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
Vesna [10]
2 years ago
14

JAVA

Mathematics
1 answer:
Oksi-84 [34.3K]2 years ago
3 0

The program is an illustration of loops

<h3>What are loops?</h3>

Loops are program statements that are used to execute repeated statements

<h3>The java program</h3>

The program, written in Java where comments are used to explain each line is as follows:

import java.util.*;

public class Main{

public static void main(String[] args) {

 Scanner input = new Scanner(System.in);

 int num;

//Get input from the user

 num = input.nextInt();

//Initialize the largest to the first input

 int maxn = num;

//This loop is repeated until a negative input is recorded

 while (num >=0){

//If the current input is greater than the previous largest

     if (num>maxn){

//Set largest to the current input

         maxn = num;      }

//Get another input from the user

     num = input.nextInt();

 }

//Print the largest

 System.out.print("Largest: "+maxn);

}

}

Read more about loops at:

brainly.com/question/14284157

You might be interested in
Equivalent decimal are decimal that have the same value. <br><br>True<br>Or<br>False
tekilochka [14]
True because decimals do have the same number when they are equivalent
5 0
3 years ago
How many times 19 go into 36
Aneli [31]
36/19
=1.894736842 and it keeps going

Hope this helped and have a great day!
5 0
3 years ago
Read 2 more answers
Grey ran 2.4 times as many miles as Emory. If Emory ran 2.08 miles, how many miles did Grey run
MrRissso [65]
2.08 x 2.4= 4.992
Round answer=5 miles
6 0
3 years ago
Its 54 your welcome because i did this from khan and i got it 54 right so its 54
ss7ja [257]
Answer: m

explanation: jsjwjwjsiw
4 0
3 years ago
Read 2 more answers
30 POINTS By looking at the intercepts, which linear function does the graph represent?
larisa86 [58]

C. f(x)=2/3x-2

<h2>Explanation:</h2>

Looking at the graph we realize that the y-intercept is given by:

b=-2

The Slope-intercept form of the equation of a line is given by:

y=mx+b

So, our equation becomes:

y=mx-2

So the only option that matches a negative y-intercept is C. Let's see that the slope m=2/3. Look at the y-intercept, if you increase x by 3 units, then y increases by 2 units and goes from x=-2 to x=0. In other words:

Change \ in \ x=\Delta x=3 \\ \\ Change \ in \ y=\Delta y=2 \\ \\ \\ m=\frac{\Delta y}{\Delta x}=\frac{2}{3}

<h2>Learn more:</h2>

Writing linear equations: brainly.com/question/12169569

#LearnWithBrainly

7 0
3 years ago
Other questions:
  • Find an equation for the line that passes through the given point and satisfies the given conditions. 11) 11) p = ( 9 , 2 ); per
    14·1 answer
  • What kind of symmetry does a cylinder have?
    13·1 answer
  • After a baseball game, both the winning and losing teams went to the same fast food restaurant. The winning team bought 24 hambu
    9·1 answer
  • What is the length X?
    14·2 answers
  • What does 1/5x13/20 equal
    10·2 answers
  • If y = 87.5, what is the value for x? 300x + 300 x plus StartFraction 500 over 7 EndFraction y equals 10,000.Y = 10,000 300x + 3
    10·1 answer
  • Which of the shapes below is a type of rectangle? Select all that apply.
    7·2 answers
  • The higher price of a commodity is ¢565.00​
    15·1 answer
  • Multiply 546.1 × 0.52 = ____
    15·1 answer
  • What is the result when the sun 4x^2+8x-1 and 7x^2-3x+8 is multiplied by 5x^2?
    10·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!