What is the result of this code? >>> x = "a" >>> x *= 3 print(x) | Sololearn: Learn to code for FREE!
Novo curso! Todo programador deveria aprender IA generativa!
Experimente uma aula grƔtis
0

What is the result of this code? >>> x = "a" >>> x *= 3 print(x)

25th Mar 2020, 4:50 AM
Ugochukwu Celestine
1 Resposta
+ 1
Here a will print 3 times x = "a" x *= 3 x = "a" * 3 = aaa when we multiply any string with number n that string will print n times.
25th Mar 2020, 5:54 AM
AĶ¢J
AĶ¢J - avatar