Untitled
unknown
c_cpp
2 years ago
418 B
7
Indexable
#include <iostream>
using namespace std;
int sumar(int a, int N, int M, int S, int B) {
int Szem = N * M;
int stoumZemla = Szem * a;
int sumaDom = S * B;
int allSuma = stoumZemla + sumaDom;
cout << allSuma;
return allSuma;
}
int main() {
int a;//stoumost
cin >> a;
int N, M;//dlina
cin >> N >> M;
int S;//plochad doma
cin >> S;
int B;//dom
cin >> B;
sumar(a,N,M,S,B);
}Editor is loading...
Leave a Comment