Question
1/ The floored division operator ( // ) can be used to round down the result of a floating - point division to the closest
1/ The floored division operator ( // ) can be used to round down the result of a floating - point division to the closest whole number value. The resulting value is an integer type if both operands are integers; if either operand is a float, then a float is returned. For example, ( 15 // 30 ) returns 0 .
Determine the result of the execution of this expression. 53 // 3
(a) 5 (b) 5.0 (c) 19 (d) 17 (e) 1
2/
The division operator ( / ) performs division and returns a floating - point number.
For example, ( 30 / 10 ) returns 3.0 .
Determine the result of the execution of this expression. 42 / 3
(a) 15.0 (b) 13.0 (c) 14.0 (d) 14 (e) 12
3/
Enter T for True or F for False.
For each of these, assume that variable x is initialized to 5 and variable y is initialized to 9 and that each assignment statement is executed separately from each other.
_____ (1) This assignment statement assigns 10 to x . x += 1
_____ (2) This assignment statement assigns 7 to x . x -= 1
_____ (3) This assignment statement assigns 45 to y . y *= x
_____ (4) This variable expression evaluates to 1 . x // y
_____ (5) This variable expression evaluates to 360 . 19 + x * y + 6
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started