Thread: I Have No Place To Start

  1. #1
    Registered User
    Join Date
    Feb 2005
    Posts
    4

    I Have No Place To Start

    I just came up with a smashing idea for a new program, but I am unsure which language I should learn to write it in. I want to be able to assign, say the "q" key to activate a variable everytime it is pushed. I wish to be able to do this with all the keys but escape. I also want the variable to be a sound, so please tell me what i need to LEARN, or teach me!

  2. #2
    Registered User
    Join Date
    Sep 2001
    Posts
    4,912
    C or C++ should be able to do all that. Start with a tutorial on the basics of said languages.

  3. #3
    Registered User
    Join Date
    Feb 2005
    Posts
    4
    yeah..... about that, do you know any good freeware C compilers, the only ones I have found dont work, and i am -excuse my language- flat on my ass broke~

  4. #4
    Registered User
    Join Date
    Sep 2001
    Posts
    4,912
    Dev-C++ is free and very popular. It works with both C and C++. Go to http://www.bloodshed.net.

  5. #5
    Registered User
    Join Date
    Feb 2005
    Posts
    4
    Wow, that was quick, thank you!

  6. #6
    Registered User
    Join Date
    Feb 2005
    Posts
    4
    YYYAAAARRGGGG!!!!! Ok, so I think to myself, golly gee that sure was helpful, this will be easy now, but no, it cant just be easy. I have gone to many different tutorials, and each of them have a different code for the "hello world program" the dev compiler can run any of my programs, and I see things like this, and have no idea what to do.:
    "To compile this code, type cc samp.c. To run it, type a.out. If it does not compile or does not run correctly, edit it again and see where you went wrong."
    WHERE DO I TYPE cc samp.c, where do i find the box to type a.out, I need a tutorial that will really help me learn, do you guys have any suggestions?

  7. #7
    ---
    Join Date
    May 2004
    Posts
    1,379
    if you are using dev-c++ you dont need to compile through the command line. there should be a compile button there on your top left

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

    Exclamation Don't Give Up!

    I don't use Dev-C++, so I can't directly help... But DON'T GIVE UP. Dev-C++ is one of the most popular free compilers. You should start-out with a popular compiler, so that you can get help.

    Compilers are usually tricky to set-up, configure, learn to use. I've used several (mostly obscure) compilers over the years, and I don't remember any of them working as expected "out of the box". Take your time, read the documentation... carefully! Don't feel bad it it takes you half-a-day to get "Hello World" working.

    One "gotcha" to look out for is the Program Window Dissapearing Before I Can See The Results problem. This is a Windows operating system issue. It's not a problem with C++ or the compiler.

    but I am unsure which language I should learn to write it in.
    C/C++ is the most universal, and most popular programming language. Word, Excel, Windows, and Linux are all written in C/C++. You can get a C or C++compiler for just about any processor/platform. However, it's not the easiest language to learn... There is a lot to it!

    Before you start, you should be aware of the things you can't do in standard C++. Because C++ is portable and will run on any machine, there is no sound, golor, or graphics in standard C++. Also there is no way in standard C++ to get the program to respond to a keypress without hitting the ENTER key. Of course, compilers like Dev-C++ do have additional non-standard libraries to do this stuff.

    And, it takes awhile to learn programming (any language). I usually compare it to learning music. How long does it take to learn to play the guitar?

  9. #9
    Registered User
    Join Date
    Feb 2005
    Location
    unf
    Posts
    16
    for the "disappearing window before the program executes problem" simply type:
    Code:
    system("pause");
    right before the return at the end of main. I know this works in C I dunno about C++

  10. #10
    Registered User
    Join Date
    Jan 2005
    Posts
    106
    Quote Originally Posted by stodd04
    for the "disappearing window before the program executes problem" simply type:
    Code:
    system("pause");
    right before the return at the end of main. I know this works in C I dunno about C++
    about.com's C++ tutorial is pretty helpful. It's probably the worst C++ tutorial in existance, but it really, really helped ME a lot.

  11. #11
    ---
    Join Date
    May 2004
    Posts
    1,379
    Quote Originally Posted by stodd04
    for the "disappearing window before the program executes problem" simply type:
    Code:
    system("pause");
    right before the return at the end of main. I know this works in C I dunno about C++
    the system() function is in the stdlib.h header so it is probably in the cstdlib header (c++).

  12. #12
    and the hat of int overfl Salem's Avatar
    Join Date
    Aug 2001
    Location
    The edge of the known universe
    Posts
    39,659
    > C/C++ is the most universal, and most popular programming language
    C/C++ is not a language - just a horrible mess. No two people will have the same idea as to what should be in C/C++.

    C is a language
    C++ is a language
    While they share a common past, and share many common ideas, C++ is not a superset of C. There are bits of C syntax which work differently in C++, or don't work at all in C++.

    > This is a Windows operating system issue.
    It's an IDE issue - results from running command line programs from a command line prompt do not disappear as soon as the program exits.
    If you dance barefoot on the broken glass of undefined behaviour, you've got to expect the occasional cut.
    If at first you don't succeed, try writing your phone number on the exam paper.

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. Best place to start (I/O question)...
    By badtwistofate in forum C Programming
    Replies: 2
    Last Post: 03-02-2009, 03:34 PM
  2. Were to Start Your Game Programming Carrer
    By C+noob in forum Game Programming
    Replies: 3
    Last Post: 07-14-2005, 01:33 AM
  3. New Monthly Contest!
    By PJYelton in forum Contests Board
    Replies: 50
    Last Post: 03-22-2005, 08:27 PM
  4. A place to start.
    By Grellin in forum Game Programming
    Replies: 0
    Last Post: 10-14-2001, 11:49 AM
  5. Where is a good place to start?!
    By bobthefish3 in forum Game Programming
    Replies: 1
    Last Post: 10-09-2001, 11:28 AM