} // end birthYear class } // end main method } // end of calculate method import java.util.*; int ageInput= console.nex

Business, Finance, Economics, Accounting, Operations Management, Computer Science, Electrical Engineering, Mechanical Engineering, Civil Engineering, Chemical Engineering, Algebra, Precalculus, Statistics and Probabilty, Advanced Math, Physics, Chemistry, Biology, Nursing, Psychology, Certifications, Tests, Prep, and more.
Post Reply
answerhappygod
Site Admin
Posts: 899603
Joined: Mon Aug 02, 2021 8:13 am

} // end birthYear class } // end main method } // end of calculate method import java.util.*; int ageInput= console.nex

Post by answerhappygod »

End Birthyear Class End Main Method End Of Calculate Method Import Java Util Int Ageinput Console Nex 1
End Birthyear Class End Main Method End Of Calculate Method Import Java Util Int Ageinput Console Nex 1 (294.25 KiB) Viewed 39 times
} // end birthYear class } // end main method } // end of calculate method import java.util.*; int ageInput= console.nextInt(); // Define variable for age & get value int birthYear calculate(year Input, ageInput); // calculate birth year int calculation year - age; int yearInput console.nextInt(); // Define variable for year & get value = = // Library for console input = * * @author (your name) * @purpose (Calculates the user's birth year based on their current age and current year) * @version (a version number or a date) public class birthYear { public static int calculate(int year, int age) { // Calculate birth year public static void main(String[] args) { return calculation; Scanner console = new Scanner(System.in); // Define scanner variable System.out.print("You were born in "+ birthYear); // display to console System.out.println("Please enter the current year: "); System.out.println("Please enter your age: ");
Join a community of subject matter experts. Register for FREE to view solutions, replies, and use search function. Request answer by replying!
Post Reply