on-internet
← Community

I don't know why there's an error specifically on the true part [closed]

Stack Overflow ·

This is a python code made in Vs Code: the last part of the code: if choosed_square True print("Code Worked") isn't working! # The legend says that the chess Creator asked for 1 grain in the first square, # in the second square, in the fourth square , in the eighth square... always multiplying. choosed_square = int(input("Choose a square on the board! (1 to 24): ")) if choosed_square < 1 or choosed_square > 24: print("Woah! The board has only 24 squares. Try Again.") else: # The Magic Formula: 4 to the power of (square - 2) grain_quantity = 4 ** (choosed_square - 2) print(f"In the square {choo

Comments

Sign in or sign up to comment and upvote.

No comments yet.