.


4 - 4


:

if p = 0 then

begin

write(' ', n, ' ');

writeln(' ')

end

else

writeln(' ', p)


, , :

Program Problem7;

uses WinCrt;

var

i, j, n, k, p : longint;

begin

write(' '); readln(n);

k := 0; i := 1;

while i*i*i + 1 <= n do

begin

k := k + 1; i := i + 1

end;

p := 0;

for i := k downto 1 do

for j := 1 to i do

if i*i*i + j*j*j=n then

begin

p := p + 1;

writeln(i, '*', i, '*', i, '+', j, '*', j, '*', j, '=', n)

end;

if

p = 0

then

begin

write(' ', n, ' ');

writeln(' ')

end

else writeln(' ', p)

end.

Program Problem7b;

uses WinCrt;

label 1, 2;

var

i, j, m, k, n : longint;

begin

write(' '); readln(n);

m := 0; i := 1; j := 1;

while j*j*j + 1 < n do j := j + 1;

repeat

k := i*i*i + j*j*j;

if k = n then m := m + 1;

if k <= n then i := i + 1;

if k >= n then j := j - 1;

until i > j;

if m = 0 then goto 1;

write(' ',n,' ');

writeln(' ',m,' '); goto 2;

1: write(' ');

writeln(' ');

2: end.

6

n. n ? , x, y, z ,

. .