Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #include <iostream>
- #include <iomanip>
- using namespace std;
- int main()
- {
- double q=0,r=0,k=0,sum=0,d=0;
- int f[11][11];
- cin>>q>>r>>k;
- for(int i=0;i<q;i++)
- {
- for(int z=0;z<r;z++)
- {
- cin>>f[i][z];
- if(z>=k)
- {
- sum+=f[i][z];
- d++;
- }
- }
- }
- if(d==0){cout<<"NO"<<endl;}else{cout<<sum<<endl;}
- return 0;
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement