0

In place operators

So I wrote this code, was wondering why the third output was 3460 My input was 5 x=2 x*=3 print(x) y=6 y/=x print(y) a=12 a*=int(input(34)) print(a) #output 6 1.0 3460 Again my input was 5 Thanks if anyone could explain this. https://code.sololearn.com/cSopUm1L3C5n/?ref=app

15th Apr 2021, 5:56 PM
Reginald Gray
1 Odpowiedź
+ 2
It writes the 34 from input(34) and after that the 60 from 5*12. Without a new line it shows 3460
15th Apr 2021, 6:41 PM
Coding Cat
Coding Cat - avatar