Advertisement
JkSoftware

Day 4 - index errors and nested lists

Nov 7th, 2021
852
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. USA =["Delaware", "Pennsylvania", "New Jersey", "Georgia", "Connecticut", "Massachusetts", "Maryland", "South Carolina", "New Hamphire", "Virginia", "New York", "North Carolina",
  2. "Rhode Island", "Vermont", "Kentucky", "Tennessee", "Ohio", "Louisiana", "Indiana", "Mississippi", "Illinois", "Alabama", "Maine", "Missouri", "Arkansas", "Michigan", "Florida",
  3. "Texas", "Iowa", "Wisconsin", "California", "Minnesota", "Oregon", "Kansas", "West Virginia", "Nevada", "Nebraska", "Colorado", "North Dakota", "South Dakota", "Montana", "Washington", #idk why i typed all this shit
  4. "Idaho", "Wyoming", "Utah", "Oklahoma", "New Mexico", "Arizona", "Alaska", "Hawaii"]                                                                                        
  5.  
  6. dirtydozen = ["Strawberries", "Spinach", "Kale", "Nectarines", "Apples", "Grapes", "Peaches", "Cherries", "Pears", "Tomatoes", "Celery", "Potatoes"]
  7.  
  8. fruits = ["Strawberries", "Nectarines", "Apples", "Grapes", "Peaches", "Cherries", "Pears"]
  9.  
  10. veggies = ["Spinach", "Kale", "Tomatoes", "Celery", "Potatoes"]
  11.  
  12. nestedlistdirtydozen = [fruits, veggies]
  13.  
  14.  
  15. print(dirtydozen)
  16. print(nestedlistdirtydozen)
Advertisement
Advertisement
Advertisement
RAW Paste Data Copied
Advertisement