Page 1 of 1

C++

Posted: Mon Jun 07, 2010 12:14 pm
by floogle11
Lately ive wanted to program in C++ but my C++ thing hasnt worked so i trashed it and do any of you know a free C++ thing i can download. (not codeblocks i tried it but it wasnt running my programms)

Posted: Mon Jun 07, 2010 9:27 pm
by bongomeno
I would recommend learning C first. It is easier.

for that, maby you would like the TinyC compiler. Just a compiler, but no IDE.

Posted: Tue Jun 08, 2010 3:57 am
by Anonymous
I like using Bloodshed Dev C++ you can download it here http://bloodshed-dev-c.en.softonic.com/

Posted: Tue Jun 08, 2010 9:00 am
by bongomeno
A nice little C++ compiler that I have made use of in the past is CIDEE. http://cidee.sourceforge.net/

Posted: Tue Jun 08, 2010 11:57 am
by floogle11
Thanks guys i really needed somthing more complex to program in.

Posted: Tue Jun 08, 2010 12:13 pm
by floogle11
HEy with dev C++ i compile my prog and i try to run it but it says it hasnt been compiled yet?

Posted: Tue Jun 08, 2010 12:19 pm
by floogle11
wait now i compiles but when i run it it just closes out

Posted: Wed Jun 09, 2010 2:19 am
by Anonymous
try putting system("pause"); as the last statement in main()

Posted: Wed Jun 09, 2010 10:44 am
by floogle11
still dosnt work

Posted: Wed Jun 09, 2010 4:08 pm
by Anonymous
Try running this code

Code: Select all

#include <iostream>

using namespace std;

int main()
{
    cout << "Hello World" << endl;
    system("pause");
    return 0;
}

Posted: Thu Jun 10, 2010 11:57 am
by floogle11
thank you

Posted: Thu Jun 10, 2010 12:44 pm
by floogle11
ok now im trying to run this but it wont work:
heres the code that im using:

Code: Select all

#include <iostream>
int Add (int x, int y)
{
    cout << "In Add(), recieved " << x << " and " << y << endl;
    system ("pause");
    return (x+y);
}

int main()
{
    cout << "im in main() " << endl;
    int a, b, c;
    cout << "enter two numbers: " <<endl>> a;
    cin >> b;
    cout << "calling Add() " << endl;
    c=Add(a, b);
    cout << "back in main()" << endl;
    cout << " c was set to" << c << endl;
    cout << " exiting...." << endl;
    system ("pause");
    return 0;
}

Posted: Thu Jun 10, 2010 4:18 pm
by Anonymous
Works fine for me. What error are you getting?

Posted: Thu Jun 10, 2010 4:25 pm
by floogle11
srry i changed it it started working but what i just put up i dont know what its doing when i try to run it. Im confused is it end1 or endl at the end of cout <<

Posted: Fri Jun 11, 2010 2:17 am
by Anonymous
it is endl for end line

Posted: Fri Jun 11, 2010 11:21 am
by floogle11
oh ok, do you just have any tutorials i hate asking questions or know were any are.

Posted: Fri Jun 11, 2010 3:18 pm
by Anonymous

Posted: Sat Jun 12, 2010 1:35 pm
by floogle11
Thanks a lot i wont ask many questions any more.