I use 5 space tabs. Dunno why. I guess I'm just lazy.
Use Tabs
Use Spaces
No, it's not. The number of characters used depends on what font size you're using. At least that's the case in Word 2002.Originally posted by Thantos
IIRC tabs are actually 5 characters, its been that way since the days of typewriters. Set your word processor to a fixed width font and try it out. Its 5 characters.
Last edited by Sang-drax : Tomorrow at 02:21 AM. Reason: Time travelling
And as for tab sizes, the standard is 8 spaces, nothing else.
In some programming languages this is part of the language definition (Python and Haskell for example).
I use a tabstop of four spaces though.
Last edited by Sang-drax : Tomorrow at 02:21 AM. Reason: Time travelling
Spaces all the way! Two spaces all the way!
- SirCrono6Code:#include <iostream> int main( void ) { std :: cout << "Hello World!" << std :: endl; return 0; }
From C to shining C++!
Great graphics, sounds, algorithms, AI, pathfinding, visual effects, cutscenes, etc., etc. do NOT make a good game.
- Bubba
IDE and Compiler - Code::Blocks with MinGW
Operating System - Windows XP Professional x64 Edition
Am I the only one who uses three space tabs then? I think 3 is perfect for readability.
Free the weed!! Class B to class C is not good enough!!
And the FAQ is here :- http://faq.cprogramming.com/cgi-bin/smartfaq.cgi
Leeme quote myself.Originally posted by Speedy5
Three spaces with the tab-to-space feature (which also allows shift-tab).
3 is perfect as it is in many other cases
i have tab set to four spaces becuase of cout... example:Code:cout<<"blah blah blah blah"<<endl <<"second line blah blah blah"<<endl;
Join is in our Unofficial Cprog IRC channel
Server: irc.phoenixradio.org
Channel: #Tech
Team Cprog Folding@Home: Team #43476
Download it Here
Detailed Stats Here
More Detailed Stats
52 Members so far, are YOU a member?
Current team score: 1223226 (ranked 374 of 45152)
The CBoard team is doing better than 99.16% of the other teams
Top 5 Members: Xterria(518175), pianorain(118517), Bennet(64957), JaWiB(55610), alphaoide(44374)
Last Updated on: Wed, 30 Aug, 2006 @ 2:30 PM EDT
When I first saw the post I was excited, thinking it was a music discussion. I do have to say I am disappointed!
There is no reason to use int main(void) in c++Originally posted by SirCrono6
Spaces all the way! Two spaces all the way!
- SirCrono6Code:#include <iostream> int main( void ) { std :: cout << "Hello World!" << std :: endl; return 0; }
int main() is exactly the same.
Then why waste the time to question it?Originally posted by Brian2
There is no reason to use int main(void) in c++
int main() is exactly the same.
Do not make direct eye contact with me.
Yeah, I know. I don't normally use it anyway .
All the way!Code:int main(int argc, char *argv[])
- SirCrono6
From C to shining C++!
Great graphics, sounds, algorithms, AI, pathfinding, visual effects, cutscenes, etc., etc. do NOT make a good game.
- Bubba
IDE and Compiler - Code::Blocks with MinGW
Operating System - Windows XP Professional x64 Edition
Brian2 would you please stop posting crap. Thank youThere is no reason to use int main(void) in c++
int main() is exactly the same.
http://faq.cprogramming.com/cgi-bin/...&id=1043284376
...I have Visual C# .net set to 4 spaces and I use Virtual Spaces because if I'm going to be posting a code in the forum, Visual C# .net converts from tabs to spaces. I also use tabs to line up the code. For example:
Code:using System; using System.Drawing; using System.Windows.Forms; namespace Example { /// <summary> /// Main class for the form /// </summary> public class Form1 : System.Windows.Forms.Form { /// <summary> /// Constructor for a Windows Form class /// </summary> public Form1() { InitializeComponents() } /// <summary> /// Used for initializing a form and all the controls needed /// for the application. /// </summary> public void InitializeComponents() { // // form1 // this.Text = "Form 1 Example"; this.BackColor = System.Drawing.Color.Black; // ... } /// <summary> /// Entry point for starting an application. /// </summary> public static void Main(string[] args) { Application.Run(form1); } } }
Last edited by Grayson_Peddie; 01-10-2004 at 01:34 PM.
View in Braille.
http://www.future-gpnet.com/braille.jpg
Like a bolt out of the BLUE,
Fate steps up and sees you THROUGH,
When you wish upon a STAR
YOUR DREAMS COME TRUE.
many editors treat tabs and spaces the same way. E.g. if you have 4 spaces and press backspace they all get deleted. If you have 1 one tab and set it to be the size of 4 spaces then it will do the samething. The only difrence is that with spaces you can click everywhere and the caret will be positioned there but with tabs it will be positioned to the begining or end of the tab. Some people (like me) are just to lazy to change the setting becuase of this.
Yeah after looking at it some more I realize its actually going to the same spot of the paper.The number of characters used depends on what font size you're using
But if you do put in to Courier New 12pt which is the closest to the typeface that most typewriters used it is 5 spaces which is actually what my point was about
I think most of us use spaces regardless (or should it be irregardless?) if we get them by hitting the spacebar or having tabs set to insert spaces instead of the tab character.