0

Solve this problem and select correct 💯 ans 🙏â˜ș and comment me right answer

Whats the output of this code? A = 4/3 B = 3/2 print(A < B)

10th Jan 2024, 3:23 PM
Shashank Pandey
Shashank Pandey - avatar
8 Respostas
+ 6
Anshul Sharma , the code that is shown in the post is in *python*. > all divisions in python are resulting in a *float* number, not in int. > A is: 1.3333333333333333 > B is: 1.5
11th Jan 2024, 4:17 PM
Lothar
Lothar - avatar
+ 6
Shashank Pandey please evaluate your print statement ... The forum is for questions and answers related to code issues not for quizlets.
10th Jan 2024, 4:25 PM
BroFar
BroFar - avatar
+ 5
Shashank Pandey , is this a question or a kind of quiz?
10th Jan 2024, 3:42 PM
Lothar
Lothar - avatar
+ 3
Shashank Pandey this question is a Quizlet ... The question and answer forum is for actual code related concerns. Please use the forum as intended. Secondly I did not give you a boolean answer as to your Quizlet.
11th Jan 2024, 3:28 PM
BroFar
BroFar - avatar
+ 1
True is output
10th Jan 2024, 4:45 PM
Shashank Pandey
Shashank Pandey - avatar
+ 1
this is correct if you consider the code is not in python but a snippet of Java. where default is int. A=4/3 A is int by default. A=1; B=3/2 B is also int by default B=1; A=B therefore A<B is false Output: false
11th Jan 2024, 2:41 PM
Anshul Sharma
+ 1
Then the case is differnt you are correct Lothar, thankyou for correcting I thought it to be java
11th Jan 2024, 7:12 PM
Anshul Sharma
+ 1
A gives 1.333333 while B gives 1.5 the code requires that you A less than B be displayed on the scr5
11th Jan 2024, 8:51 PM
Paul
Paul - avatar