Department of Computer Science | Institute of Theoretical Computer Science | CADMO

Theory of Combinatorial Algorithms

Prof. Emo Welzl and Prof. Bernd Gärtner

// Program: BoehlerMario.cpp // Autor: Mario Bhler (Gruppe O) // No iterations: 5-7 #include #include // necessary: x and y call each other void y (int i, int j); //void z (int i, int j); int b = 0; void x (const int i) { for ( int j = 6; j > 0; --j) { y(i,1); ifm::left(60); } } void y (int i, int j) { if (i <= 1) ; else { y(i-1,j); ifm::forward(20/i/j); y(i-1,j); ifm::right(30); y(i-1,j+1); ifm::left(60); y(i-1,j+1); ifm::left(150); ifm::forward(20/i/j); ifm::left(180); } } int main () { std::cout << "Number of iterations =? "; unsigned int n; std::cin >> n; // draw w_n = w_n(F) x(n); return 0; } //iteration mit .. 8?