Charas-Project
Off-Topic => Really Old Stuff => Archive => General programming => Topic started by: maxine on September 12, 2005, 05:26:27 AM
-
ok.. I havent been her so much lately. I have been busy in school and in my class we have c++... We´ve pretty much just learnt how too make a program which draws a text on the black screen or simply just multiplies the number you type in (Variable).
//Bla bla bla
#include
using namespace std;
int main()
{
<< cout "Hello Charas" << endl;
getchar ();
return o;
}
that is for example but i need a tutorial of some more variables etc.
thanks in advance
-
Okay, first,
<< cout "Hello Charas" << endl;
Should be
cout << "Hello Charas" << endl;
Second of all, you havent put in a variable for Getchar() to record.
EDIT: You're right, you don't need a .c after iostream.
#include
int main {
int o, p, q
cout << "Please enter a number to be multiplied." << endl;
o = Getchar();
cout << endl; << "Please enter a second number to be mutliplied." << endl;
p = Getchar();
q = o * p
cout << endl; << o << " times " << p << " equals " << q << endl;
}
Granted, it's been awhile since I touched C++ and that's probably wrong in a few places, but meh.
Also, Google is your friend (http://www.google.com/search?hl=en&q=c%2B%2B+tutorials&btnG=Google+Search).
-
oh yeah i did a mistake with the <<... But i didnt have too make iostream.c i only needed iostream in class.. And i know how too make the number multiply itself, and what i asked was a good page for some extended coding of variables and other stuff.. But i can see you know coding =)...
EDIT: ive tried google but havent founded any really good pages... So if anyone know any good ones feel free too tell them too me :D
-
Taken from the link to Google in my post above, this (http://www.cprogramming.com/tutorial.html#c++tutorial), this (http://www.cplusplus.com/doc/tutorial/), and this (http://www.intap.net/~drw/cpp/) all look like good tutorials to me.
-
thanks man really nice