Python Programming - Console Input/Output - Discussion
Discussion Forum : Console Input/Output - General Questions (Q.No. 49)
49.
How can you print the square of numbers from 1 to 5?
Answer: Option
Explanation:
To print the square of numbers from 1 to 5, use a loop with
range(1, 6)
and calculate the square with num * num
.
Discussion:
Be the first person to comment on this question !
Post your comments here:
Quick links
Quantitative Aptitude
Verbal (English)
Reasoning
Programming
Interview
Placement Papers