June 2018 Update
This commit is contained in:
parent
ba8067c3b7
commit
22f33d4004
5278 changed files with 84726 additions and 14379 deletions
|
|
@ -0,0 +1,9 @@
|
|||
object Main extends App {
|
||||
val radices = List(2, 8, 10, 16, 19, 36)
|
||||
for (base <- radices) print(f"$base%6d")
|
||||
println(s"""\n${"-" * (6 * radices.length)}""")
|
||||
for (i <- BigInt(0) to 35; // BigInt has a toString(radix) method
|
||||
radix <- radices;
|
||||
eol = if (radix == radices.last) '\n' else '\0'
|
||||
) print(f"${i.toString(radix)}%6s$eol")
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue