Ask a New Question

Question

Write a program that asks for and reads the price of a book (it may have a decimal part), multiplies it by 7% sales tax and displays both the sales tax and final price of the book on the screen.
12 years ago

Answers

Steve
$p = <STDIN>;
$t = $p * 0.07;
print $t,$p+$t;
12 years ago

Related Questions

write a program that asks the user to enter today's sales rounded to the nearest $100 for each of th... write a program that asks the user to enter an objects mass, and then calculates and displays its we... Write a program that asks the user to enter the student’s name (first and last), and his/her first e... Write a program that asks the user to input a grade that he or she received on an exam. The grade is... Write a program that asks the users to enter five test scores into an array Write a program that asks for the name of the employee, an hourly pay rate and hours worked. Compute... Write a program that asks for the number of calories and fat grams in a food. The program should dis... Write a program that asks the user for two numbers. Using a for loop, add all of the numbers from th... Write a program that asks a user for a radius value and then draws a blue circle inside a red square... Write a program that asks the user for a rating from 1-10. Follow these guidelines: If the user...
Ask a New Question
Archives Contact Us Privacy Policy Terms of Use