Bad code examples

This is a discussion on Bad code examples within the A Brief History of Cprogramming.com forums, part of the Community Boards category; Just searching in the C Directory section of cprogramming for some good links and I found this one: C Programs ...

  1. #1
    Me want cookie! Monster's Avatar
    Join Date
    Dec 2001
    Posts
    680

    Bad code examples

    Just searching in the C Directory section of cprogramming for some good links and I found this one:
    C Programs for simple and advanced topics

    I think this link should me removed from the cprogramming site because of the bad progrogramming examples.
    Code:
    #include <stdio.h>
    #include <conio.h>
    #include <string.h>
    
    main()
    {
       char word1[25];
       char word2[25];
    
       clrscr();
    
       printf("\n First word : ");
       gets(word1);
       fflush(stdin);
       ... 
       /* und so weiter, and so forth */
       ...
       getch();
    }
    Maybe there is a MOD who can check all these links and remove the bad ones...

  2. #2
    It's full of stars adrianxw's Avatar
    Join Date
    Aug 2001
    Posts
    4,831
    The directory is open to allow people to post their sites and links. I don't think censoring it would be true to it's aim. There is some undoutably bad code in there, but search google and you will find bad code as well.

    To make it "acceptable" one would have to take the submisssions and inspect them before adding them, that would take a long time, AND, it would only check out what was at the link at the time the submission was made.

    Routinely going through all the links would be totally impractical.

    We could remove links we considered to be bad, but they could be put back there the next day.

    There is a link on the directory home page to "selected links".

    The directory is really under the "caveat emptor" classification.
    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. Replies: 1
    Last Post: 03-21-2006, 06:52 AM
  2. what are some good C++ source code examples?
    By orion- in forum C++ Programming
    Replies: 4
    Last Post: 09-13-2005, 09:24 PM
  3. Writing Code
    By ILoveVectors in forum C++ Programming
    Replies: 4
    Last Post: 06-13-2005, 12:27 AM
  4. Seems like correct code, but results are not right...
    By OmniMirror in forum C Programming
    Replies: 4
    Last Post: 02-13-2003, 12:33 PM
  5. bad code?
    By brad123 in forum C Programming
    Replies: 11
    Last Post: 05-02-2002, 03:38 PM

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