{$A+,B-,C+,D+,E-,F-,G+,H+,I+,J+,K-,L+,M-,N+,O+,P+,Q+,R+,S+,T-,U-,V+,W-,X+,Y+,Z1}
{$MINSTACKSIZE $00004000}
{$MAXSTACKSIZE $00100000}
{$IMAGEBASE $00400000}
{$APPTYPE CONSOLE}

{TL tests}

uses SysUtils;
const maxN = 10000;
const test = 21;

var a:array[1..maxN] of integer;
    TestNo : integer;
procedure AntiQuickSort1(n:integer);
var i,w,m:integer;
begin
for i:=1 to n do a[i] := i;
for i:=2 to n do
  begin
  m := (1 + i) shr 1;
  w := a[m];a[m] := a[i];a[i] := w;
  end;
end;
procedure AntiQuickSort2(n:integer);
var i,w,m:integer;
begin
for i:=1 to n do a[i] := i;
for i:=2 to n do
  begin
  m := (1 + i + 1) shr 1;
  w := a[m];a[m] := a[i];a[i] := w;
  end;
end;

procedure AntiQuickSort3(n:integer);
{random without randseed initialization}
var i,w,m:integer;
b:array[1..maxN] of integer;
begin
for i:=n downto 1 do b[i] := 1+random(i);
for i:=1 to n do a[i] := i;
for i:=2 to n do
  begin
  m := b[i];
  w := a[m];a[m] := a[i];a[i] := w;
  end;
end;

procedure nextFile;
var s:string;
begin
s := IntToStr(TestNo);
if TestNo < 10 then s := '0' + s;
inc(TestNo);
Assign(output,s);Rewrite(output);
end;
procedure printA(n:integer);
var i:integer;
begin
nextFile;
writeln(n,' ',1);
for i:=1 to n do
  begin
  writeln((5 - (4.9 / n) * a[i]) : 0 : 5,' 1');
  end;
close(output);
end;

var i,n:integer;
begin
TestNo := test;
n := maxN;
AntiQuickSort1(n);
printA(n);
AntiQuickSort2(n);
printA(n);
AntiQuickSort3(n);
printA(n);
{Array in reverse order}
for i:=1 to n do a[i] := n + 1 - i;
printA(n);
end.
