AnsweredAssumed Answered

Python Help For Beginner

Question asked by Bauger on Jun 3, 2014
Latest reply on Jun 3, 2014 by jamesfreddyc
Hi folks,

Another python question for the forum, this one should be easy. I am trying to complete the following exercise and am stumped with the last section. I am asked to print only the items in the list with exactly 5 characters. If anyone can help me out that would be much appreciated.

# Create list with these four entries: roads, streams, parks, contours value1 = "roads" value2 = "streams" value3 = "parks" value4 = "contours"  List = [value1, value2, value3, value4]  # Print the first entry in the list to the interactive window print List[0]  # Use a loop to print every entry that has exactly 5 # characters to the interactive window  print List