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]
3 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]3 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
True or false that computers that are joined together are able to share hardware and software, but not data
kozerog [31]
False computers are able to share hardware and software but not data
8 0
3 years ago
Ideation includes all of the following EXCEPT
chubhunter [2.5K]

i believe it would be either C or D im sorry i dont know the exact answer

5 0
3 years ago
We use a cubic equation in which the variables and coefficients all take on values in the set of integers from 0 through p - 1 a
dezoksy [38]

Answer:

We use a cubic equation in which the variables and coefficients all take on values in the set of integers from 0 through p - 1 and in which calculations are performed modulo p for a __Prime Curve_ over Zp.

Explanation:

Two families of elliptic curves are used in cryptographic applications

  1. Binary curves over GF(2m):
  2. Prime Curves over Zp.
4 0
2 years ago
What variation pairs a new employee with an employee who has been with the company for 20 years?
Eva8 [605]

The variation pairs a new employee with an old employee usually focus on employee accomplishments, and criteria that employee meets or not.

<h3>What are the Appraisal Methods used to evaluate an employee's performance?</h3>

The behavioral method is known to be one of the ways to check an employee's actions within a given job.

Conclusively, There is also the use of Comparative methods that tends to compare one employee with different employees. The use of Results methods are the ones that looks into  employee accomplishments.

Learn more about variation pairs from

brainly.com/question/19262673

4 0
2 years ago
Read 2 more answers
State four features of information​
Xelga [282]

Answer:

This is your answer

8 0
3 years ago
Other questions:
  • Monica needs a printer to use at home. She wants fine-quality prints at an affordable cost. Which printer will help her achieve
    9·1 answer
  • A ____ client locates all or most of the processing logic on the server.
    11·1 answer
  • Meaning of page break​
    8·1 answer
  • What is thought to have caused the extinction of the dinosaurs?
    13·1 answer
  • Rob creates a Course_Details table that has four columns: Course _ID, Course_Name, Semester and Credits. A course may have 0.5 c
    6·2 answers
  • What invention in the past do you think had a significant impact on our culture/ lifestyle? What do you think will be invented/
    11·1 answer
  • Write a java program to find the perimeter of a triangle with sides measuring 10cm, 14cm and 15 cm.
    8·1 answer
  • What is functionality criteria or alternative word
    8·1 answer
  • Question #8
    13·1 answer
  • Q.3.1 Explain why devices on a network need addresses. (5)​
    10·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!