View Single Post
Old 10-10-2008, 07:37 PM   #2
Data
retired
 
Data's Avatar


 
Join Date: Jun 2004
Location: Jan Mayen, Svalbard and Jan Mayen
Posts: 2,167
Default

Thank you for kind remarks.

I use using namespace std; quite often, but as I published the code I made a bit more robust for copy and paste work by including the correct namespace.

I tend to forget the possibility to omit the arguments of main.
Returning a value is good practice, especially if the utility can be used in shell scripts.

My Cism were (as far as I'm concerned)

Code:
templine = "";
instead of
Code:
templine.clear()
and
Code:
templine != ""
instead of
Code:
!templine.empty()
But the Cism are actually smaller and for me at least as intuitive as the C++ things. (long live the operator overloading )
__________________
Flowing with the stream of life
Data is offline                         Send a private message to Data
Reply With Quote