View Poll Results: Whitespaces...

Voters
53. You may not vote on this poll
  • for(x=0;x<5;x++)

    13 24.53%
  • for (x = 0; x < 5; x++)

    35 66.04%
  • for ( x = 0 ; x < 5 ; x++ )

    5 9.43%

White spaces

This is a discussion on White spaces within the A Brief History of Cprogramming.com forums, part of the Community Boards category; What kind of whitespaces do you use?...

  1. #1
    the Corvetter
    Join Date
    Sep 2001
    Posts
    1,584

    White spaces

    What kind of whitespaces do you use?
    1978 Silver Anniversary Corvette

  2. #2
    the Corvetter
    Join Date
    Sep 2001
    Posts
    1,584
    I go with option 2. I hate too much spaceyness, but I like to read code.

    --Garfield
    1978 Silver Anniversary Corvette

  3. #3
    Former Member
    Join Date
    Oct 2001
    Posts
    955
    I'd rather write code fast, not waste time with spaces


    Oskilian

  4. #4
    the Corvetter
    Join Date
    Sep 2001
    Posts
    1,584
    But it is so much harder to read in future reference for debugging. That, and it takes about a millisecond to hit the space bar.

  5. #5
    .
    Join Date
    Aug 2001
    Posts
    598
    Um you forgot:
    Code:
    for                                  (x                  
    
    
    
    ;
    
    
    
    
                                            x                         
    
    
      
    
    
                                                     <     
    
    
    
    
    
    
    
    10   
    
    
    
    
    
    
    
    
    
                                                          ;
    
    
    
    
    
    
    
    
    
                                                    x 
    
    
    
    
    
              ++
    
    
    
    
    
    
    
    
    
    
    
    
    
    
      ;       
    
    
    
    
    
    
    
    
    
                                                           )
    To Err Is To Be Human. To Game Is Divine!"

  6. #6
    Registered User dirkduck's Avatar
    Join Date
    Aug 2001
    Posts
    428
    i go with #1

  7. #7
    Registered User EvenFlow's Avatar
    Join Date
    Oct 2001
    Posts
    422
    I prefer #2 - it's not too spaced out, but I can easily edit the code if I need too.
    Ramble on...

  8. #8
    the Corvetter
    Join Date
    Sep 2001
    Posts
    1,584
    Yeh, I go with Evenflow (hey that rhymes). I need to read the code when it's done.

  9. #9
    Linguistic Engineer... doubleanti's Avatar
    Join Date
    Aug 2001
    Location
    CA
    Posts
    2,459
    hmmm... speaking of which... i adopted the practice of putting a space between the opening parenthesis in a function calls parameter list, as well as the protype/declaration... and, as such, it annoys me when reading other's code... there should be a compiler's limit on the number of lines in a code block!
    hasafraggin shizigishin oppashigger...

  10. #10
    Registered User mfc2themax's Avatar
    Join Date
    Aug 2001
    Posts
    346
    i like gamegod's suggestion.....
    mfc2themax-Creator of all that is.

  11. #11
    Registered User *pointer's Avatar
    Join Date
    Oct 2001
    Posts
    74
    I must be one of the few who prefers #3. Not only is it easy to read and is consistent, it also looks nice and that's important

    However, I don't space my semicolons, that's just plain wierd. This is my preference.
    for ( i = 0; i < something; i++ ) {
    Last edited by *pointer; 10-14-2001 at 08:54 AM.
    pointer = NULL

  12. #12
    Former Member
    Join Date
    Oct 2001
    Posts
    955
    c'mon mr. Unregistered, don't make a moderator close this nice little thread, if you want to harass garfield, open a separate thread, and Garfield: don't answer it, you could make a moderator close this thread.

    by the way: why do you say that to Garfield, everyone has it's own way to code.


    Oskilian

  13. #13
    Registered User minime6696's Avatar
    Join Date
    Aug 2001
    Posts
    267

    lolz

    #1 is good for robots
    #2 is good for people semi-new to computers (not using them for your whole life)
    #3 is good for real computer gurus, I use #3, becouse coding is instant, I think and it is 'instantly' typed. I've been typing for almost my whole life, so 'time' really dont matter to me, I type with patternz, whitch lets me type a huge amount of charachters quikly, and I really dont care, cuz its great readabuility!

    for( int sloop = 0 ; sloop < blah ; sloop++ )



    SPH

  14. #14
    Linguistic Engineer... doubleanti's Avatar
    Join Date
    Aug 2001
    Location
    CA
    Posts
    2,459
    to each his own... but given your age i think you can only know so much... good luck then...
    hasafraggin shizigishin oppashigger...

  15. #15
    Just one more wrong move. -KEN-'s Avatar
    Join Date
    Aug 2001
    Posts
    3,230
    Uh oh! let's all change our votes to #3 because it's "for gurus"!

    I vote 2 - I can't stand too many spaces, and it's still readable without looking like crud.

Page 1 of 3 123 LastLast
Popular pages Recent additions subscribe to a feed

Similar Threads

  1. Reading white spaces? oh and scanf_s
    By RobotGymnast in forum C++ Programming
    Replies: 7
    Last Post: 11-01-2008, 05:32 AM
  2. white spaces ...
    By eagles in forum C++ Programming
    Replies: 6
    Last Post: 01-13-2006, 06:55 AM
  3. Replies: 1
    Last Post: 03-08-2005, 11:02 AM
  4. string input...with white spaces?
    By Pureghetto in forum C Programming
    Replies: 6
    Last Post: 03-10-2003, 12:52 PM
  5. Reading in text file into an array, white spaces...
    By error in forum C++ Programming
    Replies: 12
    Last Post: 01-14-2003, 08:39 AM

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