Nouvelle formation ! Tous les codeurs devraient apprendre l'IA générative !
Essayez une leçon gratuite0
Does a blank print statement have any effect on the other print statement(s)?
4 Réponses
+ 2
∆BH∆Y exactly what i said , the first print statement sets the value of end to " " , the next statement sets it to "\n".
+ 1
blank print statement prints a new line as the default argument for one of it's paramter "end" is newline character.
+ 1
unless you specify an empty string for optional 'end' named argument, a 'blank' print will at least output the default new line character ^^
+ 1
where is the problem?
inside loop with blank print you're writing a new line after each item, even if they doesn't end with a new line...