Results 1 to 9 of 9

Thread: Totally new to 'C'

  1. #1

    Thread Starter
    Member
    Join Date
    May 2000
    Posts
    43
    Okay i have only just become interested in programming c (i mean just this second) and i just want to know what i need to start (eg programs) and where i can get them and for how much?????

    Also is it possible to make windows like in vb using c or c++?????

    Oh one last thing where can i get basic tutorials on how to program useful c (when i say useful i mean not a program that adds 1 and 17 for example :o), )
    Thanx
    Cease

    This post has been brought to you with the help of:

  2. #2
    Guest
    You might have to start out with programs that add 1 and 17. C++ is not something you learn over night. Generally, it takes much longer than VB to learn.

    Yes, using C++, you can make Windows Applications. What you need to start is a compiler. That will depend on which one you want. Two of the more popular ones are Borland C++ and Visual C++. You can get the Modal Edition of Visual C++ for $60 CDN. The Professional and Enterprise edition's are a little more expensive, although, I believe you can get it at acedemic pricing for $100 USD, if you are a student.

    You can find some tutorials and Discussion Forums at http://www.planet-source-code.com.


  3. #3
    Frenzied Member
    Join Date
    Jul 1999
    Posts
    1,800

    Smile

    I had bought a box, learn C in 24 hours, in the box was the sams book for C and the learning edition of Borland C++ 3.0(I think) And it shows how to add and everything, it is really good so far. Look for it, its in a yellow box, and it was only $30.

    to add 1 and 17(if my memory searves me right, I don't have the book with me):
    Code:
    #include <stdio.h>
    
    int integer_add(x, y);
    Add = x, y;
    return int;
    
    int main()
    {
    int integer_add(1, 17);
    Add = (x + y)
    return 0;
    }
    hope that helps any

  4. #4
    Monday Morning Lunatic parksie's Avatar
    Join Date
    Mar 2000
    Location
    Mashin' on the motorway
    Posts
    8,169
    yikes.
    Code:
    #include <stdio.h>
    
    int integer_add(int x, int y) {
        return (x + y);
    }
    
    int main() {
        int res = integer_add(1, 17);
        printf("%d", res);
        return 0;
    }
    Is that what you meant?


    [Edited by parksie on 07-29-2000 at 06:35 AM]
    I refuse to tie my hands behind my back and hear somebody say "Bend Over, Boy, Because You Have It Coming To You".
    -- Linus Torvalds

  5. #5
    Frenzied Member
    Join Date
    Jul 1999
    Posts
    1,800
    Wow, I was pretty off! I think I better start reading that book more carefully. Sorry. Thanks parksie.

  6. #6
    Guest
    I had something like that,

    but what is the d% for(I havent looked at my C book for a long time)?

  7. #7
    Guest
    I believe it means to format and display "res".

  8. #8
    Frenzied Member HarryW's Avatar
    Join Date
    Jan 2000
    Location
    Heiho no michi
    Posts
    1,827
    '%' is an escape character for variables in the printf function, just like '\' is an escape character for characters in strings in C (like "\n" is a newline).

    If it was a character it would be %c I think, can't remember exactly. I'm too used to the C++ versions cout and cin.

    parksie, did you forget the opening curly bracket for the integer_add() function or can it be omitted?
    Harry.

    "From one thing, know ten thousand things."

  9. #9
    Monday Morning Lunatic parksie's Avatar
    Join Date
    Mar 2000
    Location
    Mashin' on the motorway
    Posts
    8,169
    Aarrrgh!!!

    Sorry. It does need a bracket, I just can't type. (edits post).

    Thanks HarryW.
    I refuse to tie my hands behind my back and hear somebody say "Bend Over, Boy, Because You Have It Coming To You".
    -- Linus Torvalds

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width