September 2017 Update

This commit is contained in:
Ingy döt Net 2017-09-23 10:01:46 +02:00
parent bba7bfd280
commit ba8067c3b7
14570 changed files with 153136 additions and 63871 deletions

View file

@ -0,0 +1,10 @@
fcn multiplicationTable(n){
w,fmt := (n*n).numDigits, " %%%dd".fmt(w).fmt; // eg " %3".fmt
header:=[1..n].apply(fmt).concat(); // 1 2 3 4 ...
println(" x ", header, "\n ", "-"*header.len());
dash:=String(" "*w,"-"); // eg " -"
foreach a in ([1..n]){
print("%2d|".fmt(a),dash*(a-1));
[a..n].pump(String,'*(a),fmt).println();
}
}(12);