Basic number guessing game in java