Does Scala have a built in formatter for binary data?
For example to print out: 00000011 for the Int value 3.
Writing one won\'t be difficult - just curious
Here is one more way (old Java):
val x = 5 val str = Integer.toString(x,2)
Just like Lauri answer, it doesn't print leading zeros.