+ 1
Python operators checking
Is there any function for checking operators in a string, like we have string.punctuation for checking punctuation marks.
4 odpowiedzi
+ 3
https://code.sololearn.com/c7m0khdpxHlS/?ref=app This is my way of doing it. It has a list of operators (which you can add more of by the way). It goes through this list, checking if the string has any of them.
+ 1
@Eragon1980 I tried the same thing, but I want a predefined function like string.punctuation for checking punctuation in a string.
0
Oh OK, I'll try to come up with something
0
I don't think there is a built in function :(