Python Programming - Console Input/Output - Discussion

Discussion Forum : Console Input/Output - General Questions (Q.No. 59)
59.
How can you read an integer from the console and print its square?
square(int(input()))
print_square(input("Enter an integer: "))
num = input("Enter an integer: "); print(int(num) ** 2)
calculate_square(int(input("Enter an integer: ")))
Answer: Option
Explanation:
To read an integer from the console and print its square, use num = input("Enter an integer: "); print(int(num) ** 2).
Discussion:
Be the first person to comment on this question !

Post your comments here:

Your comments will be displayed after verification.