6. |
Create a JSP page that uses a JavaBean to compute the amount of time a user has been alive.
Create a page that allows a user to enter his birth date. Allow the option of entering his time of birth. Use a JavaBean to calculate the number of years, months, and days the user has been alive. If the user enters a time, also calculate the number of hours and minutes the user has been alive. Sample output:
You have lived for 32 years, 2 months, 15 days, 12 hours, and 5 minutes.
Answer:
|