int main() #Fil in the code to define and indialize to 1 the variable month float total = 0, rain, cout


int main()<br>#Fil in the code to define and indialize to 1 the variable month float<br>total = 0, rain,<br>cout << Enter the total rainfall for month<br><month << endl,<br>cout << Enter-1 when you are finished

Extracted text: int main() #Fil in the code to define and indialize to 1 the variable month float total = 0, rain, cout < enter="" the="" total="" rainfall="" for="" month="">< endl,="" cout="">< enter-1="" when="" you="" are="">< endl="" w="" fill="" in="" the="" code="" to="" read="" in="" the="" value="" for="" rain="" w="" fill="" in="" the="" code="" to="" start="" a="" while="" loop="" that="" iterates="" #="" while="" rain="" does="" nor="" egual-1="" of="" fill="" in="" the="" code="" to="" update="" total="" by="" adding="" it="" to="" rain="" cout="">< "enter="" the="" total="" rainfall="" in="" inches="" for="" month="" "="">< month="">< endl="" cout="">< "enter-1="" when="" you="" are="" finished"="">< endl="" w="" fill="" in="" the="" code="" to="" read="" in="" the="" value="" for="" rain="" }/end="" of="" while="" loop="" if="" (month="=" 1)="" cout="">< "no="" data="" has="" been="" entered"="">< end!;="" else="" cout="">< "the="" total="" rainfall="" for="" the="">< month-1="">< "months="" is="">< total=""><><- endl="" return="" 0="" question="" (ulo="" 2-c="" task="" b)="" 1.="" run="" the="" program="" several="" times="" with="" various="" input.="" record="" your="" results.="" are="" they="" correct?="" 2.="" what="" happens="" if="" you="" 3.="" what="" happens="" if="" you="" enter="" only="" values="" of="" 0="" for="" one="" or="" more="" months?="" 4.="" is="" there="" any="" numerical="" data="" that="" you="" should="" not="" enter?="" enter-1="">
DAVAD CITY<br>ULO (2-c): While loop- Task B<br>1946<br>/ This program illustrates the use of a sentinel in a while loop.<br>/ The user is asked for monthly rainfall totals until a sentinel<br>/ value of -1 is entered. Then the total rainfall is displayed.<br>#include <iostream><br>using namespace std,<br>

Extracted text: DAVAD CITY ULO (2-c): While loop- Task B 1946 / This program illustrates the use of a sentinel in a while loop. / The user is asked for monthly rainfall totals until a sentinel / value of -1 is entered. Then the total rainfall is displayed. #include using namespace std,

Jun 11, 2022
SOLUTION.PDF

Get Answer To This Question

Related Questions & Answers

More Questions »

Submit New Assignment

Copy and Paste Your Assignment Here