Code written for LaunchCode's class on Java