You are on page 1of 2
Save trees use e-Question Paper Go green DOWNLOAD THIS FREE AT www.viuresource.com CHES Seema usN 16/17MC. Second Semester MCA Degree Examination, June/July 2018 Python Programming ‘Time: 3 hrs. M 80g Note: Answer FIVE full questions, choosing one full question from each g Module-t G1. How does computer tuna python program? Explain with a neat di Marks) ? Predict the output of the following code: i iy lenis’) i) “Computer’ + Application 7 i) “H20" #3 iv) max(2, -3, min 7), (6 Marks) 2 Explain the following: ae ‘pinput() fl) Augmented statement ip Com oo marks) ze 4S aa. Dice tnenag often wih pst oh i & Decpergenent pend xproe (tsmaees Tb Exphinand conser the memory model of {or the following assignment fe Stopes 26.0 orm) 3c. Give te sync ofa usrdeind fy explain the working with an H sample Noches) i FE 3 a. tnputanaray ofn umbes an of postive nad negative cer iu ‘eens FD. Usngsoing mato wri a prod i Oy the munberofo's gift i ib The index of ist ooMace ofS tomato, zt it) Acopy of masa a 1) Coprots monttiggitS Mating whitespace removed, coat FE 5 Whteamte haya") Comaing stings (eos) a on 22 4 a. Define aye the two ways of importing a module? Explain. (omanis) HT‘ b Detees pei frm of eed cal and ein the following ng aS mets win example ad strip() fin Secunia) eens Moutute3 s 2 Mon program to seach ancement sing Heat sarch (os ats fruits = [Banana’, ‘Apple, ‘Grapes’, “Mango'). Using the concept of slicing write ‘expression that produces the following: First tem of fruits raat Noe: 1. On com [’Banana’, “Apple, “Grapes"] iv) The list ['Grapes”, “Mango"] (os Marts) ‘Write a note on processing parallel lists using indices (04 Marks) Tot? BRANCHES | ALL SEMESTERS | NOTES | QUESTON PAPERS | LAB MANUALS A Viuresource Go Green initiative Save trees use e-Question Paper Go green DOWNLOAD THIS FREE AT www.viuresource.com 16/17MCA21 oR 6 a, Using loops, print the following pattem: PRPPP. pepe Pee PP P (04 Ma b. Explain the following list methods with example: ij extend () seri (i,¥) id remove(W) i) reverse () mals «. Prediat the output of the following code: >>> SCH >>> total=0 >>> for in range (len (6) if sf isalpha () AS 35> print total, count) coum) 7) a, How can we use with’ statement wile open pin (o4Manes) b._Diifereniate between tupes and sets based on lity, orderedness and uses. (@4Marks) ©. Predict the output ofthe following a Given lows = (0, 1,2.3,4) odds ~ (1, 3,5,7,9} i) lows-odds odds i) lows <= odds odds (8 Marks) 8 a. Write @ Python prograffillg read e'word and print the number of letters, vowels and percentage of vowelstg the Wad using dictionary (8 Marks) che Rowing file operations (5 Marks) (06 Marks) ve he bg maker to prepare a bread, (lo starks) oR ’a note on the usage ofthe module tKinter. (06 Marks) ain any si tKiner widgets. (6 Marks) ‘c.- Write a tkinter program to design a GUL window that has a label of background color green ‘and foreground color white. (04 Marks) 20f2 BRANCHES | ALL SEMESTERS | NOTES | QUESTON PAPERS | LAB MANUALS A Viuresource Go Green initiative

You might also like