0% found this document useful (0 votes)
8 views3 pages

Problem Sheet For Lab1

The document is a problem sheet from PSG College of Technology's Department of Computer Applications for a course on Object Oriented Programming with Python. It includes various programming exercises such as calculating money in a piggybank, generating a bill amount, evaluating a student's result, and determining the day of the week based on user input. Additional tasks involve checking character types, calculating the area of a triangle using Heron's formula, and understanding Python variable assignments.

Uploaded by

schrujhana.jagan
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)
8 views3 pages

Problem Sheet For Lab1

The document is a problem sheet from PSG College of Technology's Department of Computer Applications for a course on Object Oriented Programming with Python. It includes various programming exercises such as calculating money in a piggybank, generating a bill amount, evaluating a student's result, and determining the day of the week based on user input. Additional tasks involve checking character types, calculating the area of a triangle using Heron's formula, and understanding Python variable assignments.

Uploaded by

schrujhana.jagan
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

PSG COLLEGE OF TECHNOLOGY

DEPARTMENT OF COMPUTER APPLICATIONS


BE ECE G1 - 23L205 OBJECT ORIENTED PROGRAMMING WITH PYTHON

PROBLEM SHEET BASED ON OPERATORS


1. Write a program to calculate the total amount of money in the piggybank, by getting the
input for the number of coins of Rs.10, Rs.5, Rs.2, Rs.1.
2. Write a program to calculate the bill amount for an item by getting input for the quantity
sold, value, discount,tax. Display the bill in the following format.
3. Write a program to calculate a student’s result based on two examinations, one sport event
and three activities conducted. The weightages are Examination 50%, Sports 20% and
Activities 30%.
4. Write a program that prompts the user to enter a number between 1 – 7 and the displays the
corresponding day of the week.
5. Write a program to take input from the user and then check whether it is a number or a
character. If it is a character, determine whether it is in uppercase or lowercase.
6. Write a program to calculate the area of a triangle using Heron’s formula.
(Hint: Heron’s formula is given as: area= sqrt(s*(s-a)* (s-b)* (s-c)))
[Link] a program to calculate the tax with the given conditions

8. Given the following assignment: x = 2 and find the output for the following Python
statements.
(a) print("x")
(b) print(‘x’)
(c) print(x)
(d) print("x + 1")
(e) print(‘x’ + 1)
(f) print(x + 1)

You might also like