Created
November 26, 2012 19:45
-
-
Save nalsi/4150195 to your computer and use it in GitHub Desktop.
Print a matrix of numbers from 1*1 to 7*7
This file contains hidden or 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
## Creator: Kai Li | |
## Time: 10/18/2012 | |
## Task: Print a matrix of numbers from 1*1 to 7*7. | |
## Warning: It's not functioning properly, in that after everyline, there is an unexpected "None". | |
def nal(n): | |
i = 1 | |
while i <= 7: | |
print n*i, '\t', | |
i = i + 1 | |
def nal1(n): | |
i = 1 | |
while i <= 7: | |
print nal(i) | |
i = i + 1 | |
nal1(1) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment