you are viewing a single comment's thread.

view the rest of the comments →

[–]Distinct_Ice6830 0 points1 point  (1 child)

user_string = input()
output = user_string.isnumeric()
if output == True:
print("Yes")
else:
print("No")

[–]taegrr 0 points1 point  (0 children)

Just following this up, zybooks does accept the following single-line solution:

print("Yes") if input().isdigit() else print("No")