Computer Science, asked by isha9922, 1 month ago

2. Write the output:- a = 4.5 b = 2 print (al/b)
a 2.1
b 2
c 2.0
d 3

Answers

Answered by bishansingh26894
9

Answer:

2 answer

Explanation:

a1/b

4.5×1=4.5/2

4.5/2 answer

Answered by varshamittal029
4

Concept:

// Divides the left operand by the right operand, rounds down the result, and returns a whole number.

Given:

a = 5.6\\b = 2 \\print (a//b)

Find:

Find the output of the given program.

Solution:

Floor Division("/"): The division of operands yields a quotient where the digits following the decimal point are deleted. However, if one of the operands is negative, the result is floored, which means it is rounded away from zero (towards negative infinity).

So, in the given program:

a = 5.6\\b = 2 \\print (a//b)

Output:

2.0

Hence option (c) is correct.

Similar questions