sophkeis9025 sophkeis9025
  • 04-07-2017
  • Computers and Technology
contestada

Write a program that computes and displays a 15 percent tip when the

Respuesta :

kaevras
kaevras kaevras
  • 04-07-2017
Your question wasn't very clear, but I think I understand what you want. Additionally, you should really state what language you're working with. Here it is in C#, and shouldn't be too much of a hassle to translate in to other languages.


Console.Write("Enter payment: ");

float payment;

if (float.TryParse(Console.ReadLine(), out payment))
    Console.WriteLine((Math.Floor(payment * 100) / 100) * 0.15, + " at 15% tip.");
else
    Console.WriteLine("Invalid input.");
Answer Link

Otras preguntas

During which president's administration did the United States achieve the first budget surplus in 30 years?
which refers to the maintenance of a stable internal environment despite changing external conditions? A.differentation B. self-renewel C. homeostasis D. specia
does all the blood that passes down the aorta enter the renal artery
The veto of only one section or part of a bill
please help me thank u
16 to 19 year old male and females are __ times more likely to be involved in a crash. A. 1.7 B. 0.7 C. 2.7 D. 3.7
The horizontal line that separates the numerator and the denominator is called the dividend.
An exception to the general decline of infectious diseases in the U.S. is the increase in _____ after 1960.
When Quentin flew from New York to Atlanta,the pilot announced that they were flying at 33,000 feet.How many miles is this?Write as a mixed number.
Divide: x^10/x^4. thank you very much