//---------------------------------------------------------------
//
// r3.cpp
//
// Another example of a recursive function: countdown
//
// Written by: Simon Parsons
// Date: 28th November 2007
//

#include <iostream>
using namespace std;

void countDown (int n) {
  if ( n <= 0 )
    cout << "Blastoff!" << endl;
  else {
    cout << "Time to launch is " << n << " seconds" << endl;
    countDown(n - 1);
  }
} // end of factorial()


int main() {
  countDown(10);
}
