Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Implement the following functions in Ada programming language: One way to estimate the height of a child is to use the following formula, which uses

Implement the following functions in Ada programming language:

One way to estimate the height of a child is to use the following formula, which uses the height of the parents:

For male child:

HChild=((Hmother *15/12)+Hfather)/2

For female child:

HChild=((Hfather *14/13)+Hmother)/2

All heights are in inches. Write a program that takes as input parameters the gender of the child, height of the mother in inches, and height of the father in inches, and outputs the estimated height of the child in inches. The user should be able to input the heights in inches, feet or centimeters, and the program should output the estimated height of the child in inches, feet and in centimeters. Use the integer data type to store the heights.

1 cm = 0.393701 inches

1 feet = 12 inches

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_2

Step: 3

blur-text-image_3

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

Microsoft SQL Server 2012 Unleashed

Authors: Ray Rankins, Paul Bertucci

1st Edition

0133408507, 9780133408508

More Books

Students also viewed these Databases questions