0% found this document useful (0 votes)
395 views

PAP-Solution 18CS752 15CS664

This document provides information about a CBCS scheme exam for a Python Application Programming course taken by a student with USN 15CS664. The exam contains 5 questions to choose from across 5 modules. For each module, there are 2 main questions to choose from. The questions cover topics like computer hardware architecture, conditional statements, functions, files, strings, lists, tuples, classes, functions, time objects, operator overloading, web scraping, APIs, binary files, and databases. The exam is 3 hours long and carries a maximum of 80 marks. Relevant details like the course, subject code, semester, and date of the exam are also provided.

Uploaded by

Bharath Bharath
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
395 views

PAP-Solution 18CS752 15CS664

This document provides information about a CBCS scheme exam for a Python Application Programming course taken by a student with USN 15CS664. The exam contains 5 questions to choose from across 5 modules. For each module, there are 2 main questions to choose from. The questions cover topics like computer hardware architecture, conditional statements, functions, files, strings, lists, tuples, classes, functions, time objects, operator overloading, web scraping, APIs, binary files, and databases. The exam is 3 hours long and carries a maximum of 80 marks. Relevant details like the course, subject code, semester, and date of the exam are also provided.

Uploaded by

Bharath Bharath
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 34

CBCS SCHEME

USN 15CS664

Sixth Semester B.E. Degree Examination, Jan./Feb. 2021


Python Application Programming
Time: 3 hrs. Max. Marks: 80

Note: Answer any FlVEful questions, choosing ONEfull question from each module.

a. Explain the computer hardware architecture with a


Module-1 neat sketch. (06 Marks)
b. Write a note on general
typesof errors
Write a program that uses input to prompt a user for thejY name and then welcomes them.
(06 Marks)

(04 Marks)

OR
2 a. Write
program which prompts
a the user
för a Celsius temperature, convert the temperature
to
Fahrenheit and print the converted temperáture. (06 Marks)
b. Explain nested conditional statement with an example. (04 Marks)
C WTite a prögram with a function domputer grade that takes a score as its parameter and
returns a grade as a string.
(06 Marks)

Module-2
a. Anaiyze the of break
and continue statement with an example.
use
(06 Marks)
b. Explain format operators in python with suitable examples. (03 Marks)
- Define a file data structure. lllustrate
reading and writing operation on files with examples.
(07 Marks)

OR
4 a. Write a program to read numbers repeatedly until the user enters 'done'.
Once 'done' is
entered print out total, count and average of the numbers,
(06 Marks)
. Write a note on string methods.
(07 Marks)
Write a program to read through a file and print the contents of the file
(line by line) all in
uppercase. (03 Marks)

5
Module-3
a. Explain list operations and list methods with examples.
b. Write (05 Marks)
a
program to count how maný times each letter appears in a word. (07 Marks)
C. Explain tuple asignment with examples. (04 Marks)

OR
6 a. Write a program to opeoA filé and read it line by line. For each
words using split function. For each word check to see if the line, split the line into list of
word is already in a list. If the
word is not in the lis1, add it to the list.
b. Explain advanced (06 Marks)
text parsing using dictionary. (07 Marks)
C. Why search and find all functions of regular expressions used?
examples. Explain with suitable
(03 Marks)
I of 2
ELL
15CS664
71 a. Define class. Explain classes Module-4
and objects of
python in,detil with suitable
examples.
b. What is a pure
function? Explain with an example (10 Marks)
(06 Marks)
8 a.
a. Write a
program with a function OK
print_timehat
hour:minute:second. Write another function is takes a time objectand prints it in the form
resume True ift
follows t2 after that takes two time
b. Write a note on chronglagically and False otherwise objects ti and t2 and
operator overloadingjWith an (08 Marks)
example. (08 Marks)
9 a.How to retrieve web Modulc-5
the file retrieved. pagéSuSing urllib? Explain howtocompute
b. What is an API? frequency of each word in
Explainawith a neat sketch. (08 Marks)
(08 Marks)
10 a. Write programsto read binary files.
a ORA
b. Explain keýs ina database model. (08 Marks)
(08 Marks)
T

VD

tikiy
Name of facul+y Prof. Rauindra Poiu

De poht nea
Cosmpu Sest nde énag

Cer Se s .

Subitct Pyhon App% co%on

Subjtc Co 1SCS661/19CS 66H &cS 7S2,

alla
StaPt Tnchoohi HoD Dean' AcadtmiC
Dean, Academics
KLS
VD1T, HALIYAL
CO
KLS ih¥
rstitute of Tactnoiogy, Haliy.

You might also like