Question
use jupyter notbook Q1 part A ''' write a program to remove the item present at index 3 and add it to the 2nd position
use jupyter notbook
Q1 part A
'''
write a program to remove the item present at index 3 and add it to the 2nd position and at the end of the list.
sample_input = [54, 44, 27, 79, 91, 41]
sample_output = [54, 44, 79, 27, 91, 41, 79]
'''
part b
'''
write a python program which accepts a sequence of comma-separated numbers from user and generate a list and tuple with those numbers.
sample data : 8, 24, 65, 3
output :
List : ['8' , '24' , '65' , '3']
Tuple : ('8' , '24', '65' , '3')
'''
part c
'''
slice the below list into 3 equal parts, reverse each part and print it as 3 separate list.
input = [11, 45, 8, 23, 14, 12, 78, 45, 89]
note: should only use slicing
'''
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started