Answer:
The output of this question is 21. As show in the image
The explanation is given in below
Explanation:
Let first write the question
C=1
sum = 0
while(C<10):
C=C+3
sum=sum + C
print(sum)
Now Focus on
while(C<10):
C=C+3
sum=sum + C
The value of C is initially 1
C=1+3
Sum= 0+4
In second loop the value of C will become 4
c=4+3
sum=4+7
In third loop the value of C will be 7
c=7+3
sum=11+10
so the answer is 11+10=21
1
they were crafted in stained-glass art in religious buildings
2
puzzle games
3
motion-capture devices (e.g., Kinect, WiiMote
4
puzzle
simulation
There is your answer:
Flashing images
Answer: dynamically modified model
Explanation:
Complete Question:
Write a do-while loop that continues to prompt a user to enter a number less than 100, until the entered number is actually less than 100. End each prompt with a newline. Ex: For the user input 123, 395, 25, the expected output is:
Enter a number (<100):
Enter a number (<100):
Enter a number (<100):
Your number < 100 is: 25
Answer:
import java.util.Scanner;
public class num8 {
public static void main(String[] args) {
Scanner in = new Scanner(System.in);
int n;
do{
System.out.println("Enter a number (<100):");
n= in.nextInt();
}while(n>100);
System.out.println("Your number < 100 is: "+n);
}
}
Explanation:
Using Java programming language
Import the scanner class to receive user input
create an int variable (n) to hold the entered value
create a do while loop that continuously prompts the user to enter a number less than 100
the condition is while(n>100) It should continue the loop (prompting the user) until a number less than 100 is entered.