REVATURE INTERVIEW QUESTIONS AND ANSWERS| LATEST UPDATE
100% SOLVED
What does static mean in C# ? Means that the variable belongs to the type itself and not to
instances of the class. Used to create data and methods that can be accessed without creating
an instance of the Class
What's the difference between a Set and a Map? Set doesn't allow duplicates, while a map
does, though it has unique keys.
What's the difference between an Array List and a Linked List and which is preferable?
Arraylist uses a dynamic array to store data, while linkedlist uses a double-linked list to store
the elements. Adding or removing elements is slower in the arraylist because shifting all of the
bits is required, unlike the linked list. Arraylist acts as a list only while linkedlist can act as a list
and a queue.
It depends on the situation, ArrayList is better for storing and accessing data, and LinkedList is
better for manipulating data.
What is a wrapper class? They convert primitive data types into objects. Objects are needed
if we wish to modify the arguments passed into a method.
What is a Join? What is the difference between HAVING clause and WHERE clause?
Combines columns from two or more tables. The difference between the two is in the
,relationship to the GROUP BY clause: WHERE comes before GROUP BY; SQL evaluates the
WHERE clause before it groups records. HAVING is used with aggregate functions after the
GROUP BY statement.
difference between union and unionall UNION removes duplicate rows, while UNIONALL
doesn't. UNIONALL is faster as a result.
Do you know what multi-threading is? How do you do it (how would you start/stop a thread)?
The main purpose is to provide simultaneous execution of two or more parts of a program
to maximize the CPU usage.A multithreaded program contains two or more parts that can run
concurrently. .
Thread thread = new Thread();
To start a thread:
thread.start();
To stop a thread:
Create a boolean variable flag and set it to true
Create a method to stop the thread, which sets the variable to false.
Use a while(flag) loop, and when you want to stop it call the stop thread method.
, Whats the difference between a == and === in javascript? "===" checks to see if expressions
are the same as well as being equal.
Difference between INNER JOIN and OUTER JOIN An inner join searches tables for matching
or overlapping data. Upon finding it, the inner join combines and returns the information into
one new table that contains only the matches from each table.
An outer join returns a set of records (or rows) that include what an inner join would return but
also includes other rows for which no corresponding match is found in the other table.
Includes left outer join, which returns all records from the left table (table1), and the matched
records from the right table (table2). The result is NULL from the right side, if there is no match.
Also includes right outer join, which would include all records from the right table, and the
matched records from the left table, even if there are null values.
A full outer join joins all data from the two tables, even if there is no shared information.
Can you have multiple catch blocks on a try statement? Yes, but only the one that first
matches the exception type is executed.
Can you overload a constructor? Yes
100% SOLVED
What does static mean in C# ? Means that the variable belongs to the type itself and not to
instances of the class. Used to create data and methods that can be accessed without creating
an instance of the Class
What's the difference between a Set and a Map? Set doesn't allow duplicates, while a map
does, though it has unique keys.
What's the difference between an Array List and a Linked List and which is preferable?
Arraylist uses a dynamic array to store data, while linkedlist uses a double-linked list to store
the elements. Adding or removing elements is slower in the arraylist because shifting all of the
bits is required, unlike the linked list. Arraylist acts as a list only while linkedlist can act as a list
and a queue.
It depends on the situation, ArrayList is better for storing and accessing data, and LinkedList is
better for manipulating data.
What is a wrapper class? They convert primitive data types into objects. Objects are needed
if we wish to modify the arguments passed into a method.
What is a Join? What is the difference between HAVING clause and WHERE clause?
Combines columns from two or more tables. The difference between the two is in the
,relationship to the GROUP BY clause: WHERE comes before GROUP BY; SQL evaluates the
WHERE clause before it groups records. HAVING is used with aggregate functions after the
GROUP BY statement.
difference between union and unionall UNION removes duplicate rows, while UNIONALL
doesn't. UNIONALL is faster as a result.
Do you know what multi-threading is? How do you do it (how would you start/stop a thread)?
The main purpose is to provide simultaneous execution of two or more parts of a program
to maximize the CPU usage.A multithreaded program contains two or more parts that can run
concurrently. .
Thread thread = new Thread();
To start a thread:
thread.start();
To stop a thread:
Create a boolean variable flag and set it to true
Create a method to stop the thread, which sets the variable to false.
Use a while(flag) loop, and when you want to stop it call the stop thread method.
, Whats the difference between a == and === in javascript? "===" checks to see if expressions
are the same as well as being equal.
Difference between INNER JOIN and OUTER JOIN An inner join searches tables for matching
or overlapping data. Upon finding it, the inner join combines and returns the information into
one new table that contains only the matches from each table.
An outer join returns a set of records (or rows) that include what an inner join would return but
also includes other rows for which no corresponding match is found in the other table.
Includes left outer join, which returns all records from the left table (table1), and the matched
records from the right table (table2). The result is NULL from the right side, if there is no match.
Also includes right outer join, which would include all records from the right table, and the
matched records from the left table, even if there are null values.
A full outer join joins all data from the two tables, even if there is no shared information.
Can you have multiple catch blocks on a try statement? Yes, but only the one that first
matches the exception type is executed.
Can you overload a constructor? Yes