I have an interview soon, and they notified me that I would be speaking with a developer about the online coding problem I solved before (as my first screening). I didn't get 100% on that, but I figured out a much better way of implementing it (I think it's perfect now). I was debating whether to tell the developer that I thought about it beforehand and figured out a new solution, or to have him ask me, pretend I'm thinking, then say my new solution like I just thought of it. Would this make a difference?
Should I pretend that I thought of the new solution on the spot?
No. It's a form of lying and even if you don't consider that a huge deal (it is in the workplace), this particular lie is easy to give away in the follow-up conversation. It's also much, much better to be seen as having thought more on your initial solution after the first screen, recognised that it wasn't perfect and have figured out a much better implementation.
The fact that you'll specifically be discussing that problem means that they probably wanted you to do exactly this. They want to see if you'd consider the problem further when the time constraint was dropped and see if you're able to improve on it. And why would you think that pretending like you haven't even thought about it is a good thing, when they told you they'd revisit it?
Let's pretend you're a master plumber and you're interviewing a novice plumber. You know beforehand this novice took a test and you reviewed his solution and found he used a o-ring instead of a washer to fix a leaking pipe. You thought of all these questions and you enter the interview. At the interview you ask him, "So why did you use a o-ring?" And he sits there staring up in the sky pondering long and hard and suddenly said, "I came up with it all by my lonesome self and thought it was a great solution but I don't understand why you'd use a washer."
Would you feel you want to be around someone like that?