If you use an IDE use macros to speed up your writing. For example you can create a macro and press "Alt+c" and this line appears
Code:
cout <<     <<endl;
In MS-VS I do it by going to Tools in menu bar and clicling on macro...
Press record
Enter a name
Type what you want to be recorded
Press stop
You see the VB macro, close it.
Go to tools>macro...
Press options
In "Assign macro to" frame press keystrokes
In "Press new shortcut key" press the keys you want to be assigned.
Press assign button.