what exactly is the problem? you cant just make up problems and ridicule the code for not solving them when the coder had no idea he was supposed to be solving them.
This solution (and whatever solution you might have in mind) likely both dont solve all sorts of problems. for instance what if there is a power failure and you lose all the output? is it persisting to disk? what if new input methods that arent even thought of it come to exist 5 years from now, is it compatible with that?
> This solution (and whatever solution you might have in mind) likely both dont solve all sorts of problems. for instance what if there is a power failure and you lose all the output? is it persisting to disk? what if new input methods that arent even thought of it come to exist 5 years from now, is it compatible with that?
You are missing the point. The code doesn't work. I'd love to hear any interpretation of the problem where that code actually is correct.
This solution (and whatever solution you might have in mind) likely both dont solve all sorts of problems. for instance what if there is a power failure and you lose all the output? is it persisting to disk? what if new input methods that arent even thought of it come to exist 5 years from now, is it compatible with that?