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
valentinak56 [21]
3 years ago
9

Consider this program segment: int newNum = 0, temp; int num = k; // k is some predefined integer value 0 while (num > 10) {

temp = num % 10; num /= 10; newNum = newNum * 10 + temp; } System.out.println(newNum); Which is a true statement about the segment? I If 100 <= num <= 1000 initially, the final value of newNum must be in the range 10 <= newNum <= 100. II There is no initial value of num that will cause an infinite while loop. III If num <= 10 initially, newNum will have a final value of 0.
Computers and Technology
1 answer:
Doss [256]3 years ago
6 0

Answer:

All of these statements are true.

Explanation:

Since the while loop is reversing the integer number and leaving the highest order digit in the num and stores the reversed number in the newNum variable.

It skips one digit so if the num is in the range of [100,1000] it will result in a number between 10 and 100.

This loop can never go in infinite loop for any initial value of num because the loop will run as many times as the number of digits.

and if the value of the num is <=10 the while loop will never run and the value of newNum will be 0.

You might be interested in
Do Violent Video Games Make People More violent in Real Life ?
vova2212 [387]
To be honest, NO. Its just a videogame but i see what you are saying...
4 0
3 years ago
What is the meaning of Re:?
adelina 88 [10]

Answer:

In Email's Subject Line “Re:” most commonly understood as “Reply/Response” to an Email. “Re: ” is not taken as abbreviation of Regards/Reference. For Reference, Abbreviation is “Ref.”Explanation:

5 0
3 years ago
Read 2 more answers
The process of making raw materials into a finished product is known as
Olin [163]
1.) Business Engineering or Manufacturing :)
<span />
6 0
2 years ago
Read 2 more answers
A robot worker and a human worker are both vulnerable to
Lady bird [3.3K]

Answer:

fire

Explanation:

4 0
3 years ago
An Internet service provider that wants to influence consumers to immediately switch to its service would most likely utilize __
frutty [35]

Answer: Direct competitive

Explanation:

 The direct competitive situation occur when the two and more than two business in the market offering the similar type of services and the products so it automatically increase the level of competition in the market.

According to the question, the internet service is one of the most efficient tool for influence the customers or consumers about their products in the market and when the services are get switched then it utilize the direct competitive in the market.

Therefore, direct competitive is the correct option.

6 0
3 years ago
Other questions:
  • Write a program that requires the user to enter two floating-point numbers (num1 and num2) from the keyboard. Multiply them and
    6·1 answer
  • <img src="https://tex.z-dn.net/?f=3x%20-%205%20%3D%203x%20-%207" id="TexFormula1" title="3x - 5 = 3x - 7" alt="3x - 5 = 3x - 7"
    12·1 answer
  • An indicator is a comprehensive analysis of critical information
    8·1 answer
  • In computers, when the print command is executed, a cable carries this signal from the computer to the printer. In comparing a c
    11·1 answer
  • How do media and networks interact? A. Networks and media work in exactly the same way. B. Media are connected to networks that
    8·1 answer
  • It's fill the gap homework
    7·1 answer
  • Which of the following is input devices? (a)Scanner (b) Keyboard (c) Both a and b (d) Plotter​
    5·1 answer
  • Most significant effect the rotary press had on printing
    9·1 answer
  • Write a program that will add up the series of numbers: 99, 98, 97… 3, 2, 1. The program should print the running total as well
    13·1 answer
  • In a typical office, biometric authentication might be used to control access to employees and registered visitors only. We know
    14·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!