4. To define the variable of name_list as in the following output. Write a python program to display the first and third name in the variable of name_list. The expected answer will be displayed in the following output too.
The output is:
name_list = ["Mark", "Nicole", "Jason", "Stephanie"]
Answer: Mark Jason
Answer:
name_list = ["Mark", "Nicole", "Jason", "Stephanie"] print( "%s %s"%(name_list[0],name_list[2]))
More Exercises:
Python String ExercisesMore Numpy Exercises:
Numpy String ExercisesMore Pandas Exercises:
Pandas Series ExercisesMore Tutorials:
Python Installation - Linux (Ubuntu)