output:
input :
in this all variable are initialised from i=0,j=0,sm=0,k=1,a[3]="" and after loop start it will take input from file and after taking input it will check for the i value if its less than 3 it continue else it will move out of loop after entering the i loop the j loop start that will add the sum with input data untill j value is less than 12 and after j loop a[k] will store the value for particular month into the array for example <1> is for first year and <2> is for 2nd year and so on.
If you found this answer helpful please give a thumbs up.
Get Answers For Free
Most questions answered within 1 hours.