Advertisement
Guest User

Untitled

a guest
Feb 22nd, 2020
94
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Python 0.18 KB | None | 0 0
  1. words=['paste', 'eyes', 'motor', 'choose', 'book']
  2. def super_sum(a):
  3.     total=0
  4.     for x in a:
  5.         for y in x:
  6.             if  y=='s':
  7.                 total=total+x.index('s')
  8.     print (total)
  9. super_sum(words)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement