1answer.
Ask question
Login Signup
Ask question
All categories
  • English
  • Mathematics
  • Social Studies
  • Business
  • History
  • Health
  • Geography
  • Biology
  • Physics
  • Chemistry
  • Computers and Technology
  • Arts
  • World Languages
  • Spanish
  • French
  • German
  • Advanced Placement (AP)
  • SAT
  • Medicine
  • Law
  • Engineering
olga2289 [7]
4 years ago
13

ammy's Seashore Supplies rents beach equipment such as kayaks, canoes, beach chairs, and umbrellas to tourists. Write a program

that prompts the user for the number of minutes he rented a piece of sports equipment. Compute the rental cost as $40 per hour plus $1 per additional minute. (You might have surmised already that this rate has a logical flaw, but for now, calculate rates as described here. You can fix the problem after you read the chapter on decision making.) Display Sammy's motto with the border that you created in the SammysMotto2 class in Chapter 1. Then display the hours, minutes, and total price. Save the file as SammysRentalPrice.java.
Computers and Technology
1 answer:
melomori [17]4 years ago
8 0

Answer:

// Here is SammysRentalPrice.java file

// import package

import java.util.*;

// class definition

class SammysRentalPrice

{

   // main method of the class

public static void main (String[] args) throws java.lang.Exception

{

   try{

    // object to read value from user

    Scanner scr=new Scanner(System.in);

    // ask to enter rented minutes

       System.out.print("enter rented minutes: ");

       // read minutes

       int min=scr.nextInt();

       // find hours

       int hour=min/60;

       //reamining minutes

       min=min%60;

       // total cost

       int cost=hour*40+min*1;

       // print cost

       System.out.println("total cost is: "+cost);

   }catch(Exception ex){

       return;}

}

}

Explanation:

Read rented minutes from user and assign it to variable "min".Find the hours from minutes and then update the remaining minutes.After this multiply hours with 40 and remaining minutes with 1.Sum them and this will be the cost of rented a sports equipment.

Output:

enter rented minutes: 145

total cost is: 105

You might be interested in
Which is the most used operating system? A. Windows B.Linux C.Leopard D. DOS
Neko [114]
I think it´s either A. or  B.
7 0
3 years ago
Read 2 more answers
The CPI is a measure of the overall cost of the goods and services bought by a. a typical consumer, and the CPI is computed and
Akimi4 [234]

Answer:

a typical consumer, and the CPI is computed and reported by the Bureau of Labor Statistics.

Explanation:

The CPI is a measure of the overall cost of the goods and services bought by a typical consumer , and the CPI is computed and reported by the Bureau of labor statistics. Hence, option C is correct.

5 0
3 years ago
What is a saved link to a particular web page?​
il63 [147K]

Answer:

In a website, a hyperlink (or link) is an item like a word or button that points to another location. When you click on a link, the link will take you to the target of the link, which may be a webpage, document or other online content. Websites use hyperlinks as a way to navigate online content.

4 0
3 years ago
A visual basic application consists of a single file true or false
saw5 [17]
False. When decompiled you can see all the files required for it to run
3 0
3 years ago
Read 2 more answers
Diana is running a successful remarketing campaign. She wants to expand her reach with other targeting options. While creating a
mart [117]

Answer:

B: Audience interest around different topics.

Explanation:

When using Google Ads, and the main aim is to create a campaign for a particular marketing activity, there are several options that makes Google Ads the ideal application for this purpose. However, choosing similar audiences under the targeting option is simply telling google to find users or audiences that are interested in the different topics, but are in one way or the other connected to your marketing activity or campaign.

8 0
3 years ago
Other questions:
  • Consider a set of mobile computing clients in a certain town who each
    13·1 answer
  • If you and another person want to encrypt messages, what should you provide that person with?
    10·1 answer
  • Which of these is a Microsoft certification CCIE PMP PRINCE2 MCSE
    11·1 answer
  • 110101111.11011 to decimal (base 10)
    6·1 answer
  • A user reports that a file they shared out on their computer for another network user is not accessible to the third party. The
    5·1 answer
  • A professional bureaucracy is a knowledge-based organization where goods and services depend on the expertise and knowledge of p
    7·1 answer
  • Which command button contains the following sub options as given in the picture?
    6·2 answers
  • FREEFREEFREEFREEFREEFREE
    11·2 answers
  • Which of the following is an advantage of using
    6·2 answers
  • What is output?
    13·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!