Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #include <iostream>
- #include <cstdio>
- #include <iomanip>
- using namespace std;
- int main() {
- // your code goes here
- double a, sum[5]={0, 0, 0, 0, 0};
- const int n = 5;
- for(int i=0; i<n; i++){
- for(int j=0; j<n; j++){
- cin>>a;
- sum[i]+=a;
- }
- }
- for( int i=0; i<n; i++){
- cout <<fixed <<setprecision(4) <<sum[i] <<' ';
- }
- return 0;
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement