Documenti di Didattica
Documenti di Professioni
Documenti di Cultura
Generate the following pattern for n number of sets Sample Output for n=2
* *
* * *
* * * *
* *
* * *
* * * *
* *
* * *
* * * *
* *
* * *
* * * *
Q2. Generate the following pattern for n number:
For Value n = 4
* * * * * * * * * * *
* * * * * 1 * * * * *
* * * * 1 2 1 * * * *
* * * 1 2 3 2 1 * * *
* * 1 2 3 4 3 2 1 * *
* * * 1 2 3 2 1 * * *
* * * * 1 2 1 * * * *
* * * * * 1 * * * * *
* * * * * * * * * * *
For Value n = 2
* * * * * * * * * * *
* * * * * 1 * * * * *
* * * * 1 2 1 * * * *
* * * * * 1 * * * * *
* * * * * * * * * * *
Q3. Generate the following pattern for even number of rows.
a b c d e d c b a
a b c d d c b a
a b c c b a
a b b a
a a
a b b a
a b c c b a
a b c d d c b a
a b c d e d c b a
coordinate and a y coordinate. For example, (4,5) represents a point 4 units to the
right
of the vertical axis, and 5 units up from the horizontal axis. The sum of two points
can
be defined as a new point whose x coordinate is the sum of the x coordinates of the
two
Develop a program that uses a class called point to model a point. Define three
points,
and have the user input values to two of them. Then set the third point equal to the
sum
of the other two, and display the value of the new point. Interaction with the program
Q5) Create a menu driven application to maintain the student information using Java
to demonstrate the concept of array of Objects. Your application must have the
following functionalities.
a. For each student your application must have the details such as name, registerNo,
department, specialization, cgpa, hostelName, mentorName, noOfArrears.
c. Display the student list with all details in a proper and neat format.