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

Solve the system of equations. y = x + 2, y = x2 + 7x + 10
The perimeter of a triangle is 137 cm. If three sides of the triangle are x + 7cm, 2x - 5 and 3x - 3 cm, what is the length of each side ?
Who was the first president to speak at a national ffa convention
what ideas in the declaration of independence came from the enlightenment period ?
What became of the earth when Demeter plunged into mourning over the loss of her daughter
2. Jack bought a set of golf clubs 2. Jack bought a set of golf clubs for $254.00 and received a rebate of 24%. How much was the rebate?
Find the cube root of 26 x 36 x 53
what ideas in the declaration of independence came from the enlightenment period ?
Can someone please help me
What are the vertices of the following graph?