In python 3.8:
print(len([x for x in input("Enter your text: ") if x not in "., "]))
I hope this helps!
6.2m questions
8.1m answers