Is there a quick shortcut (like CTRL+something) to comment out/ decomment a large block of code in Dev C++ when it is selected?
I find it tedious to go line by line and add the // in front of each line.
Printable View
Is there a quick shortcut (like CTRL+something) to comment out/ decomment a large block of code in Dev C++ when it is selected?
I find it tedious to go line by line and add the // in front of each line.
Yeah - use the /*...*/ way of commenting. Everything between /* and */ is commented out. Note that this way of commenting is not recursive so /*../*..*/..*/ cannot be used - but it can include //comments
/*These are various lines of code
I want to comment out
It is tedious to keep using //
so I use the other way instead*/
Thanks!
Change to a newer environment. Dev C++ hasn't been maintained for a long time. In the free MSVC Express for instance you just mark the area and press Ctrl+K,C to comment and Ctrl+K,U to uncomment. I bet other modern environments has something similar.