// Program: GuentherRaphaela.cpp
// making F -> F
#include
#include
//POST: the word w_i^F will be drawn.
void f(const unsigned int i) {
if (i==0)
ifm::forward();
else {
f(i-1);
f(i-1);
ifm::left (63);
ifm::save();
ifm::left (63);
f(i-1);
ifm::left (40);
f(i-1);
ifm::right(63);
f(i-1);
ifm::right(63);
f(i-1);
ifm::restore();
ifm::right(63);
ifm::save();
ifm::right(63);
f(i-1);
ifm::left(63);
f(i-1);
ifm::left(63);
f(i-1);
ifm::restore();
}
}
int main() {
std::cout << "Number of iterations =? ";
unsigned int n;
std::cin >> n;
ifm::left(90);
f(n);
return 0;
}