Untitled

mail@pastecode.io avatar
unknown
c_cpp
7 months ago
525 B
0
Indexable
Never
#include <iostream>
using namespace std;

void agekoresh(int age) {
	setlocale(LC_ALL, "russian");
	if (age >= 10 and age <= 19) {
		cout << "молод";
	}
	if (age >= 20 and age <=29) {
		cout << "бывалый";
	}
	if (age >= 30 and age <= 39) {
		cout << "старый";
	}
	if (age >= 40 and age <= 49) {
		cout << "таких не бывает";
	}
	if (age < 10 || age > 40) {
		cout << "какой то перец";
	}
}

int main()
{
	int a;
	int b = 0;
	cin >> a;

	agekoresh(a);
}