Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Write a JAVA code that would initialize a variable containing an age of a person, then calculate and print the age of a person's age

image text in transcribed

Write a JAVA code that would initialize a variable containing an age of a person, then calculate and print the age of a person's age in terms of: a) months; b) days; c) hours; and d) seconds. Note: Use current date as your reference. You may use manual counting for days since there are months with 28, 30 and 31 days. TEST RUN; Input: 1 year old Birthday: February 21, 2020 OUTPUT; a. Months= 12 months b. days= 365 days c. hours= 8760 hours d. seconds= 31,536,000

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Repairing And Querying Databases Under Aggregate Constraints

Authors: Sergio Flesca ,Filippo Furfaro ,Francesco Parisi

2011th Edition

146141640X, 978-1461416401

More Books

Students also viewed these Databases questions

Question

Explain how the checkpoints regulate the cell cycle,

Answered: 1 week ago

Question

1. The evaluation results can be used to change the program.

Answered: 1 week ago

Question

5. To determine the financial benefits and costs of the program.

Answered: 1 week ago