Write an algorithm and draw a flowchart to print the square of all numbers from LOW to HIGH. Test with LOW=1 and HIGH=10.
Jump to Post
def square(low, high): count = 1 for count in range(low,(high+1), 1): print (count, " squared is ", count**2) lowNum = raw_input("Please insert low value") highNum = raw_input("Please insert high value") square(int(lowNum), int(highNum))
This may work, haven't tested it as i'm at school; I have no executable …
All 2 Replies
Be a part of the DaniWeb community
We're a friendly, industry-focused community of 1.21 million developers, IT pros, digital marketers, and technology enthusiasts learning and sharing knowledge.