Thread: Hi Im new here. Need some advice

  1. #1
    Registered User
    Join Date
    Jul 2004
    Posts
    18

    Hi Im new here. Need some advice

    Hi everyone. Im new on this forum and in C++.

    Tomorrow Im going to buy some C++ books and I hope they helps me a lot..

    Programming is my hobby so I desided to start with simple games. What do you recommend to me to try first?

    I know some basics like type of vars, statements, arrays etc. But today I was read something about pointers and it seems like new to me.

    P.S What a lovely forum I like that tag feature -.-

    P.P.S In addition, Im going to take care on my english grammar and find approporiate book for it :P Sorry, Im not living in england or us and usually Im using english only for reading :\
    Last edited by rockdj; 07-21-2004 at 01:47 PM.

  2. #2
    C(++)(#)
    Join Date
    Jul 2004
    Posts
    309
    If I remember right (only learned this today myself): pointers take a piece of date from one section of memory and place it in another.


    As for trying something first: I would suggest doing text-based games before 2d - and learn C++ before that

  3. #3
    Registered User
    Join Date
    Sep 2001
    Posts
    4,912
    No. A pointer just contains a memory location. It's sort of like an address. As you learn more C++, you'll understand the need for this. Pointers took a long time for me to understand.

    Text based games would be a good place for a newbie to start. They're simple and will teach you a lot about logic and program flow.

    And don't worry too much about your English. I was able to understand you fine, and there are a lot of people on the board who live in England and America but are so lazy in typing that no one can understand them - so your English is fine!

  4. #4
    Registered User
    Join Date
    Mar 2004
    Posts
    180
    I find this site to be really helpfull.

    Also, what compiler thingy are you using? Dev-C++, Visual C++, Borland C++ Builder, etc?

    Good luck!

    DW

  5. #5
    Registered User axon's Avatar
    Join Date
    Feb 2003
    Posts
    2,572
    welcome to our forums!

    here is a good thread about starting game programming, especially pay attention to Bubba's reply http://cboard.cprogramming.com/showt...light=start%3F

    here is another thread about starting C++ http://cboard.cprogramming.com/showt...light=start%3F

    for book recomendations do a search on this board an you will get tons of threads. Other then that, make sure you read the forum guidelines and rules, and make sure to use code tags whenever posting code.

    enjoy

    some entropy with that sink? entropysink.com

    there are two cardinal sins from which all others spring: Impatience and Laziness. - franz kafka

  6. #6
    C(++)(#)
    Join Date
    Jul 2004
    Posts
    309
    Quote Originally Posted by sean_mackrory
    No. A pointer just contains a memory location. It's sort of like an address. As you learn more C++, you'll understand the need for this. Pointers took a long time for me to understand.
    Eh....thats...even more confusing o_O

  7. #7
    Registered User
    Join Date
    Mar 2002
    Posts
    1,595
    I think of it like this. Memory is a thing that has a beginning and an end (that is it is a finite resource.). An address is how far away from the beginning to look. The distance is a number. A pointer holds the distance from the start of memory that a particular piece of information is. In other words a pointer tells you where to look, but it doesn't tell you what's there. You can dereference a pointer to find out what's there if you want to, so that information is indirectly available for your use. However, the pointer just contains the address, not the information per se. You can also use the pointer to change the information at the address if you want to, rather than just locate or access the information, but that may be more than you want to know right now.

  8. #8
    C(++)(#)
    Join Date
    Jul 2004
    Posts
    309
    Quote Originally Posted by elad
    I think of it like this. Memory is a thing that has a beginning and an end (that is it is a finite resource.). An address is how far away from the beginning to look. The distance is a number. A pointer holds the distance from the start of memory that a particular piece of information is. In other words a pointer tells you where to look, but it doesn't tell you what's there. You can dereference a pointer to find out what's there if you want to, so that information is indirectly available for your use. However, the pointer just contains the address, not the information per se. You can also use the pointer to change the information at the address if you want to, rather than just locate or access the information, but that may be more than you want to know right now.
    THANK YOU!!! That makes much more sense then the book///tuturials iv been reading.

  9. #9
    Registered User
    Join Date
    Feb 2004
    Posts
    35
    Personally I think pointers are so confusing because every reference say they are, or hint at it in some or other way.

    Yeah, a pointer is like a bookmark, or a note with the pagenumber on it.

  10. #10
    Hardware Engineer
    Join Date
    Sep 2001
    Posts
    1,398

    Exclamation You don't need to learn pointers on the first day.

    I guess pointers are confusing because they have to do with what's going on inside the computer.

    All variables reside at a particular physical memory location (address). Most of the time you don't need to know their address. You only need to know the variable's name.

    A pointer is a variable that holds the address of another variable. So, it "points to" a variable. Again, you normally don't need to know the addresses... you only need to know the name of the pointer, and the name of the variable that it points to.

    My standard homework analogy:
    Bob has the homework answers. Bob is a normal variable. If you know that Bob has the answers, you can directly ask him..

    If Sally doesn't know the answers but she knows where Bob lives, she's a pointer.

    If don't know Bob, but you know Sally, you can use what is called dereferencing and tell Sally "Go get the answer". (You dereference simply by writing *Sally.)

    If you forget to dereference, Sally will give you Bob's address... This is NOT what you want!

    rockdj,
    You will study functions before you study pointers. Everything in C++ is done with functions. You will learn that a function can return only one value. For example, a function can return a single character, but not a full sentence (i.e. a string variable). A single pointer can give your function access to the whole string.

  11. #11
    Registered User
    Join Date
    Jul 2004
    Posts
    18
    Thanks for your feedback guys.

    Today I have bought the book named "C++: How To Program Third Edition" written by Deitel & Deitel. I live in Russia so I don't have a chanse to use an online shop like amazon.com for buying recommended books. No one working with us.. Our shipment system is too retard One time I have made an order in our russian online shop... What time do you think I waited? TWO MONTH ! Finally when a shop manager has called me to confirm the deal.. I have been confused - I simply forgot about this order.. I told him 'HA-HA' and made cancel. So sad and so true for russia... I think that I newer shall see books like 'how to make rpg' etc They newer will be in russia shops

    Ok. I stop it. Sorry If I bored any of you guys

    Also, what compiler thingy are you using? Dev-C++, Visual C++, Borland C++ Builder, etc?
    Visual C++ and MS dev C++ 6.0.

    As for trying something first: I would suggest doing text-based games before 2d - and learn C++ before that
    Yep. Its 'hard truth' but its necessary to study some theory before you can do something you like

    So I started to read the book... I Hope the theory will not be very boring and annoying.

  12. #12
    01000011 00100000 0010000
    Join Date
    Jul 2004
    Posts
    38
    A good book that I have been reading is called "C++ from the ground up." Written by Herbert Schildt (a member on the ANSI C++ board, which is a group of people who write up all the regulations for the C++ language). It's not like a lot of the books out there that are for beginners and take you up to moderate level, and then you have to buy the other book that goes with the book you just bought for moderate to advanced levels. Like a lot of the VB books I have been reading, which is very annoying. This book goes from the basics (in fact the first 6 chapters are really just review on the lessons hosted here on the website) to the most advanced topics in C++. Also, once you have read the book you will know the entire C++ language. Though he doesn't go into specific areas such as Windows programming which includes the MFC (Microsoft Foundation Classes). Though he does mention it. A good idea, if you are doing windows programming is to read this book, and then buy a book for programmers that know C++, but would like to learn the MFC. I really think that "C++ from the ground up." is a great book for beginners (like me). I have already gone through about 1/3 of the book, and with the information I have learned I am writing a D&D style RPG game (With spells, equipment, battling, and all that good RPG stuff). Keep in mind that the entire book is Console Programming based. Like I said earlier, if you wanna do windows specifically learn C++ then MFC.

  13. #13
    Registered User
    Join Date
    Jul 2004
    Posts
    18
    I have already gone through about 1/3 of the book, and with the information I have learned I am writing a D&D style RPG game (With spells, equipment, battling, and all that good RPG stuff).
    Yeah.. Its just great! I dream to be able to make things like that.

    Like I said earlier, if you wanna do windows specifically learn C++ then MFC.
    Ok. I'll memorize that. Thanks.

  14. #14
    Registered User
    Join Date
    Sep 2001
    Posts
    4,912
    A good book that I have been reading is called "C++ from the ground up." Written by Herbert Schildt (a member on the ANSI C++ board, which is a group of people who write up all the regulations for the C++ language).
    If that's the same guy who thinks any C code will compile under C++ he shouldn't be on the ANSI board.

    Rockdj - You can get a lot of good tutorials on-line. It's always nice to have a good book or two - but if it's tough to get books in Russia, there's always Google - it's great for learning how to do anything.

  15. #15
    Registered User
    Join Date
    Jul 2004
    Posts
    18
    It's always nice to have a good book or two - but if it's tough to get books in Russia, there's always Google - it's great for learning how to do anything.
    Google is useful forsure but all we know that books are better for digging into something special like programming.
    I have no choose so I will make my best with googling..

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. Advice on C Programming with MSVC++ 2008
    By IT_Guy in forum Windows Programming
    Replies: 1
    Last Post: 03-06-2009, 04:23 AM
  2. girl friend advice (prob. the wrong place)
    By B0bDole in forum A Brief History of Cprogramming.com
    Replies: 15
    Last Post: 10-22-2004, 06:38 PM
  3. need advice on project
    By lambs4 in forum C Programming
    Replies: 2
    Last Post: 07-23-2003, 01:06 PM
  4. need hardware advice....
    By forgottenPWord in forum Tech Board
    Replies: 5
    Last Post: 03-23-2003, 09:12 AM
  5. Newbie: Seek advice
    By gogo in forum C++ Programming
    Replies: 4
    Last Post: 11-06-2001, 10:04 AM