A ask the user for the diameter of the pizza in inches b


In Python

Question 1:

Joe's Pizza Palace needs a program to calculate the number of slices a pizza of any size can be divided into. The program should perform the following steps:

A) Ask the user for the diameter of the pizza in inches.

B) Calculate the number of slices that may be taken from a pizza of that size.

C) Display a message telling the number of slices.

To calculate the number of slices that may be taken from the pizza, you must know the following facts:

  • Each slice should have an area of 14.125 inches.
  • To calculate the number of slices, simply divide the area of the pizza by 14.125.
  • The area of the pizza is calculated with this formula: Area = π*r2

Solution Preview :

Prepared by a verified Expert
Business Management: A ask the user for the diameter of the pizza in inches b
Reference No:- TGS02337974

Now Priced at $15 (50% Discount)

Recommended (92%)

Rated (4.4/5)