0% found this document useful (0 votes)
737 views49 pages

Combinepdf Combined

For a modular software design, the combination of high cohesion and low coupling should be used. A logically cohesive module will have activities implemented from inside the module itself. The while loop is a controlled structure used when the exact number of times a code needs to be executed is unknown.

Uploaded by

Yashika
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
737 views49 pages

Combinepdf Combined

For a modular software design, the combination of high cohesion and low coupling should be used. A logically cohesive module will have activities implemented from inside the module itself. The while loop is a controlled structure used when the exact number of times a code needs to be executed is unknown.

Uploaded by

Yashika
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 49

PRIMMER DUMP

1. If you are asked to do a modular software design, which combination of coupling and cohesions
should you use for designing the software?

a. High cohesion and high coupling

b. High cohesion and low coupling

c. Low cohesion and high coupling

d. Low cohesion and low coupling

2. Statement: For a logically cohesive module, there are some activities to be implemented. These
activities are preferred from inside the module itself. Is the above given statement true? If not,
choose the correct option to make it true.

a. The activities are selected from outside the module.

b. The activities are selected in a random manner.

c. The activities are selected in a sorted manner.

d. The given statement is true.

3. What kind of controlled structure is used when we don’t know the exact number of times a
code needs to be executed?

a. switch

b. while

c. for

d. if-else

4. Which of the given statements is true about XP?

a. XP narrows down towards a single project developed and numbered by a single team.

b. XP will not work in environment where the manager insists on complete documentation before
the team begins to code

c. XP will work in the environment where programmers are separated geographically.

d. XP is best suited to work with systems that have scalability issues


5. testing is done by client in the real world environment.

a. Alpha

b. beta

c. system

d. gamma

6. Which two phases of feature driven development are repeated until no more feature exist?

a. Develop an overall model


b. Plan by feature
c. Design by feature
d. Build a feature list
e. Build by feature
a. b and c
b. c and e
c. b and e
d. d and b

7. Predict the output

What will be the output for the given code snippet

startprogram

public class Main {

public static void main(String[] args) {

try {

System.out.println(4/0);

try{

Int[] a={1,2,3};

System.out.println(a[3]);

} catch(ArrayIndexOutOfBoundsException e) {

System.out.println(“Out of bounds”);

}catch(ArthmeticException e){

System.out.println(“ArithmaticException : divide by 0”);

endprogram
a. out of bounds ArithmaticException : divide by 0

b. runtime error

c. out of bounds

d. ArithmaticException: divide by 0

8. Which of the following declarations will cause a compile time error?

a. int[] scores = null;

b. int[] scores =new int[5];

c. String[] nameArray = new String[10];

d. String[] nameArray = (5,3,2);

9. Arrow symbols in the flowchart is used to show the sequence of steps and the relationship
among them. State true and false

a. True

b. False

10. Information hiding is achieved through which OOP principle?

a. Inheritance

b. Encapsulation

c. Typing

d. Hierarchy

11. In multibranch, the pipeline names should not contain .

a. spaces

b. special characters

c. numerics

d. variables

12. Which are the phases of CI/CD pipeline?

a. Source

b. Operate

c. Monitor

d. Deploy
13. is a conceptual framework where software is developed is iterations

a. Agile

b. prototyping

c. extreme programming

d. DSDM

14. Predict the output of the following statement. Select substr(“Yellow is A colour”,1,5) from
dual;

a. Yellow

b. Yel

c. Yello
d. elow

15. column header is referred as

a. domain

b. attribute

c. table

d. tuples

16. At which level of testing the non-functional requirements are tested?

a. Unit testing

b. system testing

c. Integration testing

d. Acceptance testing

17. Agile methodology does not accepts change of requirements at any stage

a. True

b. False

18. In a relational database a referential integrity constraint can be done using

a. primary key

b. foreign key

c. secondary key

d. compose key
19. Which of the given options are true with respect to arrays?

a. Array size is fixed

b. The element of an array can be accessed using index.

c. Array element can be sorted by decreasing order

d. Negative values cannot be placed in an array.

20. Name the type of join used to include rows that do not have matching values

a. Cartesian product

b. inner join

c. non equi-join

d. outer join

21. Expand DSDM

a. Dynamic System Development Method

b. Dynamic State Development Method

c. Dynamic System Design Method

d. Data System Development Method

22. A primary key can have null values. State True and False.

a. True

b. False

23. Meta data is declared as in SQL?

a. Data Dictionary

b. Meta Dictionary

c. Meta Information

d. Data Information

24. Which of the following is true about Continuous Integration?

a. It is performed immediately after the developers check-in.

b. Development team sends continuous code merging requests even when the testing process is
running

c. It emphasis on the change in all stages of your production pipeline

d. It is an approach of testing each code to codebase automatically.


25. The practice of automatically provisioning a new environment at the time of deployment is
referred to as

a. Continuous Integration

b. Continuous Development

c. Infrastructure-as-Code

d. Configuration Management

26. Scrum divides the development into short cycles called .

a. Spirals

b. Tracks

c. Lanes

d. Sprints

26. Which of the following is a correct declaration in java?

a. char[] Tic = new char();

b. char[] Tic = new char[19];

c. char[] Tic = new char(14);

d. char[] Tic = new char[];

27. Raghav has developed an application to automate the billing process of the Aarvee
Departmental Store. When the product is in operation, the client found that the place of the phone
number, it prints the Customer ID. So he approaches Raghav to fix the issue. What type of
Maintenance does the above scenario depict?

a. Corrective

b. Adaptive

c. Predictive

d. Preventive

28. Consider the scenario: You have written a code to display a menu on the screen and some
operation are preformed based on the given user input. Which control structure would you use, so
that the menu is guaranteed to show/display at least once on the screen, before performing the
operation.

a. for loop

b. While loop

c. Do-While loop

d. Case
29. Predict the output for the given pseudo code snippet. SET count = 1

While count less than or equal to 5

Print “Hello, world”

Count = count + 1

END WHILE

a. Prints” Hello, world” 5 times

b. Prints “Hello, world” 6 times

c. loop goes on infinitely

d. Prints “Hello, world” 4 times

30. Pinky and Raju are working on an insurance project. They are not aware of SVN. So they created
a common project on the server. Both retrieved the project from the server. They made relevant
changes to the life. First Raju saved the changes to the server. Next Pinky saved her project identify
which of the given statements are true.

a. Both their changes get updated on the server.


b. Pinky’s changes alone are stored and when Raju tries the upload, the server notifies the
differences.

c. Both Pinky and Raju’s changes get rolled back.

d. Pinky’s project over writes the changes done by Raju.

31. Statement: For a logically cohesive module, there are some activities to be implemented. These
activities are preferred from inside the module itself.

Is the above given Statement true? If not, choose the correct option to make it true.

a. The activities are selected from outside the module.

b. The activities are selected in a random manner.

c. The activities are selected in a sorted manner.

d. The given statement is true.

32. does the special group or group 0 is included while coupling groups using the groupCount in
java.

a. True

b. False
33. Many are delivered in an agile process.

a. Builds

b. Software

c. Programs

d. Tests

34. Predict the output

startprogram

class Product

String productName;

class Mobile extends Product

String mobileName;

void display()

super.productName = mobileName + “Brand New !”;

System.out.println(mobileName +” “ + productName);

}
class Main

public Static void main(String args[])

Mobile obj = new Mobile();

obj.productName=”1”;

obj.mobileName=”2”;

obj.display();

endprogram
a. 2 2Brand New !
b. 1 2Brand New !
c. 1 1Brand New !
d. Brand New !

35. Predict the output

import java.util.Scanner;

class WeightLimitExceeded extends Exception {

WeightLimitExceeded(int x) {

System.out.print(Math.abs(15-x) + "kg: ");

public class Main{

void validWeight(int weight) throws WeightLimitExceeded {

if(weight > 15)

throw new WeightLimitExceeded(weight);

else

System.out.println("You are ready to fly!");


}

public static void main(String[] args)

Main ob = new Main();

Scanner in=new Scanner(System.in);

for(int i=0;i<2;i++) {

try {

ob.validWeight(in.nextInt());

catch(WeightLimitExceeded e)

System.out.println(e);

}
}

What will be the output for the given code snippet

a. 5kg : WeightLimitExceeded

You are ready to fly!

b. NumberFormatException
c. 5kg :

You are ready to fly!

d. Cannot find symbol Math.abs

36. Predict the output

What will be the output for the given code snippet

Startprogram

Public class Main{

public static void main(String args[])

try {

System.out.println(4 / 0);

try {

int[] a = {1,2,3};

System.out.println(a[3]);

} catch(ArrayIndexOutOfBoundsException e){

System.out.println(“Out of bounds”);

} catch (AritjmeticException e) {

System.out.println(“AritjmeticException : divide by 0”);

endprogram

a. Out of bounds AritjmeticException : divide by 0

b. Runtime error

c. Out of bounds

d. AritjmeticException : divide by 0
37. Predict the output

What will be the output for the given code snippet

startprogram

Public class Main{

public static void main(String args[])

int a =10;

for(int i=3;1>=0;1++)

try{

System.out.println(a / i);

System.out.println(“End of try”);

catch(ArithmaticException e) {

System.out.println(e);

endprogram

a. 3
5
10
Java.lang.ArithmeticException: / by zero
b. 3
End of try
5
End of try
10
End of try
Java.lang.ArithmeticException: / by zero

c. Compiletimeerror

d.runtimeerror

38. Predict the output

What will be the output for the given code snippet

Startprogram

Import java.util.regex;

Public class Main{

public static void main(String args[])


{

String s=”ABC”;

Pattern p=Pattern.compile(s);

String r=”ABCABCABCABC”;

Matcher m=p.matcher(r);

System.out.println(m.lookingAt());

endprogram

a. true

b. false

c. ABC

d. 0

39. Predict the output

What will be the output for the given code snippet

startprogram

Import java.util.regex;

Public class Main{

public static void main(String args[])

Pattern p=Pattern.compile(“\\d”);

String test=”India123”;

Matcher m=p.matcher(test);

If(m!null)

System.out.println(m.find());

System.out.println(m.matches());

endprogram

a. true
true

b. false

true

c. true

false

d. false

false

40. Predict the output

What will be the output for the given code snippet

startprogram

Public class Main{

public static void main(String args[])

int arr[] = new int[] {0,1,2,3,4,5,6,7,8,9};

int n=6;

n = arr[arr[n] / 2];

System.out.println(arr[n] / 2);

endprogram

a. 2

b. 1

c. 6

d. 0

41. Predict the output

public class Main{

public static void main(String args[])

int[]m = new int[13];

System.out.println("m[0] is " +m[0]);

}
}

(a.) Program has a compiler error

(b.) Program has a compiler error

(c.) The program runs fine and displays m[0] is 0.

(d.) None

42. Predict the output

import java.util.regex.*;

public class Hello {

public static void main(String args[])

String s="REGULAREXPRESSION";

String r="";

s=s.replaceAll(r,",");

System.out.println(s);

(a.) ,R,E,G,U,L,A,R,E,X,P,R,E,S,S,I,O,N,

(b.) REGULAREXPRESSION

(c.) None

(d.) All

43. Predict the output

import java.util.Scanner;

public class Main {

static void func(int a,int b) throws ArithmeticException, ArrayIndexOutOfBoundsException

System.out.println(10/a);

int[] arr={1,2,3};

System.out.println(arr[b]);

public static void main(String[] args)

{
Scanner in=new Scanner(System.in);

for(int i=0;i<3;i++)

try{

func(in.nextInt(),in.nextInt());

catch(ArithmeticException e){

System.out.println("can't divide by zero");

catch(ArrayIndexOutOfBoundsException e)

System.out.println("Out of bounds");

a) 5

can't divide by zero

out of bounds

b) 5

can't divide by zero

out of bounds

c) Compile TimeError

d) Results in recursion

44. Which plugin are the appropriate functionality plugins used in multibranch pipelines for
validating the pull or change requests. (Select any two)

*) GitHub Branch Source

*) GitHub Main Source


*) Bitbucket Branch Source

*) Bitbucket Main Source

45. In code phase, requirements and feedback are gathered from customers and stakeholders.

a) True

b) False

46. Agile is useful when the client requirements are not clear or requirement frequently changes.

a) True

b) False

47. Many are delivered in an agile process

a) Builds

b) Softwares

c) Programs

d) Tests

48. Assume we have created a table employees with the columns: employee_id, employee_name,
salary, designation and manager_id. Here employee_id is set as primary key and manager_id is a
foreign key which refers to employee_id in the employees. Manju wants to display the employee
details along with the manager id and manager name. Select which query suits the above
requirement.

a) select employee_id, employee_name, salary, employee_id "Mgr-id", employee_name "Mgr-


name" FROM employees;

b) select e.employee_id, e.employee_name, e.salary, m.employee_id "Mgr-id", m.employee_name


"Mgr-name" FROM employees e, employees m Where e.manager_id = m.manager_id;
c) select e.employee_id, e.employee_name, e.salary, m.employee_id "Mgr-id", m.employee_name
"Mgr-name" FROM employees e, employees m Where e.manager_id = m.employee_id;

d) select e.employee_id, e.employee_name, e.salary, m.manager_id "Mgr-id", m.employee_name


"Mgr-name" FROM employees e, employees m Where e.manager_id = m.employee_id;

49. Predict the output

What will be the output for the given code snippet

startprogram

import java.util.Scanner;

public class Main{


public static void throwit(){

System.out.println("throwit");

throw new RunTimeException();

public static void main(String[] args){

try{

System.out.println("Hello");

throwit();

}catch(Exception re){

System.out.println("Caught");

}finally{

System.out.println("Finally");

System.out.println("After");

a) Hello

throwit

Caught

Finally

After

b) Finally

After

c) CompileTimeError

d) throwit

Caught

After

Finally
What does public Boolean lookingAt() method do?

Attempts to match the pattern partially or fully in the matcher

Which of these are not agile methodology?


BPM

Agile Technology does not accepts change of requirements at any stage.


False

In a relational database a referential integrity constraint can be done using


Foreign key

Which one is YAML’s basic building block?


Key Value

Predict the output of the below query. Select max(salary), min(salary), sum(salary), avg(salary) fromemployee.
Will display the max, min, sum and average salary earned by the employee

In multibranch, the pipeline names should not contain


Spaces

Which of the following takes more time?


Maintenance

1. Which of the following is said to be non-adaptive


ANS=selection sort
Merge sort

2. What is the output of the query:


startprogram
Select substr(“Stay home!Stay safe!!”,1) from dual;
End program
ANS= Stay home! Stay safe!
3. Which of the given options are used to calculate the running time complexity of
an algorithm
ANS= Asymtotic notation

4. is used to alter the program flow, when a set of


statements need to be excecuted only if a condition is fulfilled
ANS= Conditional statement

5. Analysis of selection algorithm eliminates number of elements each


time
Ans= n/2

6. White box testers should require the working knowledge of the code segment
ANS-True

7. A doubly linked list cannot be implemented using a single pointer variable in


every node
Ans= True

8. If you create a view WITH READ ONLY option, it can only be viewed and
not updated. State true/false.
Ans = true.

9. constraints ensures and of the data in the database


Ans = a)Correctness
b) Reliability

10. The WHERE clause cannot be used to apply additional conditions in SELECT
statement containing the ON or the USING clause. State true/false.
Ans = true(not sure).
11. Consider the following array {12,3,1,5,8} Tell us the number of steps that are
required to sort the elements in the ascending order using insertion sort.
Ans = 5

12. Choose legal identifiers from the below options:


a)4thvariable
b)_98_
c) &count
d)$says
e)new

13. In which of the given data structures, does the implementation becomes
difficult?
Ans= graph

14. William is planning to develop software- Customer Feedback System, which


helps the department store to predict the sales target. His requirements are
clear but his requirements are not stable. Suggest a software development
suitable for this scenario.
Ans = Prototype model

15. White box testers should require the working knowledge of the code being
tested
Ans= true

16. import java.util.ArrayList;


import java.util.List;
class TestMain{
public static void main(String[] args){
//INSERT LIST DECLARATION HERE
for(int i=0;i<=5;i++){
List<Integer> row=new ArrayList<Integer>();
for(int j=0;j<=5;j++)
row.add(i*j);
db.add(row);
}
for(List<Integer>row:db)
System.out.println(row); }
}
Ans = List<List<Integer>>db= new ArrayList<List<List<Integer>>();

17. public class Main


{
public void printVal(Integer i)
{
System.out.println("Integer "+i);
} public void printVal(int i)
{
System.out.println("Int "+i);
}
public static void main(String[] args) { new Main().printVal(127); }
}
Ans = int 127

18. public class TestMain extends Tree


{
public static void main(String s[])
{
new TestMain().go();
}
void go(){
grow2(new Tree().new TestMain());
grow2(Main)new tree().nw TestMain());
}
void grow (Tree t1,main r1){
Testmain r2=(Testmain)t1;
Tree t2=(Tree)r1;
}
}
class Tree{}
ans = compile time error

19. public class Main{


public static void main (String[] args){
String a[]=new String[-9/-4];
int b=a.length;
System.out.print(new
String[]{"Harley","Aprilla","Kawasaki","Triumph","Guzz"}[0]);
}}
Ans = Kawasaki

20. predict output


class TestMain{
int x=50;
public static void main (String[] args) {
final TestMain f1= new TestMain();
TestMain f2 = new TestMain();
TestMain f3 = isvalid(f1,f2);
System.out.println(f1==f3)+""+(f1.x==f3.x));
}
static TestMain isvalid(TestMain x,TestMain y){
final TestMain z=x;
z.x=60;
return z;
}
ans= true true

21. class mammel{


String name= "Dog";
String makenoise(){
return "Bow Wow";
}
}
class Cat extends mammel{
String name="Cat";
String makeNoise()
{
return "Meow";
}
}
public class Main{
public static void main (String[] args) {
new Main.go();
}
void go()
{
mammel m=new Cat();
System.out.println(m.name+m.makeNoise());
}
}
Ans = dog meow

22. Bonus calculated module was unit tested by the developer. Depending on the
salary the bonus
needs to be calculated. Assume if one of the salary-range is between 30000 to
40000 then the
bonus should be 10%. From the given options identify the test cases for
Equivalence Partitioning.
Ans-
25000,35000,45000
25000,27000,29000
42000,43000,45000
32000,35000,39000

23. What is the command to concatenate fname and lname with a space in between
and display
the output under the heading of “Full Name”?
Employee(eid,fname,lname,salary)
Ans= select fname||’ ’||lname as ‘Full Name’ from employee;
select fname||’ ‘||lname ‘Full Name’ from employee;

24. Consider the following table structure and write a query to display all the
employees who
have and don’t have department id assigned
Emp(fname,lname,dno)
Dept(dep9d,dname)
Ans= 1) SELECT FNAME,DEPTID,DNAME FROM EMP E LEFT OUTER JOIN DEPT D
ON (E.DNO=D.DEPTID);
2) SELECT FNAME,DEPTID,DNAME FROM EMP E FULL OUTER JON DEPT D
ON(E.DNO=D.DEPTID

25. Select statements true about persistence


Answer = i) persistence is way through which life time of object exists even after
the terminates
ii) Java uses serialsation for object persistence
iii) Persistence is a way through which the life time of object is
terminated as the program terminates
iv) Persistence of object is done by java runtime automatically.

50. public class TestMain


{
{
index=1;
}
int index;
public static void main(String[] args)
{
new TestMain().find();
}
void find(){
int[][]d = {{7,8,9},{4,5,6},{0,1,2,3}};
System.out.println(d[index++][index++]);
}
}
Ans = 6
41. class Rays {
static String s="";
protected Rays(){
s+="Rays";
}
}
class Alpha extends Rays {
private Alpha(){
s+=" Alpha";
}}
public class Main extends Rays
{
private Main() {
s += "SubAlpha";
}
public static void main(String s[])
{ new Main();
System.out.println(s);
}}
Ans = rayssubalpha

42. In order to refer to all the elements in a one dimensional array which is the
possible option that you would choose.
Ans = Using an indexed loop, such that the respective from 0 to the array
size minus one.
43 is the time duration for each sprint
a>2-3 days
b>2-5 hours
c>2-4 weeks
d>1 month

43. Match the correct options with the characteristics of a good program

1) Cost effectiveness - A)Ability to handle most of the changes without


having to rewrite the entire program

2)Eficiency - B)Deals with the amount of time and memory


space required for a program

3)Portability -C)Ability to run on different platforms with or


without minimal changes

4) Flexibility – D)Deals with program quality without much


expenses
Ans = 1-D,2-B,3-C,4-A

48. public class Main


{
{
System.out.print("Hello");
}
public display()
{
System.out.print("display");
}
public static void main(String s[])
{
System.out.print("hai");
display dobj1=new display();
display dobj1=new display();
}
}
Ans = haiHellodisplayHellodisplay

49. is used to alter the program flow, when a set of statements need
to be executed only if a condition is fulfilled.

Ans= conditional statements

50. in which of the given data structures, is pointers concept applied?


Linked list
Binary tree

51. What is the output of the query: startprogram


Select substr(“Stay home! Stay safe!!”,1)from dual;
End program
Ans: Stay home! Stay safe!

52. appending content to existing file in vi editor can be done in mode.

Command mode
Insert mode
Append mode
Escape mode

57. choose the data control Language commands?


Commit
Grant
58. In HTML, base tag should be used inside the head section only?
True

59. which uml diagram is capable to depict conditional branching and loop
execution?
Ans = sequence diagram

70. choose the methods(s) of the stringbuilder class


Intern()
Delete()
Append()
Reverse()
Replace()

71. Consider the following structure


Customer (custid,custnmae,address,city,country)
Choose the option display all customer who all are not from Hyderabad and
delhi.

a. Select * from customer where city in(“Hyderabad”,”Delhi”);


b. Select * from customer where city < > in(“Hyderabad”,”Delhi”);
c. Select * from customer where city not in(“Hyderabad”,”Delhi”);
d. Select * from customer where city <>“Hyderabad” and city <>”Delhi”;

78. which of the given options are true with respect to linked lists, when
compared to arrays
1.Linked lists are dynamic in size
2.Random access is possible in linked list
3.Insertion and deletions are expensive in linked list
4.All the options

79. “How to do” aspects is converted in a SRS document.State true/False.


Ans:0(False)
80. consider a scenario: you have written a code to display a menu on the screen
and some operations are performed based on the given user input.
Which control structure would you use ,so that the menu is guaranteed to
show?display at least once on the screen, before performing the operation
Ans= do-while loop

81. US Insurance project development team members are divided into two
groups, one team
works in the development office in India and the other group works onsite, ie,
at the client location
So Programmers located in different locations is not suitable for methodologies
Ans=DSDM

82. Which of the following is not a part of SRS document


Ans –
Functional Requirement
Non-Functional Requirements
Implementation Details
Hardware Software specifications

83. ) When constructing loop statements,if the iteration condition is not


terminated ,it will
result in Infinite loop(true?false)
ans= true

84) Sam and rose are working on the loan monitoring project the head version
was checked
out By both sam and rose .both of them made their changes in the local
machines both of them
Made the required changes and updated the same to the server from the given
options Identify
correct option
Ans= Second projects gets over written by the first one

85) ERD Example


consider the given scenario. A product may or may not have a sale.
A sale can have one or more products.Iden9fy the op9onality between the
product and sales
correct option: 1…0

86. In a binary search algorithm, if the element to be searched is lesses than the
pivot value (middle value), then is split in half.

Right interval
Left interval
Half interval
Complier dependent

87. startprogram
public interface studentmark{
/*insert code here*/ int mark=100;
}
which modifiers when inserted in the above code will provide compilation
errors?(choose two)
endprogram

final
static
abstract
private
public

88. )Amaze Agencies, Customers can apply for loan. To apply loan the
customers
should get registered first then apply for the loan. The admin will approve the
loan
and then the loan will be issued to the customer.
Identify the classes in above scenario.
Ans: Customer, Loan, Register.
90. class High{
public High(String s){
System.out.print("From High");
}
}
public class Main extends High{
public Main(String s){
System.out.print("From Low");
}
public static void main(String[] args){
new Main("High Low");
System.out.prinln("");
}
}
Ans = compile time error

91. The following XML fragment is legal.


Startprogram<2020SalesReport>
<income>1000000</income>
<profit>500000</profit>
</2020SalesReport>
Endprogram
Ans: True

92. 1)INNER JOIN 2)LEFT OUTERJOIN 4)RIGHT OUTER JOIN 5)FULL OUTER JOIN
WITH
A)Returns records that have matching values in both tables B)Returns the matched records
from the
right table, and all records from the left table C)Returns the matched records from the left
table, and
all records from the right table D)Returns all records when there is a match in either left or
right
table
a>1-d,2-c,3-b,4-a
b>1-d,2-b,3-c,4-1
c>1-d,2-b,3-a,4-c
d>1-a,2-b,3-c,4-d
93. Consider the file staff dat which has the following content
1:Anu Professor 85000 y
2 Sam Associate Professor 150000 5yrs
3. John Professor 75000 6yrs
4. Suresh Associate Professor 150000 5yrs Which is the command to display the outbusas
tolos?
Suresh Associate Professor
Sam Associate Professor
John Professor
Anu Professor
Ans= cut -d: -f 2,3 staff dat|sort -r

94. The company needs to change the job title ‘officer’ to ‘Administrative officer’ for all
officers.which statement does this
Ans= update employee job=’Administrative officer’ where upper=’officer’;

95. identify the type of control statement from the given option, in which the program chooses
two or more alternative path based on the result of a particular expression that returns a
Boolean value.
Ans=sequential

96. public class demo


{
static int num1=85; Note=
Agar question mai num1 or num2 ki
int num2=58; values alag aegi to fatafat is copy kar k compiler m
{ check kar k output bata dena..jaha jaha demo hai
display(); waha Main likh dena agar online compiler usekarre
ho to
num1=58;
num2=85;
}
void display()
{
System.out.println("num1="+num1);
System.out.println("num2="+num2);
}
public static void main(String d[])
{
demo myobj=new demo();
myobj.display();
}}
Ans =
num1=85
num2=58
num1=58
num2=85

97. predict the output display the loan type and the number of customers under
each loan type,considering only those loan types which are taken by more than
one customer.
Select loan_type,count(customer-id) from loans_taken l1 inner join loans l2 on l1
loan_id=l2 loan_id group by loan_type having count(customer_id)>1 order by
loan_type

98. Consider the following css code snippet

Startprogram
H1{
Text-shadow : 2px 3px 5px;
}
Endprogram

Choose the appropriate appearance for the text……….


Ans= horizontal shadow 2px,vertical shadow 3px,blur 5px

99. which of the below are functional interfaces?

Clonable
Serialization
Autocloseable
Comparable
Comparator

100.
Statement 1 : an include relationship between usecase means the included usecase
will be called every time the base usecase is executed

Statement 2 : an extends relationship between usecase means the extended usecase


is executed only when a given condition is true

Identify the correct statement

Ans= both 1 and 2 are true

101 what is the order of execution when there is a parent class and a child class
with constructors in it?
Ans =
1. initialization block of super class
2. initialization block of the class
3. constructor of super class
4. constructor of the class

102. Spot the error. Observe the given algorithm to calculate the simple interest.
Identify the

incorrect step (if any)


Step 1: Start
Step2: Get priniciple_amount,no_of years,rate_of_interst
Step3: Multiply priniciple_amount,no_of years,rate_of_interst and store it in
result
Step4: Simple_Interest=result%100
Step5: Display Simple Interest
Step6: Stop

Ans = Step 4

103. class Television


{
public void getPictureResolution(){
System.out.println("Video Quality is low");
}}
public class smartTv extends Television{

public void getPictureResolution(){


System.out.println("Video Quality is high");
}

public static void main(String[] args) {


try{
((smartTv)new Television()).gePictureResoution();
}
catch(ClassCastException e)
{System.out.print("Class cast exception was caught");
}
finally{
System.out.println("Finally");
}
}
}

Ans=
video quality is high
finally

104.
You need to analyze the time duration from the time that your orders are placed
to the time that your orders are shipped.
To do this, you must create a report that displays the customer number, date
ordered, date shipped, and the number of
months in whole numbers from the time the order is placed to the time the order
is shipped Which statement produces the required results

options =
O SELECT customer_id, order_date, shipping_date, ROUND(DAYS BETWEEN
(shipping_dale, order_date)) 30) Time Taken FROM order,

O SELECT customer_id, order_date, shipping_date,ROUNDOFF(shipping_date


order_date) Time Taken FROM order

O SELECT customer_id, order_date, shipping_date,MONTHS BETWEEN


(shipping_da order_date) Time TakenFROM order,

O SELECT customer_id, order_date, shipping_date ROUND(MONTHS BETWEEN


(shipping_date, ter_date)) Time Taken FROM order,

105. in CSS, which of the following code/ codes can be used for colouringa
table background in red?
Code 1: table {background-color: red; }
Code 2: table {bgcolor: red;}
Code 3: table {background: red;}

Choose one
Ans= code 1 only

106. class TestMain{


public static void main (String[] args) {
Map<Tasks, String> m= new HashMap<Tasks, String>();
Tasks t1 = new Tasks("Jan");
Tasks t2 = new Tasks("Jan");
Tasks t3 = new Tasks("Apr");
m.put(t1,"Design");
m.put(t2,"Code");
m.put(t3,"Develop");
System.out.println(m.size());
}
}
class Tasks{
String day;
Tasks(String d){
day=d;
}
public boolean equals(Object o){
return((Tasks)o).day==this.day;
}
}
public int hashcode()
{
return 0;
}
Correct option: 3

107. Agile methodology accepts change of requirement at any stage. State true or
false
Ans = 1

108. A linear structure which follows a specific order in which the operations are
performed.Stack follows which of the given orders?
Ans = last-in-first-out

109. when an exception occours in a method.The method creates an object for that
exception. To handel the exception, it is given to the run time system.the run time
system searches for all the methods in the call stack,it is cannot find the
approproate handler then it hands over the object to?
Ans= nosuchmethodexception

110. class BlackBoard{


Short story=200;
BlackBoard write(BlackBoard bb)
{
bb=null;
return bb;
}
public static void main(String[] args)
{
BlackBoard b1=new BlackBoard();
BlackBoard b2=new BlackBoard();
BlackBoard b3=b1.write(b2);
b1=null;
}
}

Ans= 1

111. Which of the following is a checked exception


Correct answer: IOException
FileNotFoundException

112. import java.util.*;


public class Main
{
public static void main(String[] args)
{
String[] str={"Banana","Apple","Watermelon","Mango"};
sortFruit o=new sortFruit();
Arrays.sort(str,o);
for(String s: str)
System.out.print(s+" ");
System.out.println(Arrays.binarySearch(str,"map"));
}
static class sortFruit implements Comparator<String>
{
public int compare(String str1,String str2)
{
return str2.compareTo(str1);
}
}
}

Ans = Watermelon Mango Banana Apple -5

113. What is the relationship between these two Building has rooms
Ans
Composition
Aggregation
Generalization
Hierarchy

114. which of the following tag represents a section of the document intended for
navigation in html5?
Ans= nav

115. A Software needs to be developed for a Sterlin Hospital to monitor the radiations given
for cancer patients. Even a very minute
deviation would result in the risk of the life of the patient. Which would be the appropriate life
cycle model used to implement
the given scenario
Select one:
a. Agile
b. Prototyping
c. Water fall
d. Spiral

116. which of the following operations can be used instead of the or operator
when there are multiple values that need to be compared
Ans = IN

117. Consider the scenario. For an insurance, a customer makes a claim. The claim
can be a
normal or a critical claim. The insurance company confirms the claim. What diagram
can be used tounderstand the state changes of the component triggered by events
and the dynamic
nature
Correct answer : state chart diagram

118. which of the following is not a principle of dsdm?


Ans = easy to understand modes

119.
Startprogram
Body{
Background-color : rgba(0,0,0,0);
}
Endprogram
Ans = fully transparant

120. in javascript what will be returned by the following code


snippet?
Startprogram
Document.write(new date().getmonth());
Endprogram
Ans = month as number from 0 to 11

121. class ClassA


protected void show(){
System.out.print("Super Class Method"),
}
class ClassB extends ClassA{
private void show(){ System.out.print("Sub Class Method");
}
public static void main(String[] args){ ClassB subObj = new ClassB();
subObj.show();
}
}
Ans = compite time error

122. class One {


}
class Two extends One {
}

public class Main {


static String s="Print";
public static void main(String[] args)
{
One[] a=new One[2];
Two[] b = new Two[2];
print(a);
print(b);
print(7);
System.out.println(s);
}

static void print (One[]...a2){


s +="1";
}
static void print(Two[]...b1) {
s += "2";
}
static void print(Two[] b1) {
s += "3";
}
static void print(Object o) {
s += "4";
}
}

Ans= print 434


123. . The object which is used to fetch the input from an element for
processing is
Ans= document

125. Which of the following tags is used to define a multi-line input field?
Ans: datalist /textarea

126. SPOT THE ERROR:


Observe the below algorithm to fifind the average of three numbers.
Step1: Start
Step2: Get num1, num2, num3
Step3: Add num1, num2, num3 and store it in Sum
Step4: Average=sum%3
Step5: Display Sum and Average
Step6: Stop
Identify the incorrect step(if any)
Ans= step4
startprogram

Select to_char(report_date,
‘Mon’) as MONTH, status
from AQI_DELHI;

Endprogram

22
333

Option 1 Ans=
startprogram
Echo “enter the number”
Read n
For((i=1;i<=n;i++))
Do for ((j=1;j<=i;j++))
Do
Echo -e “$i \c”
Done echo “ ”
Done
endprogram
red

What is the purpose of groupcount()


method with respect to regular
expressions? c
Ans= b and c

import java.util.ArrayList;
public class testuserMain{
public static void main(String[] anrgs)
{
ArrayList<String> a1=new ArrayList<String>(5);
a1.add("Ten");
a1.add("Twenty");
a1.add(4,"Fifty");
a1.add("thirty");
a1.add("Fourty" );
System.out.println(a1);}}

Ans= indexoutofbound

public class Parent{


public static final void displayATMAMOUNT()
{
System.out.println("500000");
}}
public class child extends Parent{
public void displayATMAMOUNT
{
System.out.println("600000");
}}
public static void main (String[] args) {
child c=new child();
c.displayATMAMOUNT();
}
Ans= CTE
which of the given phases consume more time during software life cycle
correct op9on: Maintenance

114. Which of the given options define a set of activities that transform the client needs to an
effective software solution
Ans-Software planning
Software cost estimation
Software development process
Software resource planning

. Root is super user in unix operating system and it is represented using


Ans=/

. Choose the statement that true about Class?


Ans
Class is a dynamic component
Class is described using attributes and methods
Change the class to change the state of an object
Class properties depends on object properties

. Carefully read the question and answer accordingly. In an array, if an item to be searched is
found in the middle of an array then it is said to be
ans= average case

. Which is the correct implementation for a progress bar in HTML5


Ans- #review
<progress value=”20” max=”100”></progress>

Class bird{
System.out.print("b1");
}
public Bird(){
System.out.print ("b2");
}
Correct answer:r1 E2 Testman b1 b2 E1 r2 M1

class ClassA{

protected void show(){

System.out.print("Super Class Method");


}}
class ClassB extends ClassA
{
private void show(){

System.out.print("Sub Class Method");


}

public static void main(String[] args)


{
ClassB subObj = new ClassB();
subObj.show();
}}
Ans=compilation error

Which of the following is used to reference data that can act as an abbreviation or can be
found at an external location?
Ans- ENTITY
In a CSS script, each property of an element is separated by a
Ans – semicolon (;)

46. Which jquery syntax hides all the paragraph elements


Ans-
$(“p”).hide();

Integer i=new Integer(-5);


Double d=new Double(new Integer(-6));
System.out.println(i%d);
short no=4;
System.out.println((no-i)*d);

Ans= -5.0
-54.0

You might also like