Been reading a text book on Java and have gotten to some exercises. I'm a complete beginner and was wanting some advice. I would rather an answer that points me in the right direction rather than giving me the straight up answer.
I need to write a program that takes a four-digit integer from the user and then prints it out on the screen one digit per line
for example: Input = 1993
The program should display it as follows:
I believe I need to use arrays but am not quite sure. I'm using a Scanner for the user input but don't know how to assign each number to a separate variable, if that's even the way I should go about it. If anyone could help I would very much appreciate it. Thanks!
Post a Reply
|Oldest Newest Rating|
Java / Android Development
Very popular language used to create desktop applications, website applets, and Android apps.
|Bucky Roberts Administrator|