. . Click on the title for the solution . . This is the answer: : int num; ifstream outFile; outFile.open("numbers"); cin >> num; int a,sum=0; for(int i=0; i<num; i++) { outFile>> a; sum = sum+a; } cout << sum << endl; outFile.close();
. . Click on the title for the solution . . This is the answer: : int max_width = winarr[0].getWidth(); if (winarr[0].getWidth()==winarr[1].getWidth() && winarr[1].getWidth()==winarr[2].getWidth()) cout<<"0"; if (max_width < winarr[1].getWidth()) cout<<winarr[1].getWidth(); if (max_width < winarr[2].getWidth()) cout<<winarr[2].getWidth(); if (max_width>winarr[1].getWidth() && max_width>winarr[2].getWidth()) cout<< winarr[0].getWidth();
Comments
Post a Comment