void count(int n) { if (n<0) cout << "n must be positive.." << endl; else if (n>10) cout << "done counting..." << endl; else { cout << n << endl; count (n+1); } }
void count(int n)
{
if (n<0)
cout << "n must be positive.." << endl;
else if (n>10)
cout << "done counting..." << endl;
else
{
cout << n << endl;
count (n+1);
}
}