I'm fairly new to Python (and programming in general), so I often end up facing really silly issues, such as the one below.
What I want is to repeatedly check if all the characters in a user input are symbols. When such an input is entered, I want to print that string.
Since there doesn't seem to be a way to specifically test for symbols, I decided to test for letters first, and then for numbers, and if both of them come up as negative, then it should print the text.
Here is my code:
while True:
symbols = input("Enter symbol string:")
if symbols == symbols.isalpha():
print (symbols.isalpha())
elif not a == a.isalpha():
print (a.isalpha())
break