Gilb wrote:
Jameson wrote:
Gilb wrote:
using <stdio.h>
main()
{
printf("this is the last post so far/n ps i do know that there will be many problem with this source code because i haven't programmed c in a long time");
}
You forgot to give main() a return type. I suggest "void main()" since you don't have a return statement, though to be proper C it's a good idea to have "int main(int argc, char** argv)" and a "return 0" later in your code.
Morning all.
looking at an old 1980's C book
the term is "include" not using (that is C#

)
there is a missing # on the preprocessor command Include
i remember being told that i should always give main() a return type but in this case it doesn't matter
though i am just a newbie when it gets to programming, i have no idea what "char** argv" actually does
Don't know how I missed seeing the include mistakes... "using" is in C++ too, for declaring namespace usage.
The variables in the main declaration are used to pass information to the program when calling it from the command line. The int is the number of arguments, and the char** is an array of character arrays (array of strings basically, holds the arguments). So you can call a program like "prog.exe arg1 arg2" and as a result, argc=3, argv[0]="prog.exe", argv[1]="arg1", and argv[2]="arg2". Most people will do "char* argv[]" instead of "char** argv", but the two are equivalent.
_________________
Air·is·water·with·holes·in·it. Think·honk·if·you're·a·telepath. Never·call·a·man·a·fool.·Borrow·from·him. A·tautology·is·a·thing·which·is·tautological. Hi!·I'm·a·.signature·virus!·Copy·me·into·your·~/.signature·to·help·me·spread!