If Number = 4 , what is the range of possible numbers that can result from the f
ID: 3708412 • Letter: I
Question
If Number = 4, what is the range of possible numbers that can result from the following? (Note, this question has 2 parts; you must answer each part correctly to receive full marks. Enter only the numbers in the space provided.)
Floor(Random() * 10) + Number
The range starts at .
The range ends at .
Flag this Question
Write a random generator statement that produces random integers in the following range; store the result in a variable called Range. (Do not include spaces in your answer.)
1 through 4
Flag this Question
The _____________ function takes a string or a string variable inside the parentheses and returns the number of characters in that string.
Flag this Question
If Number = 25, what would be the result of the following conditional statement? True or false?
Sqrt(Number) == Floor(Sqrt(Number))
Flag this Question
If Number is an integer value, what would be displayed as a result of the following assignment? (Note: if there are any spaces, it is assumed to be one space.)
Set Number = Length_Of(" ")
Write Number
Flag this Question
If Number = 64, what would be the result of the following conditional statement? True or false?
Floor(Sqrt(Number/2)) == Sqrt(Floor(Number/2))
Flag this Question
____________ numbers are numbers that belong to a sequence, generated by a mathematical algorithm, in which each number is equally likely to occur.
Flag this Question9
If Number = 7, what would be the result of the following conditional statement? True or false?
Sqrt(Number) == Int(Sqrt(Number))
Flag this Question
The ___________ allows for output from Print statements to occur on a new line.
Numbers that form an unpredictable sequence in which each number is equally likely to occur are called __________ numbers.
Flag this Question
If Num1 = 5.6 and Num2 = 3, what value would be displayed as a result of the following assignment?
Set Number = Floor(Num1 * Num2)
Write Number
Flag this Question
The following random generator code Floor(Random()*6) produces the numbers through . (Note, this question has 2 parts; you must answer each part correctly to receive full marks. Enter only the numbers in the space provided.)
Flag this Question
If Num1 = 3.2 and Num2 = 5, what value would be displayed as a result of the following assignment?
Set Number = Int(Num2 - Num1)
Write Number
Flag this Question
If Number = 4, what is the range of possible numbers that can result from the following? (Note, this question has 2 parts; you must answer each part correctly to receive full marks. Enter only the numbers in the space provided.)
Floor(Random() * Number)
The range starts at .
The range ends at .
Flag this Question
If one For loop is nested within another, then the counter variables for the two loops should be _________.
Flag this Question
If Number = 6, what is the range of possible numbers that can result from the following?
Floor(Random() * Number) + 3
The range starts at .
The range ends at .
(Note, this question has 2 parts; you must answer each part correctly to receive full marks. Enter only the numbers in the space provided.)
Flag this Question
The random generator code Floor(Random()*6) produces the numbers through . (Note, this question has 2 parts; you must answer each part correctly to receive full marks. Enter only the numbers in the space provided.)
Flag this Question
It's possible to __________ out of a loop if the user has entered an incorrect value that would cause an error or a problem within the loop, or if the user has entered a required response end the program can continue without further iterations of the loop.
Flag this Question
If Num = 4.22, what value would be displayed as a result of the following assignment?
Set Num = Ceiling(Num)
Write Num
Flag this Question
If Number = 3.5, what would be the result of the following conditional statement? True or false?
Floor(Number*Number) == Number*Number
Flag this Question
If Num1 = 5.6 and Num2 = 3, what value would be displayed as a result of the following assignment?
Set Number = Floor(Num1 / Num2)
Write Number
Flag this Question
If Num = 6.89, what value would be displayed as a result of the following assignment?
Set Num = Ceiling(Num)
Flag this Question
If Number is an integer value, what would be displayed as a result of the following assignment? (Note: if there are any spaces, it is assumed to be one space.)
Set Number = Length_Of("Good-bye!")
Write Number
Flag this Question
The ___________ function computes square roots. (For your answer, enter only the function, not any parameters that the function can carry.)
TrueExplanation / Answer
Question: If Number = 4, what is the range of possible numbers that can result from the following? (Note, this question has 2 parts; you must answer each part correctly to receive full marks. Enter only the numbers in the space provided.)
Floor(Random() * 10) + Number
The range starts at .
The range ends at .
Answer: The range starts at 4 and ends at 10.
Question: Write a random generator statement that produces random integers in the following range; store the result in a variable called Range. (Do not include spaces in your answer.)
1 through 4
Answer: Floor(Random() * 4) + 1
Question: The _____________ function takes a string or a string variable inside the parentheses and returns the number of characters in that string.
Answer: Length_Of function returns the length or we can say number of characters in that string.
Question: If Number = 25, what would be the result of the following conditional statement? True or false?
Sqrt(Number) == Floor(Sqrt(Number))
True
False
Answer: Sqrt(Number) which is sqrt(25) i.e 5
Now Floor(sqrt(25))
Floor(5) and this will return 5
Hence both are equal so True.
Question: If Number is an integer value, what would be displayed as a result of the following assignment? (Note: if there are any spaces, it is assumed to be one space.)
Set Number = Length_Of(" ")
Write Number
Answer: The value will be 0 as this is an empty string.
Question: If Number = 64, what would be the result of the following conditional statement? True or false?
Floor(Sqrt(Number/2)) == Sqrt(Floor(Number/2))
True
False
Answer: First let’s see sqrt(Number/2) which is sqrt(64/2)
Sqrt(32) which is 5.6568 and now if we take floor of this value i.e floor(5.6568) then this will return 5 (smaller nearest number or equal to it). This means
Floor(Sqrt(Number/2)) = 5
Now Sqrt(Floor(Number/2))
Sqrt(Floor(64/2))
Sqrt(Floor(32)) //number nearest smaller or equal to
Sqrt(32)
= 5.6568
5 = 5.6568 which is false.
Question: If Number = 7, what would be the result of the following conditional statement? True or false?
Sqrt(Number) == Int(Sqrt(Number))
True
False
Answer: sqrt(7) will get the square root of the number 7 which is 2.6457 and if we pass this value to Int then it will only return the real part of it and leaves the decimal part hence Sqrt(Number) == Int(Sqrt(Number)) are not equal so false.
Question: The ___________ allows for output from Print statements to occur on a new line.
Numbers that form an unpredictable sequence in which each number is equally likely to occur are called __________ numbers.
Answer: will allow the output to be printed in next line.
Numbers which are unpredictable are called Random numbers.
Question:If Num1 = 5.6 and Num2 = 3, what value would be displayed as a result of the following assignment?
Set Number = Floor(Num1 * Num2)
Write Number
Answer: Floor function returns the value less than or equal to the parameter passed to it.
Now here we are dividing num1 by num2 which is 5.6/3 = 1.866667 or we can say 1.87. Now if we pass this to floor it will return 1 as the nearest less number to 1.87 is 1.
Question: The following random generator code Floor(Random()*6) produces the numbers through . (Note, this question has 2 parts; you must answer each part correctly to receive full marks. Enter only the numbers in the space provided.)
Answer: Here we can see the given equation as Floor(Random() * Number) + 0. Hence the range starts at 0 and range ends at 6
Question: If Num1 = 3.2 and Num2 = 5, what value would be displayed as a result of the following assignment?
Set Number = Int(Num2 - Num1)
Write Number
Answer: Here we have Num2 = 3.2
And Num2 = 5
Now Num2-Num1
= 5-3.2
= 1.8
And now as we have passed this to int which takes only int value and not the decimal value. So the value will be 1.
Question: If Number = 4, what is the range of possible numbers that can result from the following? (Note, this question has 2 parts; you must answer each part correctly to receive full marks. Enter only the numbers in the space provided.)
Floor(Random() * Number)
The range starts at .
The range ends at .
Answer: Here we can see the given equation as Floor(Random() * Number) + 0. Hence the range starts at 0 and range ends at 4.
Question: If Number = 6, what is the range of possible numbers that can result from the following?
Floor(Random() * Number) + 3
The range starts at
The range ends at .
(Note, this question has 2 parts; you must answer each part correctly to receive full marks. Enter only the numbers in the space provided.)
Answer: Here the minimum range or we can say range starts at 3 and range ends at 6.
Question: The random generator code Floor(Random()*6) produces the numbers through . (Note, this question has 2 parts; you must answer each part correctly to receive full marks. Enter only the numbers in the space provided.)
Answer: This will produce random number between 0 to 6.
Question: It's possible to __________ out of a loop if the user has entered an incorrect value that would cause an error or a problem within the loop, or if the user has entered a required response end the program can continue without further iterations of the loop.
Answer: break, which makes it possible to get out of the loop or we can say break the loop.
Question: If Num = 4.22, what value would be displayed as a result of the following assignment?
Set Num = Ceiling(Num)
Write Num
Answer: Ceiling(4.22)
This will return 5 as Ceiling function returns the value equal to or nearest greater value.
Question: If Number = 3.5, what would be the result of the following conditional statement? True or false?
Floor(Number*Number) == Number*Number
True
False
Answer: Here the value of number is 3.5
Number * Number = 3.5 * 3.5
= 12.25
Now Floor(Number*Number) = Floor(3.5*3.5)
= Floor(12.25)
= 12 (as Floor function returns the value equal to or nearest less than to it value).
Hence Floor(Number*Number) = Number*Number
12 = 12.25 is false
Question: If Num1 = 5.6 and Num2 = 3, what value would be displayed as a result of the following assignment?
Set Number = Floor(Num1 / Num2)
Write Number
Answer: Floor function returns the value less than or equal to the parameter passed to it.
Now here we are dividing num1 by num2 which is 5.6/3 = 1.866667 or we can say 1.87. Now if we pass this to floor it will return 1 as the nearest less number to 1.87 is 1.
Question: If Num = 6.89, what value would be displayed as a result of the following assignment?
Set Num = Ceiling(Num)
Answer: The ceiling function returns the smallest near to or equal to the parameter passed to the function and here we have passed 6.89 and the nearest number is 7.
Question: If Number is an integer value, what would be displayed as a result of the following assignment? (Note: if there are any spaces, it is assumed to be one space.)
Set Number = Length_Of("Good-bye!")
Write Number
Answer: It will calculate length of the string which is 9 hence the value of the Number is 9.
Question: The ___________ function computes square roots. (For your answer, enter only the function, not any parameters that the function can carry.)
Answer: sqrt function is used to compute square root
True
Related Questions
drjack9650@gmail.com
Navigate
Integrity-first tutoring: explanations and feedback only — we do not complete graded work. Learn more.