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
Pretty please lmk what this is
Gnesinka [82]

Answer:

Donda

Step-by-step explanation:

3 0
3 years ago
What is the range of possible sizes for side x? _ &lt; x &lt; _
allochka39001 [22]

Answer:

  0.5 < x < 16.5

Step-by-step explanation:

The third side of the triangle must be longer than the difference of the other two sides:

  x > (8.5 -8.0)

  x > 0.5

And it must be shorter than their sum:

  x < (8.5 +8.0)

  x < 16.5

The third side must be in the range ...

  0.5 < x < 16.5

_____

These limits are a direct consequence of the triangle inequality, which requires the sum of the two shortest sides exceed the length of the longest side.

3 0
2 years ago
The vertices of quadrilateral EFGH are listed below.
pav-90 [236]
It is going robe f help me ?
6 0
3 years ago
HELP MEE PLEASEE I DONT WANNA FAIL SUMMER SCHOOL NO FILES OR LINKS WOULD BE DEEPLY APPRECIATED
bazaltina [42]
1) 3:5
2) 7:10
3) 2:9
4) 6:1
5) 5:2
6) 11:3
7) 9:5
8) 2:7
9) 8:3
10) 5:2
4 0
2 years ago
If a child's knowledge of the alphabet is limited to the letters a, b, c, i, and e, and if the child writes two letters at rando
Savatey [412]
The formula for probability is # of favorable outcomes divided by the total number of outcomes. 

So we know that there are a total of 5 letters. The child writes two letters, so we will have x/5 * x/5. Now, it is asking, what is the probability that they are both vowels.

We can see that a, i, and e are vowels, so the probability if the child were to write one letter would be 3/5. Since he is writing 2, you can multiply 3/5 * 3/5, which would give you your answer, 9/25. Therefore the probability that both letters are vowels is 9/25.

Hope this helps! Please rate, leave a thanks, and mark a brainliest answer. (Not necessarily mine). Thanks, it really helps! :D


7 0
3 years ago
Other questions:
  • The area of a triangle is 3.6 cm 2 . If the triangle has a base of 6 cm, what is the height?
    10·1 answer
  • A study of fish is being conducted in a pond. They marked 30 fish and released them. The next day, they counted 75 fish, 25 of t
    5·1 answer
  • What is the range of f(x) = A cos(x) +b or<br> g(x) = A sin(x)+b?
    10·1 answer
  • Will mark brainliest
    7·1 answer
  • 12. A cyclist travels 40 km at a speed of x km/h. Find the time
    13·2 answers
  • Instead of using the values {1,2,3,4,5,6) on dice, suppose a pair of dice have the following: {1,2,2,3,3,4} on one die and {1,3,
    15·1 answer
  • Explain what happens as the heart grows bigger.
    15·2 answers
  • What is the image of the point (-5, 6) after a rotation of 90°
    8·1 answer
  • Y=(<br><img src="https://tex.z-dn.net/?f=y%20%3D%20%28%20%5Csqrt%7Bx%20%2B%203%7D%20%2B%205%29%20%5E%7B10%20%7D%20" id="TexFormu
    8·1 answer
  • 4. Ian and his friends are renting a cabin
    14·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!