Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- Var R: integer=4;
- Function yUpO(x: integer):integer;
- begin
- yUpO := trunc(sqrt(R*R - x*x));
- end;
- Var
- xL, xR, yUp, yDown, n: integer;
- BEGIN
- writeln('Radiys = ', R);
- n := 0;
- for xR := 1 to R do
- for yUp := 1 to R do
- if (yUpO(yUp) >= yUp) and (yUpO(xR) >= xR) then
- inc(n);
- n := n*4;
- writeln('Kol-vo kvadratov 1x1 = ', n);
- readln;
- END.
Add Comment
Please, Sign In to add comment