PrepAway - Latest Free Exam Questions & Answers

Which code should you use?

You need to write a console application that meets the following requirements:
If the application is compiled in Debug mode, the console output must display Entering debug mode.

If the application is compiled in Release mode, the console output must display Entering release
mode.
Which code should you use?

PrepAway - Latest Free Exam Questions & Answers

A.
Option A

B.
Option B

C.
Option C

D.
Option D

Explanation:
Programmatically detecting Release/Debug mode (.NET)
Boolean isDebugMode = false;
#if DEBUG
isDebugMode = true;
#endif

http://stackoverflow.com/questions/654450/programmatically-detecting-release-debug-mode-net

4 Comments on “Which code should you use?


Leave a Reply