uses 
    tools;
var
    t, i, j: longint;
begin
    randseed := 4085095;
    generateLineSpan(1000, 5, 100);
    generateRandomSpan(1000, 5, 100);
    addRandom(10000, 100);
    setTightData();
    for i := 1 to m div 2 do begin
        j := m - i + 1;
        t := a[i]; a[i] := a[j]; a[j] := t;
        t := b[i]; b[i] := b[j]; b[j] := t;
        t := l[i]; l[i] := l[j]; l[j] := t;
    end;
    output();
end.
