Thread: What first program? Please read it

  1. #1
    Registered User Gades_GD's Avatar
    Join Date
    Nov 2001
    Posts
    46

    Question What first program? Please read it

    I've seen lots of threads about what book you should buy to learn C, and many questions from newbies (like me, under Gades) because they're working on their first project. And sometimes "this" project probably is not the most appropiate.

    So, my question is about what type of program should we start with? I'm not talking about the "hello world" type, I'm talking more of something like making a personal phone book, a calculator, etc.

    So please, I think this thread would be very interesting for everyone starting, could you give your opinion?

    As a second part of the question, I'd like you guys to say which one was (more or less) your first program as a newbie; saying what was more difficult of it, and if you'd recommend it.

    Thans for replying to this thread (because I guess you will )
    Gades Yacht Design

  2. #2
    "The Oldest Member Here" Xterria's Avatar
    Join Date
    Sep 2001
    Location
    Buffalo, NY
    Posts
    1,039
    it depends on what you know....if you know alot then go on to a Tic Tac Cut off my toe game with AI, but if you're sort of a newbie, then do a calculator.

    and mine was a calculator

  3. #3
    Registered User Gades_GD's Avatar
    Join Date
    Nov 2001
    Posts
    46
    Thanks for your reply Xterria.

    I've seen a couple of times on the games board that people suggest to do this game (Tic Tac Cut...), but I don't even know the game!!

    So you think a calculator is a good program for a newbie.

    Would you post it? It's not for me (right now I have more than enogh with my program ), but for anyone who is starting.

    It's a shame not more people answer this thread, I think it'd be very helpful. If I'm wrong, please let me know. I can't help too many people answering questions at the C board, so I thought this was a good idea.
    Gades Yacht Design

  4. #4
    the Corvetter
    Join Date
    Sep 2001
    Posts
    1,584
    I'll tell you what my first (useful) program was. Summed up, it read a file (file I/O) and put questions from the setup file into a linked list (advanced pointers) and then randomly asked questions and received user input (I/O) and then decided if the question was right.

    --Garfield
    1978 Silver Anniversary Corvette

  5. #5
    "The Oldest Member Here" Xterria's Avatar
    Join Date
    Sep 2001
    Location
    Buffalo, NY
    Posts
    1,039
    I did that calculator before some program formatted my harddrive. Never made one since (that just occurred to me) but after that, I made a tic-tac-toe game(Visual C++)

  6. #6
    Former Member
    Join Date
    Oct 2001
    Posts
    955
    My first FULL program was a recursive solution to the Hanoi's towers problem, I made it in VB, would you like to see it? (program is in spanish though)

    Oskilian

  7. #7
    Registered User Gades_GD's Avatar
    Join Date
    Nov 2001
    Posts
    46
    As soon as I pass this subject (C Programming), I want to learn Visual Basic, so please post it.

    But what is Hanoi's towers problem?
    Gades Yacht Design

  8. #8
    Registered User Gades_GD's Avatar
    Join Date
    Nov 2001
    Posts
    46
    >.....(view the program),.......

    Where is it? Did you try to attach it?
    Gades Yacht Design

  9. #9
    Former Member
    Join Date
    Oct 2001
    Posts
    955
    Hanoi's towers is an ancient problem which consists of three towers and some rings of progressive sizes, the game begins with all the rings in the far left tower organized the bigger one below, and the idea is to move them all to the far right tower with these two rules:

    1. you can only move one ring at a time
    2. there can never be a bigger ring on tom of a smaller one

    check it out

    P.S. I couldn't attach the program properly the previous time, so use this one

    Oskilian
    Last edited by oskilian; 11-18-2001 at 05:12 PM.

  10. #10
    Registered User Gades_GD's Avatar
    Join Date
    Nov 2001
    Posts
    46
    Xterria: I tried to compile your code and it doesn't, can you post the executable program?

    Thanks
    Gades Yacht Design

  11. #11
    Registered User Gades_GD's Avatar
    Join Date
    Nov 2001
    Posts
    46
    Garfield: would you post your exe file? Just to have a better idea of what you did.



    I can't believe people don't reply more to this thread. Lot's of you guys reply to questions; some easy ones, some difficult ones. How come you don't answer this one? Can you tell me if there's something wrong about this idea?
    Gades Yacht Design

  12. #12
    It's full of stars adrianxw's Avatar
    Join Date
    Aug 2001
    Posts
    4,829
    >>> people don't reply more to this thread

    You can't make people reply if they are not interested in replying. One reason they may not be interested is that they've already seen this type of thread many times before, just a few days ago, for example, there was a "What should be my next program" thread on the C++ board...

    By the way, my first program read a deck of punched cards, averaged some values and then produced a batch job which passed the data to a statistical analysis package.
    Wave upon wave of demented avengers march cheerfully out of obscurity unto the dream.

  13. #13
    the hat of redundancy hat nvoigt's Avatar
    Join Date
    Aug 2001
    Location
    Hannover, Germany
    Posts
    3,130
    My first program ? My first program printed a joke to the screen.
    Incredibly boring but took me about a day in Basic...

    The first real program was a character creator for AD&D. Took a while too, because I had to code the GUI myself. I.e. Button = Colored rectangle with a special function called when clicked inside. No OOP, no classes, no predefined stuff.

    Whatever you do as a first, make it short, make it easy and make something motivating. What that is depends on your own taste and speed of learning.

    Re: Replies: Keep in mind this is a messageboard. I checked this morning and didn't see your thread, I checked now, and there it is. In the US, people are getting up while I write this.
    hth
    -nv

    She was so Blonde, she spent 20 minutes looking at the orange juice can because it said "Concentrate."

    When in doubt, read the FAQ.
    Then ask a smart question.

  14. #14
    Registered User Gades_GD's Avatar
    Join Date
    Nov 2001
    Posts
    46
    I'm sorry if I've been rude and thanks for your replies.

    >"What should be my next program" thread on the C++ board...

    Sorry, I only read the C board and the GD, that's why I didn't see it. I've seen the other board maybe a couple of times, but I don't follow them at all.
    Gades Yacht Design

  15. #15
    It's full of stars adrianxw's Avatar
    Join Date
    Aug 2001
    Posts
    4,829
    >>> I'm sorry if I've been rude and thanks for your replies

    You've not been rude, I was simply suggesting a reason why people may not have replied. It is, of course, also true what NV said, many members have not logged on yet today...
    Wave upon wave of demented avengers march cheerfully out of obscurity unto the dream.

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. I read my program on gcc but have to run on bcc...
    By philae in forum C Programming
    Replies: 4
    Last Post: 03-06-2006, 08:28 PM
  2. Replies: 3
    Last Post: 03-04-2005, 02:46 PM
  3. Program to help you read faster
    By Nutshell in forum A Brief History of Cprogramming.com
    Replies: 4
    Last Post: 07-19-2003, 02:06 PM
  4. Read a file into a loop program
    By TimeClock in forum C Programming
    Replies: 5
    Last Post: 07-17-2003, 06:29 PM
  5. read data
    By in_need in forum C Programming
    Replies: 2
    Last Post: 10-30-2001, 08:10 AM