c for dummies

This is a discussion on c for dummies within the C Programming forums, part of the General Programming Boards category; hey , I have just started learning the language C with the help of C for dummies . M trying ...

  1. #1
    Registered User
    Join Date
    Nov 2010
    Posts
    2

    c for dummies

    hey ,

    I have just started learning the language C with the help of C for dummies . M trying to make gcc work in windows , the following are the steps I have followed in command prompt & the problems m facing :-

    in c:\windows i type "copy con gcc.bat" (wtq)

    then i type :- @c:\Dev-Cpp\bin\gcc %1 %2 %3 %4 %5 %6

    the error message it gives is access is denied , <0> files copied .

    my os is windows 7 starter

    pls help !

    thnx

  2. #2
    Registered User claudiu's Avatar
    Join Date
    Feb 2010
    Location
    London, United Kingdom
    Posts
    2,094
    First of all avoid dev-cpp. It is outdated, non-maintained rubbish.

    Use Codeblocks instead. You can download it for free.

    Secondly, if you are only starting you might want to give MinGw a try as a compiler. It is a minimal gcc for windows.
    1. Get rid of gets(). Never ever ever use it again. Replace it with fgets() and use that instead.
    2. Get rid of void main and replace it with int main(void) and return 0 at the end of the function.
    3. Get rid of conio.h and other antiquated DOS crap headers.
    4. Don't cast the return value of malloc, even if you always always always make sure that stdlib.h is included.

  3. #3
    C-no_Ob Bennie98's Avatar
    Join Date
    Oct 2010
    Location
    Ledeberg, Ghent, East-Flanders, Belgium
    Posts
    49
    or try Pelles C ... also free and uses the c99 compiler... very nice program and a good IDE

    edit: link & compilertype
    Last edited by Bennie98; 11-02-2010 at 07:21 AM.

  4. #4
    Banned
    Join Date
    Aug 2010
    Location
    Ontario Canada
    Posts
    9,547
    Quote Originally Posted by newprog82 View Post
    hey ,

    I have just started learning the language C with the help of C for dummies . M trying to make gcc work in windows , the following are the steps I have followed in command prompt & the problems m facing :-

    in c:\windows i type "copy con gcc.bat" (wtq)

    then i type :- @c:\Dev-Cpp\bin\gcc %1 %2 %3 %4 %5 %6

    the error message it gives is access is denied , <0> files copied .

    my os is windows 7 starter

    pls help !

    thnx
    Right off the top... uninstall and trash DEV-CPP ... it's had it's day and there is much better to be had for free.

    Claudu has already mentioned the CodeBlocks ide which comes with gcc.

    If you are not totally stuck on the GCC compiler and are looking for an all in one console and gui development station you might find PellesC is much easier for beginners to use... It comes complete with windows headers and libs, supports macro assembly, can produce console, gui and CE (portable) code and is fully documented.

    smorgasbordet - Pelles C

Popular pages Recent additions subscribe to a feed

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21