program prog3; {$APPTYPE CONSOLE} uses SysUtils, windows; var a:array[1..100000000] of byte; j,k,n,i:integer; time:int64; begin readln(n); time:=gettickcount; a[1]:=1; for i:=2 to round(sqrt(n)) do begin if a[i]=0 then begin j:=i*i; while(j<=n)do begin a[j]:=1; j:=j+i; end; end; end; {for k:=1 to n do if a[k]=0 then write(k,' '); writeln; }time:=gettickcount-time; writeln(time/1000:0:5); readln; { TODO -oUser -cConsole Main : Insert code here } end.