pls what is the result of this code if not true print("1") elif not(1+1==3): print("2") else print("3") | Sololearn: Learn to code for FREE!
Nouvelle formation ! Tous les codeurs devraient apprendre l'IA générative !
Essayez une leçon gratuite
+ 3

pls what is the result of this code if not true print("1") elif not(1+1==3): print("2") else print("3")

2nd Sep 2016, 4:59 PM
anthony
7 Réponses
+ 12
The answer is 2 'cause "if not True" gives False which means the program goes to elif. "Not 1+1 ==3" is True which means the program print 2
2nd Sep 2016, 5:27 PM
Дима
Дима - avatar
+ 1
thnx.
11th Sep 2016, 5:11 PM
Tarun Kumar Patnaik
Tarun Kumar Patnaik - avatar
0
2 is the answer
2nd Sep 2016, 5:28 PM
karthikeya N S
karthikeya N S - avatar
0
Thanks guys
2nd Sep 2016, 5:44 PM
anthony
0
2
12th Sep 2016, 5:23 AM
Fredrik
Fredrik - avatar
0
2 bcos if not makes false
10th Jul 2017, 9:22 PM
Ishaku Ibrahim
Ishaku Ibrahim - avatar
- 1
2
22nd Dec 2016, 11:01 AM
CRAZINESS BLACKNESS
CRAZINESS BLACKNESS - avatar