(In C++) Include the appropriate function prototypes using an object called myStuff and private member variables. Create
Posted: Thu May 05, 2022 12:43 pm
(In C++)
Include the appropriate function prototypes using an object
called myStuff and private member variables.
Create an implementation file that will initialize default
values: firstName, lastName, age, shoeSize and declare/initialize
class function prototypes. Shoe size should be a double for 'half'
sizes - 8.5, 11.5, etc.
Declare appropriate datatypes and variables for user input.
(four total)
Your program should prompt users to enter their first name and
last name. Then enter their age, then enter their shoe size.
Use appropriate set/get functions to manipulate the user
values.
Create a class member object to print out the user's values.
All numeric output to two (2) decimal places.
External functions:
External functions require a function prototype before the main()
and the declarations after the main().
An external 'void' function to calculate the radius of a circle if
the area is a product of age and shoe size. Hint: use sqrt(), const
pi is 3.14159.
An external 'void' function to draw a 6x6 two-dimensional array
placing the age in the first position and the shoe size in the last
position. Hint: set the default value to zero.
A class function to count the vowels and consonates of the
user's first and last name. Hint: isVowel() program.
A class function to add the ASCII values of the letters of the
user's first and last name.
A class function to convert the user's first and last name to a
10-digit phone number output as xxx-xxx-xxxx. Hint: Alter the
telephone digit program.
All class functions that require formal parameters will use the
object.get*** as the actual parameter - myStuff.get***
All class functions without formal parameters (empty functions)
must use a get*** statement to initialize values.
Appropriate comments for code blocks/functions.
Include the appropriate function prototypes using an object
called myStuff and private member variables.
Create an implementation file that will initialize default
values: firstName, lastName, age, shoeSize and declare/initialize
class function prototypes. Shoe size should be a double for 'half'
sizes - 8.5, 11.5, etc.
Declare appropriate datatypes and variables for user input.
(four total)
Your program should prompt users to enter their first name and
last name. Then enter their age, then enter their shoe size.
Use appropriate set/get functions to manipulate the user
values.
Create a class member object to print out the user's values.
All numeric output to two (2) decimal places.
External functions:
External functions require a function prototype before the main()
and the declarations after the main().
An external 'void' function to calculate the radius of a circle if
the area is a product of age and shoe size. Hint: use sqrt(), const
pi is 3.14159.
An external 'void' function to draw a 6x6 two-dimensional array
placing the age in the first position and the shoe size in the last
position. Hint: set the default value to zero.
A class function to count the vowels and consonates of the
user's first and last name. Hint: isVowel() program.
A class function to add the ASCII values of the letters of the
user's first and last name.
A class function to convert the user's first and last name to a
10-digit phone number output as xxx-xxx-xxxx. Hint: Alter the
telephone digit program.
All class functions that require formal parameters will use the
object.get*** as the actual parameter - myStuff.get***
All class functions without formal parameters (empty functions)
must use a get*** statement to initialize values.
Appropriate comments for code blocks/functions.