sadeem50 sadeem50
  • 10-11-2020
  • Computers and Technology
contestada

What is the output of the below Java program?
int a=1:
while (a=4)
{
System.out.print(a + "");
a ++:
}
What is the output of the following java program

Respuesta :

skowronkow skowronkow
  • 10-11-2020

Answer:

If you fix your program: instead of "while (a=4)" you will have: while(a<4)

It wil print:

> 123

Explanation:

You can check the output of that kind of programs in online repl consoles e.g: https://repl.it/languages/java10

Answer Link

Otras preguntas

Here's a story problem...."Rita's wants to estimate the number of beans in a large jar.  She takes out 100. she takes out 100 beans and marks them. Then she ret
if arctan(3/5)=K    Tan(k)=?
Here's a story problem...."Rita's wants to estimate the number of beans in a large jar.  She takes out 100. she takes out 100 beans and marks them. Then she ret
Here's a story problem...."Rita's wants to estimate the number of beans in a large jar.  She takes out 100. she takes out 100 beans and marks them. Then she ret
Here's a story problem...."Rita's wants to estimate the number of beans in a large jar.  She takes out 100. she takes out 100 beans and marks them. Then she ret
At the begining of 6 grade the ratio of number of the advanced math students to the number of regular students was 3:8. However after taking the placement tests
What was an effect of nationalism in Europe in the early 1900s?
if arctan(3/5)=K    Tan(k)=?
What was an effect of nationalism in Europe in the early 1900s?
Suppose theta= 11pi/12. How do you use the sum identity to find the exact value of sin theta?