TristanSld

index method in lists 1

Jan 8th, 2014
70
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. #!/usr/bin/rnv python
  2. #-*-coding:utf-8-*-
  3. meyveler=["elma","erik","elma","çilek",
  4. "karpuz","kavun","elma"]
  5. print meyveler.index("elma"), "\n"
  6. print meyveler.index("elma",1), "\n"
  7. print meyveler.index("elma",2), "\n"
  8. print meyveler.index("elma",3), "\n"
RAW Paste Data