I appreciate you trying to learn - really I do, however:
most people when trying to learn something new start with the basics and don't just jump into something they 'want' or find interesting.. if you start to learn how to play guitar or piano, you're not going to be playing Steve Vai, or Mozart right away, you start with stupid simple stuff. Same with programming - you start with the basic concepts, you don't just jump into Hacking, D3D etc.
If you don't even know that you need to have functions (or even a main function like david above me mentioned) to put your code in, let alone how to write one from scratch I AGAIN highly suggest you take a break from whatever project you're wanting to work on, and start with Hello world, adding 2 numbers, or other SIMPLER programs until you can do those in your sleep. Then once you understand the concepts of how a C++ program is even supposed to be structured you can move on to the more 'fun' projects..
Otherwise what's gonna end up happening is the only way your project would be 'fixed' is where 'we' write everything for you, you copy & paste it, hit compile and go off saying 'you' wrote something while really you didn't etc etc and if you have read some of the other threads, we really frown upon that type of behavior. And i could tell you: Put this here and that there, but what does that do for you? Nothing since you'll have no idea WHY you had to make the change.
On the flipside, we always encourage and help out people who are truly trying to learn how to program C++ / C / ASM etc who have intelligent questions.
Anyway, Not even knowing what a (main) function is and why it's required, which is usually explained on page 1 or 2 of any C++ book/tuturial unfortunately comes across as someone who does NOT want to learn, but wants to leech. If that's not the case, then make the effort to learn things properly
Again - not trying to be a dick - but that's how it is.