precompile marco : Preprocessor Directives : Language Basics C# Source Code


Custom Search

C# Source Code » Language Basics » Preprocessor Directives »

 

precompile marco








    
 

#define MYOWN
#define DEBUG
#undef VERBOSE

using System;
class Operators {
    static void Main() {
#if MYOWN
        Console.WriteLine("Hi!");
#elif VERBOSE
   Console.WriteLine("Program Starting?);
#endif
        int a = 10, b = 5;
#if DEBUG
        Console.WriteLine("a={0}, b={1}", a, b);
#endif
#if MYOWN && (VERBOSE || DEBUG)
        Console.WriteLine("Continuing, Author");
#elif !MYOWN && (VERBOSE || DEBUG)
   Console.WriteLine("Continuing?);
#endif
    }
}

 
    
   
  
   







HTML code for linking to this page:

Follow Navioo On Twitter

C# Source Code

 Navioo Language Basics
» Preprocessor Directives