Code::Blocks Forums

User forums => Help => Topic started by: ikkesomye on January 11, 2011, 12:47:14 am

Title: First program.
Post by: ikkesomye on January 11, 2011, 12:47:14 am
I am completely new to any programming language.  I am just sort of following this youtube video making your first C++ program and even though I have followed it step by step when I build and run nothing happens.

I'm sure you have all heard this question before I am just really lost.

This was the youtube video
http://www.youtube.com/watch?v=qkilWa5sX9Y

The website I am learning from
http://www.cprogramming.com/tutorial/lesson1.html

thanks to those willing to help me out.
Title: Re: First program.
Post by: ikkesomye on January 11, 2011, 01:00:10 am
#include <iostream>

using namespace std;

int main()
{
  cout<<"HEY, you, I'm alive! Oh, and Hello World!\n";
  cin.get();

  return 0;
}

Title: Re: First program.
Post by: ollydbg on January 11, 2011, 01:37:52 am
Welcome!!!
Quote
I'm sure you have all heard this question before I am just really lost.
what is your question?? Did you search the forum firstly??
we discuss only Code::blocks related question here, if you would like to discuss some programming question, I suggest you can go to some forum dedicate to that issue.
Title: Re: First program.
Post by: ikkesomye on January 11, 2011, 02:06:30 am
my bad sorry.  Basically I am running and building the program and nothing is happening.  I am not getting the same command prompt hellow world! message the user in the video is getting.
Title: Re: First program.
Post by: ollydbg on January 11, 2011, 02:55:22 am
en, what the exact steps did you do? also please describe your OS? C::B version? compiler version......

Quote
Basically I am running and building the program and nothing is happening.
this statement has no sense. (you just say: I have a problem which we all know)
Title: Re: First program.
Post by: ikkesomye on January 11, 2011, 03:10:18 am
windows 7
codeblocks 10.05

#include <iostream>

using namespace std;

int main()
{
    cout <<"hello world";
    cin get();
    return 0;
}

clicking the button to build and run like said in video.

Nothing happens.
Title: Re: First program.
Post by: ikkesomye on January 11, 2011, 03:30:31 am
C++
Title: Re: First program.
Post by: ollydbg on January 11, 2011, 05:34:49 am
clicking the button to build and run like said in video.
Nothing happens.
what have you done before you click the button??
...
I don't want to see a whole tutorial to see what the step you take. ( the video takes 10 min)
I suggest you can just use the project wizard to create a simple console program, then test again.
Title: Re: First program.
Post by: ikkesomye on January 11, 2011, 06:30:25 am
thanks for your help.