0
Print 'for loop' without add new line
The default print in python is make a new line. How to print sequence in a same line using for loop?
2 odpowiedzi
+ 1
print function in Python has more parameters than you think. you can set the 'end' parameter, which is '\n' by default, to '' (these are two single quotes). there will be no new line after this print.
print ('abc', end='')
print ('def')
0
Thanks buddy, it's works