Results 1 to 6 of 6

Thread: C Compiler

  1. #1
    Join Date
    Dec 2007
    Posts
    123
    Thanks
    17
    Thanked 1 Time in 1 Post

    Question C Compiler

    Hi,

    Just wondering if Borland C++ Compiler version 5.5 works for C language also?

    If not, can u plz refer me with a similar free C compiler?


    Thanx

  2. #2
    Join Date
    Jul 2008
    Posts
    199
    Thanks
    6
    Thanked 58 Times in 57 Posts

    Default

    This free IDE is for C and C++

    http://www.bloodshed.net/devcpp.html

    And yes, that compiler you're asking about does do regular C

  3. #3
    Join Date
    Dec 2007
    Posts
    123
    Thanks
    17
    Thanked 1 Time in 1 Post

    Default

    ok I downloaded Bloodsheed Dev C++

    I am trying to run this code

    Code:
    #include <stdio.h>
    
    int main()
    {
        printf("\n");
        printf("Hello World");
        printf("\n");
    }

    It compiles ok, and a DOS screen comes for a few milliseconds and disappears.

    Why is this hapenning? And How/Where do I see the output?

    Sorry, I am new to C.


    Thanx

  4. #4
    Join Date
    Jun 2007
    Posts
    543
    Thanks
    3
    Thanked 78 Times in 78 Posts
    Blog Entries
    1

    Default

    because the window will close as soon as the code is done. i don't know about c but in c++ you use cin.get(); which pauses the script and waits for the user to press any key
    [Jasme Library (Javascript Motion Effects)] My Site
    /\/\@§†ê® §©®¡þ† /\/\@|{ê®
    There are 10 kinds of people in the world, those that understand binary and those that don't.

  5. #5
    Join Date
    Jan 2008
    Posts
    4,168
    Thanks
    28
    Thanked 628 Times in 624 Posts
    Blog Entries
    1

    Default

    Also, in c++ you can also use: system("PAUSE");
    Jeremy | jfein.net

  6. #6
    Join Date
    Jun 2007
    Posts
    543
    Thanks
    3
    Thanked 78 Times in 78 Posts
    Blog Entries
    1

    Default

    yes but that is os dependent and not to standards
    [Jasme Library (Javascript Motion Effects)] My Site
    /\/\@§†ê® §©®¡þ† /\/\@|{ê®
    There are 10 kinds of people in the world, those that understand binary and those that don't.

Bookmarks

Posting Permissions

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