#include <cstdio>
#include <cstdlib>
#include <iostream>
using namespace std;
digits()
{
If(num==1)
cout<< "one";
}
int main(int nNumberofArgs, char* pszArgs[])
{
int num;
cout << "Enter a number 1 to 9:";
cin >> num;
digits();
system("pause");
return 0;
}
I just want to make a simple function that when asked for a number 1-9
it returns and outputs the spelling of that number.
ie. you input the number 1 and cout returns "one"
very very basic no error checking or anything indepth. I just cant seem to figure how to name the function and how to hand off an integer and return the spelling.
I've seen examples of math and handing off equations, but i'm slow in the department of comprehension when it comes to coding and making minor tweaks that change the program just errors out. thanks in advance