begin
        comment
                        ALGOL Praktikum, Dr. Karl Nickel, 1964,
                        page 215 (Aufgabe 40)

                ``Teilsummen-Formel nach Euler.
                  Loesung von Doz. Dr. R. Wagener.
                  Elegantissimum''
        ;


        integer N, H, U, K ;  integer array S[0:200] ;


        for N := 1 step 1 until 200 do

        begin   S[0] := N ;  S[N] := 0 ;  H := U := -1 ;

                for K := N-1 step H until 0 do

                begin   S[N] := S[K] + S[N]*U ;

                        H := ((3+U)*H - 2) / (3-U) ;

                        U := -U

                end ;

                S[N] := abs( S[N] ) ;

                outinteger (1, N);
                outinteger (1, S[N]);
                outstring (1, "\n")
        end
end
