Virajsinh

Java_08

Feb 7th, 2018
108
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. //Write A Java Program To Explain Annotation Concept
  2. //3. @Deprecated
  3.  
  4. class A
  5. {
  6.     void m()
  7.     {
  8.         System.out.println("hello m");
  9.     }
  10.    
  11.     @Deprecated
  12.     void n()
  13.     {
  14.         System.out.println("hello n");
  15.     }
  16. }
  17.  
  18. class Ex7 // Ex7 is FileName
  19. {
  20.     public static void main(String args[])
  21.     {
  22.         A a = new A();
  23.         a.n();
  24.     }
  25. }
RAW Paste Data