model2-PYTHON
model2-PYTHON
9. How do you use command line arguments to give input to the program?
11. i) Draw a flow chart to accept three distinct numbers , find (AU,N/D2022) C105.2 BTL2
the greatest and print the result (8)
ii) Draw a flowchart to find the sum of the series. 1+2+3+…..
+100(8)
12. i) What is meant by recursion? Write a recursive algorithm to (AU,N/D2022) C105.3 BTL2
solve towers of Hanoi problem (8)
ii) Explain in detail about precedence of python operators
and the associativity of python operators.(8)
13. i) Discuss about scope and lifetime of variables considering (AU,N/D2022) C105.2 BTL3
functions.(8)
ii) Write and explain the python program to swap two
numbers with and without temporary variables.(8)
14. i) Explain bubble sort algorithm using python (AU,N/D2023) C105.2 BTL4
programming(8)
ii) What is string function in python? Explain any 3 python
string methods with an example.(6)
15. i) Explain in deatil about lists, list operations and list slices(8)
(AU,A/M2023) C105.2 BTL3
ii)Demonstrate with python code the various operations that can be performed on tuples(8)
16. i) Why does python require file handling?Explain opening & closing file in python with all modes.
(AU,N/D2023) C105.3 BTL4
ii) Give a brief note on python exception handling using try, except, raise and finally statements.(8)