Program hren;
uses crt;
var a:integer;
BEGIN
<span>writeln ('How old are you?');
read(a);
a:=60-a;
</span><span>writeln ('years you have ',a);</span>
END.
Я конечно не супер умная, но по идее должен быть ноль, сам подставь)
#include <iostream>
using namespace std;
int gcd(int a, int b);
int main()
{
freopen("input.txt", "r", stdin);
freopen("output.txt", "w", stdout);
int n;
cin >> n;
for (int i = 0; i < n; ++i)
{
int a, b, c, d;
scanf("%d/%d+%d/%d=", &a, &b, &c, &d);
int num = a * d + b * c;
int den = b * d;
int cur_gcd = gcd(num, den);
num /= cur_gcd;
den /= cur_gcd;
cout << num;
if(den != 1)
cout << '/' << den;
<span> cout << endl;
</span> }
fclose(stdin);
fclose(stdout);
return 0;
}
int gcd(int a, int b)
{
if(a == 0)
return b;
return gcd(b % a, a);
}
Def f(x):
if x > 2:
return x*x+ 4*x + 5
else:
return 1/(x*x+4+x5)