Answered step by step
Verified Expert Solution
Question
1 Approved Answer
I need guidance in doing this for the given produc generated REQUIRED LIBRARIES Library name Purpose iostream contains definitions of cin, cout, endl, and input/output
I need guidance in doing this
for the given produc generated REQUIRED LIBRARIES Library name Purpose iostream contains definitions of cin, cout, endl, and input/output operators cstdlib contains rand() and srand() for random number generation string contains definition of type string chrono contains definitions of time functions Other you may include other libraries as needed for additional functionality you wish to add. DATA STRUCTURE Write a CH class called ID_stamp that you will save in a file called ID_stamp.h which has the following: Private data members: variable named stamp of type integer variable name desc of type string for product description Public function members: These functions should be declared in the class and defined outside the class. Input data function that has no parameters and returns nothing. The function should display a message prompting for input of a description string. It should then read keyboard input of a string (you may use getline()). Your program then extracts the current time using now() function of chrono. This is passed to the rand() function to generate an integer that will be considered the unique identifier assigned to stamp. Display data function that outputs both the entered string and the stamp to the screen with description and formatting added. Definitions of the member functions should be saved in a file called ID stamm cnn PROCESSING Write a main() function that instantiates (declares) an object of type ID_stamp. Next, a prompt of number of items to stamp is displayed followed by reading an integer. A loop is then entered that runs as many times as the integer just read and does the following: call the input data function call the display data function The main() function and all code associated with it should be saved in a file called ID_stamp_driver.cppStep by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started