Difference between revisions of "Spring 2020: Programming in Java Lab"

From MKWiki
Jump to navigation Jump to search
Line 13: Line 13:
 
! Q. NO.  !! Program  !! Remarks
 
! Q. NO.  !! Program  !! Remarks
 
|-
 
|-
| 1 || WAP to print first n even numbers || Practice Set  
+
| 1 || WAP to find the sum of any number of integers entered as command line argument || Practice Set  
 
|-
 
|-
| 2 || WAP to find sum of first n odd numbers || Practice Set
+
| 2 || WAP to find the factorial of a given number || Practice Set
 
|-
 
|-
| 3 || WAP to check whether the given number is prime or not || Practice Set
+
| 3 || WAP to check whether the given number is prime or not ||  
 
|-
 
|-
 
| 4 || WAP to print the following pattern using nested for loop:<br>
 
| 4 || WAP to print the following pattern using nested for loop:<br>
Line 25: Line 25:
 
  *  *  *  *
 
  *  *  *  *
 
|| Practice Set
 
|| Practice Set
|-
+
 
| 5 || WAP to sort an array using built in PHP function || Q2. of the exercise
 
 
|}
 
|}

Revision as of 12:47, 8 January 2020

  • Instructions
    • Please be on time to avoid the attendance penalty.
    • Turn off(shutdown) your assigned machine after finishing your work (or before you leave the lab).
    • Please arrange the chair in proper place while leaving the lab.
    • Please put your phone in silent mode.


Lab 1: Getting Started ( week of 8th January 2020 )

  • Brief introduction to Java Basic Building Blocks Download
Q. NO. Program Remarks
1 WAP to find the sum of any number of integers entered as command line argument Practice Set
2 WAP to find the factorial of a given number Practice Set
3 WAP to check whether the given number is prime or not
4 WAP to print the following pattern using nested for loop:
*
* *
* * *
* * * *
Practice Set