Syvum Home Page

Home > Discussions > For all activities

Discussion topic: Contributed Answer/Explanation to Q. 12

Viewing replies        View entire discussion

To go to the homepage of this topic, click here.
Home: sanjanapaiOriginal MessageReply  
Subject: Contributed Answer/Explanation to Q. 2
   // and /* */
   <p>
   // for single line comments & /* */ for multiple lines comments.
   </p>
   <p>
   eg1-
   </p>
   <p>
   class Example
   </p>
   <p>
   {
   </p>
   <p>
           public void main(int n) //enter a desired number
   </p>
   <p>
           {
   </p>
   <p>
                   System.out.println(n);
   </p>
   <p>
           }
   </p>
   <p>
   }
   </p>
   <p>
   eg2-
   </p>
   <p>
   class Example
   </p>
   <p>
   {
   </p>
   <p>
           public void main(int n)
   </p>
   <p>
           {
   </p>
   <p>
                   /* The number input above 
   </p>
   <p>
                            is printed by the statement
   
   </p>
   <p>
                            given below */
   </p>
   <p>
                  System.out.println(n);
   </p>
   <p>
           }
   </p>
   <p>
   }
   </p>

Posted at: Sun Jan 24 06:34:50 2010 (GMT)

Page 1 of 1
From: sanjanapaiReply 1 of 1Reply
Subject: Contributed Answer/Explanation to Q. 2
   // and /* */
   <p>
   // for single line comments & /* */ for multiple lines comments
   </p>

Posted at: Sun Jan 24 06:36:10 2010 (GMT)

Page 1 of 1

To post to this forum, you must be signed in as a Syvum member. Please sign in / register as a member.

Contact Info © 1999-2024 Syvum Technologies Inc. Privacy Policy Disclaimer and Copyright