Study

Lists in Python - Activity#3

  •   0%
  •  0     0     0

  • What is the output of the above code segment?
    [7, 5, 2, 8]
  • What is output of the above code segment?
    True
  • Write the Python code that can sort list numbers = [1, 4, 2, 6, 3 ]
    numbers.sort()
  • What is the output of the following list assignment?
    False
  • Using the slicing concept, write the line of code that would display elements [4, 5, 6] only.
    numbers[3:6]