Anonymous user
Pascal's triangle: Difference between revisions
→{{header|Scala}}
No edit summary |
|||
Line 791:
}
</lang>
Funtion to
<lang scala>
def prettytri(r:Int) = (1 to r) foreach {n=>print(" "*(r-n)); tri(n) map (c=>print(c+" ")); println}
|