Hi guys, having abit of trouble getting the login box goin. Could you please provide me with correct code for the below?
I need to:
prompt for and input user name
prompt for and input user number
while the user number is not between 1 and 500 inclusive
warn the user the number is not in the correct range
prompt for and input user number
set identifier to first letter of username, followed by hyphen, followed by user number
write out the user name
write out user number
write out identifier
We don't supply "answers" like that, but you are obviously half-way there, so please show us what you have got so far, and we shall be happy to discuss it.
You already wrote the pseudo-code, so all you need to do is translate each line to actual code. Console (since Java 6) and Scanner (since Java 5.0) can help you out a lot.