The following exercise has problems related to the concept of variables, input and output functions.
1. Write a python script to read two numbers from the user and calculate
a. sum b. multiplication c. division d. subtraction e. modulus
2. Write a python script to read the radius from the user, find the area and perimeter of a circle.
3. Write a python script to read the base and height and print the area of a triangle.
4. Write a python script which reads the sides (a,b,c) of a triangle and find the area of it.
5. Mr. Sudhakar has 2 bank accounts. First account has balance ‘b1’ and Second account has balance ‘b2’. The bank will deduct 15% of bank balance at the end of the month in each account. print the bank balance of Mr. Sudhakar at the end of the month.
6. Mrs. Binish started reading python book of 500 pages. For reading a single page it takes 20 minutes for her and will take a break for some time while reading. Write a python script to print the number of hours for Binish to read the complete book, if she has taken 3 breaks. [ note: each break is of time 30 minutes]
7. Every day Morning Milk is brought from ‘n’ farms to a milk booth for sales. Given the amount of milk from ‘n’ forms, write an algorithm and python code to find the total quantity of milk in booth in milli liters. For example, if there are three farms i.e. n=3, from first farm 2 liters 300 ml, second farm 3 liters 700 ml and from the third farm 1 liter 200 ml, then the total quantity of milk is 7200 ml.
8. Assume the price of a book is 1200 Indian Rupees, but the e-commerce site has given a discount of 30% for each copy. Shipping cost is 200 Indian Rupees for 20 books. Write a python script to find the total price to be paid by the customer if he ordered 40 copies of the same book.
9. I started from my office to home at 7:00 PM. I walked 10 minutes 30 seconds and had a coffee at the coffee shop for 20 minutes 30 seconds. From there i went to the shopping and spend around 2 hours 40 minutes. From the shopping mall it took 30 minutes to reach home. At what time may i reach the home for dinner.