Design Statement Write a MATLAB script that will determine a person's age based on the birth...
Fantastic news! We've Found the answer you've been seeking!
Question:
Transcribed Image Text:
Design Statement Write a MATLAB script that will determine a person's age based on the birth date that is input. The script should determine the age in years, weeks, days, hours, minutes, and seconds and output that information using the formatting shown below. The output should also include the user's name, birth date, and the current date. As of today, 21-Jun-2018, Joe Student, who was born on 4-15-1997, is officially: 21.18 years old. 1105.37 weeks old 7737.62 days old. 185702.81 hours old. 11142168.48 minutes old 668530108.58 seconds old 2. Two useful functions are now and datenum. When learning about datenum, you are encouraged to use help (and not doc) and start by looking at the examples at the end of the help information. 3. Include your basic pseudocode as a comment block at the end of your script. 4. The script must: a. Be fully commented using the conventions covered in this unit. b. Use screen-directed input. c. Display all output in the command window such that following the last line Design Statement Write a MATLAB script that will determine a person's age based on the birth date that is input. The script should determine the age in years, weeks, days, hours, minutes, and seconds and output that information using the formatting shown below. The output should also include the user's name, birth date, and the current date. As of today, 21-Jun-2018, Joe Student, who was born on 4-15-1997, is officially: 21.18 years old. 1105.37 weeks old 7737.62 days old. 185702.81 hours old. 11142168.48 minutes old 668530108.58 seconds old 2. Two useful functions are now and datenum. When learning about datenum, you are encouraged to use help (and not doc) and start by looking at the examples at the end of the help information. 3. Include your basic pseudocode as a comment block at the end of your script. 4. The script must: a. Be fully commented using the conventions covered in this unit. b. Use screen-directed input. c. Display all output in the command window such that following the last line
Expert Answer:
Answer rating: 100% (QA)
Age Calculator Script Prompt user for their name name inputPlease enter your name s Prompt user for ... View the full answer
Related Book For
Posted Date:
Students also viewed these programming questions
-
Write a Matlab script that describes the dynamics of Pressure and Flow in the systemic arteries and Left Ventricle. Assume that : 1) Pressure in the Left atrium (PLA) and in the Systemic Veins (Psv)...
-
Write a MATLAB script to plot the efficiency as a function of electric power output for the induction generator of Problem 6.17 as the slip varies from -0.5 to -3.2 percent. Assume the generator to...
-
Write a MATLAB script to plot a set of per-unit power-angle curves for a salient-pole synchronous generator connected to an infinite bus (V bus = 1.0 per unit). The generator reactances are X d =...
-
The following is a summary of the petty cash transactions of Jockfield Ltd for May 2012. You are required to: (a) Rule up a suitable petty cash book with analysis columns for expenditure on cleaning,...
-
Explain the relationship between planning materiality and tolerable misstatement when using PPS sampling.
-
The Hotshots are a professional hockey team with a long tradition of winning. However, over the past three years, the team has not won a major championship, and attendance at games has dropped...
-
Assume that IHOP paid \(\$ 10\) per share to purchase 1,000 of its \(\$ 1\) par common as treasury stock. The purchase of treasury stock a. Decreased total equity by \(\$ 10,000\) b. Increased total...
-
From its first Red Lobster in 1968, Darden Restaurants has grown the chain to 690 locations, with over $2.6 billion in U.S sales annually. The casual dinning market may be crowded, with competitors...
-
Channing Tate sells his farm, Magic Meander, to Chris Hemsworth for R 5000 000. Chris takes occupation of the farm. Despite a letter of demand, Chris fails to make any payments for the purchase price...
-
Moeco has issued some commercial paper with 6 months to repayment and a face value of $9.5 million and it just sold in the open-market for $3.2 million. What is the implied effective annual rate of...
-
Ms. Chiu moved from Toronto to Vancouver to start a new job. She earned $40,000 from her Toronto job and $50,000 from her Vancouver job in the year of the move. Ms. Chiu incurred the following costs...
-
Your company has been contracted to manage the renovation of an office building. The client has provided a strict deadline for the project, but the scope of work is still being defined. How will you...
-
Nash Magazine sold 10,080 annual subscriptions on August 1, 2025, for $13 each. Prepare Nash's August 1, 2025, journal entry and the December 31, 2025, annual adjusting entry, assuming the magazines...
-
Water vapor contained in a piston-cylinder assembly undergoes an isothermal expansion at 200C from a pressure of 7.9 bar to a pressure of 2.8 bar. Evaluate the work, in kJ/kg.
-
In the YouTube video, "The Most Important Video You Will Ever See", Professor Al Bartlett from the University of Colorado at Boulder states that he believes the biggest shortcoming of the human race...
-
Part 3. Transaction Analysis (18 T). Journalize the following transactions. Including the correct accounts involved, and the correct application of debits and credits. Date 3.1 Prepare journal...
-
Calculate the accelerated repayment of debt tranche 2. Accelerated repayments are made in order of seniority. Year 0 Year 1 Assumptions Debt tranche 1 mandatory repayment (900.0) Debt tranche 2...
-
Fill in each blank so that the resulting statement is true. A solution to a system of linear equations in two variables is an ordered pair that__________ .
-
Consider the magnetic circuit of Figure. This structure, known as a pot-core, is typically made in two halves. The N-turn coil is wound on a cylindrical bobbin and can be easily inserted over the...
-
When operated at rated voltage and frequency, a three-phase squirrel-cage induction motor (of the design classification known as a high-slip motor) delivers full load at a slip of 8.7 percent and...
-
The wound rotor of Problem 11.24 will be used to drive a constant-torque load equal to the rated full-load torque of the motor. Using the results of Problem 11.24, calculate the external rotor...
-
Find the area under the standard normal curve to the right of a. z = 0.47 b. z = 2.91 c. z = 2.04 d. z = 1.09
-
Find the area under the standard normal curve that lies outside the interval between a. z = 0.38 and z = 1.02 b. z = 1.42 and z = 1.78 c. z = 0.01 and z = 2.67 d. z = 2.45 and z = 0.34
-
Find the area under the standard normal curve that lies outside the interval between a. z = 1.11 and z = 3.21 b. z = 1.93 and z = 0.59 c. z = 0.46 and z = 1.75 d. z = 2.73 and z = 1.39
Study smarter with the SolutionInn App