Untitled

 avatar
unknown
c_cpp
a year ago
418 B
1
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);
}
Leave a Comment