Hãy nhập câu hỏi của bạn vào đây, nếu là tài khoản VIP, bạn sẽ được ưu tiên trả lời.
![](https://rs.olm.vn/images/avt/0.png?1311)
vì \(2^n-1\) là số nguyên tố nên tổng các ước của \(2^n-1\) là \(1+2^n-1\)
tổng các ước của \(2^{n-1}\left(2^n-1\right)\) là \(\displaystyle\Sigma ^{n-1}_{i=0}(2^i)\times (1+2^n-1)\)\(=\left(2^n-1\right)\times2^n=2\left[2^{n-1}\left(2^n-1\right)\right]\)
Vậy số đã cho là số hoàn hảo
![](https://rs.olm.vn/images/avt/0.png?1311)
![](https://rs.olm.vn/images/avt/0.png?1311)
program bai_toan;
var
N, i, sum: integer;
begin
write('Nhap so N: ');
readln(N);
write('Cac uoc cua ', N, ' khong ke ', N, ' la: ');
for i := 1 to N - 1 do
if N mod i = 0 then
write(i, ' ');
writeln;
sum := 0;
for i := 1 to N - 1 do
begin
if N mod i = 0 then sum := sum + i;
end;
if sum = N then writeln(N, ' la so hoan hao')
else writeln(N, ' khong phai la so hoan hao');
writeln;
writeln('Tat ca so hoan hao trong pham vi 1 -> ', N, ' la:');
for i := 1 to N do
begin
sum := 0;
for j := 1 to i - 1 do
begin
if i mod j = 0 then sum := sum + j;
end;
if sum = i then writeln(i);
end;
readln;
end.
![](https://rs.olm.vn/images/avt/0.png?1311)
![](https://rs.olm.vn/images/avt/0.png?1311)
n=1
vì 12 + 5.1+1 =1+5+1=7 (thỏa mãn vì 7 là số nguyên tố)
Vậy n = 1
![](https://rs.olm.vn/images/avt/0.png?1311)