You are on page 1of 2

1.

Write the python program which


 Input the top speed of 10 cars
 Output the fastest speed and the slowest speed

2. A small café sells 4 types of item:


bun 0.50 dollars
coffee 1.20 dollars
cake 1.50 dollars
sandwich 2.10 dollars

Write the python program, which


 inputs every item sold during the day
 uses an item called ‘end’ to finish the day’s input
 adds up the daily amount taken for each type of item
 outputs the total takings (for all items added together) at the end of the day
 outputs the type of item that had the highest takings at the end of the day.

3. Write a program to display the square and cube of a number between 1 and 50
entered by a user.
The code must:
 ask the user to enter a number between 1 and 50 inclusive
 display the number, the square of the number and the cube of the number,
with appropriate labels
 stop when a number outside the range 1 to 50 is entered.

4. Ayomi wants a program that will calculate the number of fence panels required
to surround building sites such as the one shown in the diagram (not to scale).
Each building site is a rectangle.
Each fence panel is 1 meter long.
Width A gap of 4 meters is needed to access each site.
The location of the gap is not significant.
The user will input the length and width of the building site as whole numbers of
meters.
The program will output the minimum number of full panels needed.

You might also like