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
Eddi Din [679]
3 years ago
5

Write a program that asks the user to enter an object’s mass, then calls a // function to return the object's weigh in newtown.

If the object weighs // more than 500 newtons, the function also displays a message indicating that // it is too heavy. If the object weighs less than 100 newtons, the function // also displays a message indicating that it is too light.
Computers and Technology
1 answer:
lisov135 [29]3 years ago
4 0

Answer:

import java.util.Scanner;

public class num8 {

   public static void main(String[] args) {

       Scanner in = new Scanner(System.in);

       System.out.println("Enter the mass");

       double mass = in.nextDouble();

       double weight = calWeight(mass);

       System.out.println("The weigth is "+weight);

   }

   static double calWeight(double mass){

       double weight = mass*9.80665; // assume a = accelation due to gravity = 9.80665N

       if(weight>500){

           System.out.println("Too Heavy");

       }

       else if(weight<100){

           System.out.println("Too Light");

       }

       return weight;

   }

}

Explanation:

  • Using Java programming language
  • The main method is created to request and store a variable, mass in kilogram. The main method call calWeight() and passes the value for mass
  • A method calWeight() is created that calculates the weight in newtons (mass * 9.8).
  • The method checks if the weight is greater than 500 (prints too heavy) if less than 100(prints to light)
  • Returns the weight  

You might be interested in
Yuri, a medical assistant, has been asked to send an account of a patient's last office visit to another doctor's office. The te
g100num [7]
The internet,,

To let the other doctor know about specific details on the patient, and other excessive information.

Hope this helps!! :)
6 0
3 years ago
Read 2 more answers
Which of the following is as result of division of Labour​
neonofarm [45]

Answer:

Specialization

Explanation:

6 0
3 years ago
The isometric projection camera technique provides an illusion of perspective by using things like parallax scrolling to create
Oksi-84 [34.3K]

Answer:

False.  

Explanation:

In this question some information is missing the question does not mention which type of question is this. This question is a true/false type question.

isometric projection camera is an engineer or the technical drawing in which we represented the 3D(three dimensional) objects in the 2D(Two dimensional) objects. This camera representing the object in a visual manner. isometric projection is also known as Isometric drawing, In the isometric projection camera, all the angles are equal. It does not provide an illusion perspective by using parallax scrolling to create the illusion of 3D in a 2D game.

3 0
3 years ago
What is key to remember when handling linked lists?
djyliett [7]

Answer:

Some key points to remember, when handling the linked list are as follow:

  • Linked list is the linear data structure in which each of the elements contain separate object.
  • Linked list components are not store in a contiguous location.
  • In the linked list the elements or components are basically use the pointers for linked with another elements.
  • The last node of the linked list must contain null value.
  • In the linked list, the allocation of the memory is equal to upper node limit.
7 0
3 years ago
G The method of mapping where each memory locationis mapped to exactly one location in the cache is
Otrada [13]

Answer:

Direct Mapped Cache

Explanation:

Given that a Direct Mapped Cache is a form of mapping whereby each main memory address is mapped into precisely one cache block.

It is considered cheaper compared to the associative method of cache mapping, and it is faster when searching through it. This is because it utilizes a tag field only.

Hence, The method of mapping where each memory location is mapped to exactly one location in the cache is "Direct Mapped Cache"

4 0
3 years ago
Other questions:
  • Given a positive integer, output its complement number. The complement strategy is to flip the bits of its binary representation
    6·1 answer
  • Write a grammar for the language consisting of strings built only of the letters a and b. The strings may have any number of the
    6·1 answer
  • Web browsers are used to browse the world wide web.
    5·2 answers
  • "_____ devices improve memory by encoding items in a special way."
    13·1 answer
  • Which of these is NOT a desktop computer operating system?
    8·2 answers
  • write a script to check command arguments. Display the argument one by one (use a for loop). If there is no argument provided, r
    6·1 answer
  • I like to troll what about you
    10·1 answer
  • List at least 5 professions for people working in the Information/Communication<br> fields.
    10·1 answer
  • Synapse is not working and is crashing every time you attach it. What should you do?
    13·1 answer
  • Moving images of real event​
    12·2 answers
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!