Python Challenging Questions
Python Challenging Questions
Solve any two of the following questions to qualify for the selection round:
Q.1 Write a program to find LCM of two or more then two numbers entered by the user.
Q.2 Write a program to accept a string (minimum length of string to be 3 and maximum to
be 9) and code the program to produce the following result:
Output : cow
cwo
owc
ocw
woc
wco
Q.3 Write a program to take input of a list object having numbers between 1 to 9 only with
minimum list elements count to be 3 and maximum to be 9 as shown below using a test
case and produce the output shown below.
Input : [ 5, 1, 6, 7, 9 ]
Output : [ 1, 5, 6, 7, 9]
[ 5, 6, 7, 9, 1]
[ 6, 7, 9, 1, 5]
[ 7, 9, 1, 5, 6]
[ 9, 1, 5, 6, 7]
1 2 3 4 5 6 7 8
7 6 5 4 3 2 1
1 2 3 4 5 6
5 4 3 2 1
1 2 3 4
3 2 1
1 2
1