How to write something like !(str.endswith())
in python
I mean I want to check if string IS NOT ending with something.
My code is
if text == text. upper(): and text.endswith("."):
But I want to put IS NOT after and writing
if text == text. upper(): and not text.endswith("."):
or
if text == text. upper(): and not(text.endswith(".")):
gives me Invalid syntax
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With