Created
November 20, 2014 23:04
-
-
Save koalahamlet/c4e07a1aba1b7a680aa0 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
for (var i = 1; i < 13; i++) { | |
var str = ""; | |
for (var j = 1; j < 13; j++) { | |
var num = i*j; | |
var spacer; | |
if (num <= 9) { | |
spacer = " " | |
} | |
else if (num <= 99 ){ | |
spacer = " " | |
} else { | |
spacer = " " | |
} | |
str += i*j + spacer; | |
} | |
console.log(str); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment