subject

JAVA CHALLENGE ZYBOOKs ACTIVITY
2.18.3: Fixed range of random numbers.
Type two statements that use nextInt() to print 2 random integers between (and including) 100 and 149. End with a newline. Ex:
112 102
My Previous Incorrect Attempt :
import java. util. Scanner;
import java. util. Random;
public class RandomGenerateNumbers {
public static void main (String [] args) {
Random randGen = new Random();
int seedVal;
seedVal = 4;
randGen. setSeed(seedVal);
/* Your solution goes here */
int first = randGen. nextInt(10);
int second = randGen. nextInt(10);
System. out. println(first*seedVal*14);
System. out. println(second*seedVal*(51/4)+6); }
}
MUST BE USED CODE TEMPLATE:
import java. util. Scanner;
import java. util. Random;
public class RandomGenerateNumbers {
public static void main (String [] args) {
Random randGen = new Random();
int seedVal;
seedVal = 4;
randGen. setSeed(seedVal);
/* Your solution goes here */
}
}

ansver
Answers: 1

Another question on Computers and Technology

question
Computers and Technology, 23.06.2019 12:00
If you're using an existing powerpoint presentation that will receive new slides based on a word outline, select the a. slide that will appear after the new slides. b. first slide in the presentation. c. slide that will appear before the new slides. d. last slide in the presentation.
Answers: 2
question
Computers and Technology, 23.06.2019 12:20
When guido van rossum created python, he wanted to make a language that was more than other programming languages. a. code-based b. human-readable c. complex d. functional
Answers: 1
question
Computers and Technology, 23.06.2019 14:00
Select the correct answer. a company is currently focusing on creating specific management goals for itself. which level of maturity is the company demonstrating under the sse_ccm framework? a. performed informally b. planned and tracked c. quantitatively controlled d. well-defined e. continuously improving
Answers: 2
question
Computers and Technology, 23.06.2019 17:00
What does the faves button do? a. users mark a web page as a favorite b. leads other readers to favor a specific page c. readers sort and align their favicons, or favorite icons d. leads users to a message board where they can post questions
Answers: 1
You know the right answer?
JAVA CHALLENGE ZYBOOKs ACTIVITY
2.18.3: Fixed range of random numbers.
Type two stateme...
Questions
question
Mathematics, 07.01.2022 07:20
question
Social Studies, 07.01.2022 07:20
Questions on the website: 13722362