Ask coding questions

← Back to all posts
Why is this printing on multiple lines?
Brendan23 (166)

if you run the repl, input random letters(has to be more than 1), it should be like https://replit.com/@ZarmDev/Intro
but instead it prints on multiple lines! what is the problem, and, if you know how, how do I fix it?

Comments
hotnewtop
Coder100 (18123)

Don't forget to add flush=True as well

print("hi", end = "", flush = True)
Brendan23 (166)

@Coder100 I added that, it doesn't quite work out.

JBloves27 (1882)

This could be happening from the second print in the for loops.
It prints letters_lower[i], but because it doesn't have end="", I think it may be the reason for this.

Hope this helps!

Brendan23 (166)

@JBloves27 That makes it worse!(no offense) if you run it now, when I have added that, it's even worse.

JBloves27 (1882)

It seems like it's working tho? @Brendan23

Brendan23 (166)

@JBloves27 it's supposed to have the searching through letters effect/the printing and clearing letters until it find the right one effect though.

JBloves27 (1882)

Ohh, ok. I think I know what you mean. Let me get some code for you, is that ok? @Brendan23

JBloves27 (1882)

Sorry for late reply, I was trying to find solution. But do you mean something like this? If not, I can tweak it a bit to make it fit to your bidding :)

https://replit.com/@JBloves27/PunyTepidSupercollider#main.py

@Brendan23

Brendan23 (166)

@JBloves27 I want it like https://replit.com/@ZarmDev/Intro . (in otherwords no) I want it to look like https://replit.com/@ZarmDev/Intro
except no extra z at the end.
Sorry for being a bit bossy.