Write a python program to check whether inputted string has space or not.
Answers
Answered by
2
Answer:
# Python isspace() method example.
# Variable declaration.
str = " " # string contains space.
if str.isspace() == True:
print("It contains space")
else:
print("Not space")
str = "ab cd ef \n"
Similar questions
French,
1 month ago
Hindi,
1 month ago
English,
3 months ago
India Languages,
9 months ago
India Languages,
9 months ago
India Languages,
9 months ago