Page 1 of 1

2. Define a struct fruitType to store the following data about a fruit Fruit name (string),color (string), Lat (int), su

Posted: Sat May 14, 2022 3:58 pm
by answerhappygod
2 Define A Struct Fruittype To Store The Following Data About A Fruit Fruit Name String Color String Lat Int Su 1
2 Define A Struct Fruittype To Store The Following Data About A Fruit Fruit Name String Color String Lat Int Su 1 (15.98 KiB) Viewed 73 times
2 Define A Struct Fruittype To Store The Following Data About A Fruit Fruit Name String Color String Lat Int Su 2
2 Define A Struct Fruittype To Store The Following Data About A Fruit Fruit Name String Color String Lat Int Su 2 (15.98 KiB) Viewed 73 times
2 Define A Struct Fruittype To Store The Following Data About A Fruit Fruit Name String Color String Lat Int Su 3
2 Define A Struct Fruittype To Store The Following Data About A Fruit Fruit Name String Color String Lat Int Su 3 (17.35 KiB) Viewed 73 times
2. Define a struct fruitType to store the following data about a fruit Fruit name (string),color (string), Lat (int), sugar (int), and carbohydrate (int) (35pts) a. Write a function definition called getFruitinput that takes an input file stream reference and a fruitType reference as parameters. The function should read values from a file and store data into the variable of fruitType parameter. b. Write a function called printFruitInfo that takes an input file stream reference and a fruitType as parameters. The function should output data stored in the fruitType Parameter.

2. Define a struct fruitType to store the following data about a fruit: Fruit name (string), color (string), fat (int), sugar (int), and carbohydrate (int). (35pts) a. Write a function definition called getFruitInput that takes an input file stream reference and a fruitType reference as parameters. The function should read values from a file and store data into the variable of fruitType parameter. b. Write a function called printFruitInfo that takes an input file stream reference and a fruitType as parameters. The function should output data stored in the fruitType Parameter.