Question: a. Write a C++ program to create a structure called Pet Shop with the variables Pet Name, Pet Colour and Pet Price. You have to

 a. Write a C++ program to create a structure called Pet

a. Write a C++ program to create a structure called Pet Shop with the variables Pet Name, Pet Colour and Pet Price. You have to create two structure variables and enter the Pet Name, Pet Colour and Pet Price for two. Finally, you have to calculate the total pet price. Display the details as shown below. Pet Name Pet color Black Cat Price 12.250 18.825 Parrot Green b. Using file handling, write a C++ program to create a file called 'Petshop.text' and write the following details into the file in the format shown below. Pet Name Pet color Price Cat Black 12.250 Parrot Green 18.825

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!