Advertisement
tian95

endswith()

Aug 16th, 2017
160
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Python 0.19 KB | None | 0 0
  1. foo = 'Sedang Belajar Python!!'
  2.  
  3. print(foo.endswith('!'))        # True
  4. print(foo.endswith('Python!!')) # True
  5. print(foo.endswith('Belajar'))  # False
  6. print(foo.endswith('python!!')) # False
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement