Explore topic-wise InterviewSolutions in Current Affairs.

This section includes 7 InterviewSolutions, each offering curated multiple-choice questions to sharpen your Current Affairs knowledge and support exam preparation. Choose a topic below to get started.

1.

What Is A Simple Graph?

Answer»

A SIMPLE graph is a graph, which has not more than ONE EDGE between a PAIR of NODES than such a graph is called a simple graph.

A simple graph is a graph, which has not more than one edge between a pair of nodes than such a graph is called a simple graph.

2.

What Is A Weighted Graph?

Answer»

A GRAPH in which WEIGHTS are assigned to EVERY EDGE is CALLED a weighted graph.

A graph in which weights are assigned to every edge is called a weighted graph.

3.

Define Outdegree Of A Graph?

Answer»

In a DIRECTED GRAPH, for any node v, the NUMBER of edges which have v as their initial node is called the out DEGREE of the node v.

In a directed graph, for any node v, the number of edges which have v as their initial node is called the out degree of the node v.

4.

Define Indegree Of A Graph?

Answer»

In a directed graph, for any NODE V, the NUMBER of edges which have v as their terminal node is CALLED the indegree of the node v.

In a directed graph, for any node v, the number of edges which have v as their terminal node is called the indegree of the node v.

5.

Define Path In A Graph?

Answer»

The path in a graph is the route TAKEN to reach terminal NODE from a STARTING node.

The path in a graph is the route taken to reach terminal node from a starting node.

6.

What Is A Simple Path?

Answer»

A path in a DIAGRAM in which the edges are DISTINCT is CALLED a simple path. It is ALSO called as edge simple.

A path in a diagram in which the edges are distinct is called a simple path. It is also called as edge simple.

7.

What Is A Cycle Or A Circuit?

Answer»

A PATH which ORIGINATES and ENDS in the same node is called a CYCLE or circuit.

A path which originates and ends in the same node is called a cycle or circuit.

8.

What Is An Acyclic Graph?

Answer»

A simple DIAGRAM which does not have any cycles is CALLED an ACYCLIC graph.

A simple diagram which does not have any cycles is called an acyclic graph.

9.

What Is Meant By Strongly Connected In A Graph?

Answer»

An undirected graph is CONNECTED, if there is a path from EVERY vertex to every other vertex. A DIRECTED graph with this PROPERTY is CALLED strongly connected.

An undirected graph is connected, if there is a path from every vertex to every other vertex. A directed graph with this property is called strongly connected.

10.

When Is A Graph Said To Be Weakly Connected?

Answer»

When a DIRECTED GRAPH is not strongly connected but the UNDERLYING graph is connected, then the graph is SAID to be weakly connected.

When a directed graph is not strongly connected but the underlying graph is connected, then the graph is said to be weakly connected.

11.

What Are The Two Traversal Strategies Used In Traversing A Graph?

Answer»
  1. BREADTH FIRST SEARCH
  2. DEPTH first search

12.

What Is A Minimum Spanning Tree?

Answer»

A MINIMUM spanning TREE of an UNDIRECTED graph G is a tree FORMED from graph edges that CONNECTS all the vertices of G at the lowest total cost.

A minimum spanning tree of an undirected graph G is a tree formed from graph edges that connects all the vertices of G at the lowest total cost.

13.

Name Two Algorithms Two Find Minimum Spanning Tree?

Answer»

14.

Define Graph Traversals?

Answer»

Traversing a graph is an EFFICIENT way to VISIT each vertex and edge EXACTLY once.

Traversing a graph is an efficient way to visit each vertex and edge exactly once.

15.

List The Two Important Key Points Of Depth First Search?

Answer»

i) If path exists from one node to another node, WALK across the edge – exploring the edge.
ii) If path does not exist from one specific node to any other node, RETURN to the PREVIOUS node where we have been before – BACKTRACKING.

i) If path exists from one node to another node, walk across the edge – exploring the edge.
ii) If path does not exist from one specific node to any other node, return to the previous node where we have been before – backtracking.

16.

What Do You Mean By Breadth First Search (bfs)?

Answer»

BFS PERFORMS simultaneous explorations STARTING from a COMMON point and spreading out independently.

BFS performs simultaneous explorations starting from a common point and spreading out independently.

17.

Differentiate Bfs And Dfs?

Answer»

 

 

18.

What Do You Mean By Tree Edge?

Answer»

If W is undiscovered at the TIME vw is explored, then vw is called a tree edge and V becomes the PARENT of w.

If w is undiscovered at the time vw is explored, then vw is called a tree edge and v becomes the parent of w.

19.

What Do You Mean By Back Edge?

Answer»

If w is the ANCESTOR of V, then VW is CALLED a back edge.

If w is the ancestor of v, then vw is called a back edge.

20.

Define Biconnectivity?

Answer»

A connected graph G is SAID to be biconnected, if it remains connected after removal of any one vertex and the EDGES that are INCIDENT UPON that vertex. A connected graph is biconnected, if it has no articulation points.

A connected graph G is said to be biconnected, if it remains connected after removal of any one vertex and the edges that are incident upon that vertex. A connected graph is biconnected, if it has no articulation points.

21.

What Do You Mean By Articulation Point?

Answer»

If a GRAPH is not biconnected, the vertices WHOSE removal would disconnect the graph are KNOWN as ARTICULATION points.

If a graph is not biconnected, the vertices whose removal would disconnect the graph are known as articulation points.

22.

What Do You Mean By Shortest Path?

Answer»

A PATH having minimum weight between two VERTICES is KNOWN as shortest path, in which weight is always a positive NUMBER.

A path having minimum weight between two vertices is known as shortest path, in which weight is always a positive number.

23.

Why You Need A Data Structure?

Answer»

A data structure helps you to UNDERSTAND the relationship of one data element with the other and organize it within the MEMORY. Sometimes the organization might be SIMPLE and can be very clearly visioned.

Eg; List of names of months in a year –Linear Data Structure, List of historical places in the WORLD- Non-Linear Data Structure. A data structure helps you to analyze the data, store it and organize it in a logical and mathematical manner.

A data structure helps you to understand the relationship of one data element with the other and organize it within the memory. Sometimes the organization might be simple and can be very clearly visioned.

Eg; List of names of months in a year –Linear Data Structure, List of historical places in the world- Non-Linear Data Structure. A data structure helps you to analyze the data, store it and organize it in a logical and mathematical manner.

24.

Define A Deque?

Answer»

Deque (Double-Ended Queue) is ANOTHER form of a queue in which insertions and deletions are made at both the front and rear ends of the queue. There are two VARIATIONS of a deque, namely, input RESTRICTED deque and output restricted deque. The input restricted deque ALLOWS insertion at ONE end (it can be either front or rear) only. The output restricted deque allows deletion at one end (it can be either front or rear) only.

Deque (Double-Ended Queue) is another form of a queue in which insertions and deletions are made at both the front and rear ends of the queue. There are two variations of a deque, namely, input restricted deque and output restricted deque. The input restricted deque allows insertion at one end (it can be either front or rear) only. The output restricted deque allows deletion at one end (it can be either front or rear) only.

25.

State The Difference Between Queues And Linked Lists?

Answer»

The difference between QUEUES and linked lists is that INSERTIONS and deletions may occur anywhere in the linked list, but in queues insertions can be MADE only in the REAR end and deletions can be made only in the front end.

The difference between queues and linked lists is that insertions and deletions may occur anywhere in the linked list, but in queues insertions can be made only in the rear end and deletions can be made only in the front end.

26.

Define A Priority Queue?

Answer»

PRIORITY queue is a collection of elements, each containing a key referred as the priority for that element. Elements can be inserted in any order (i.e., of alternating priority), but are ARRANGED in order of their priority VALUE in the queue. The elements are deleted from the queue in the order of their priority (i.e., the elements with the HIGHEST priority is deleted first). The elements with the same priority are given EQUAL importance and processed accordingly.

Priority queue is a collection of elements, each containing a key referred as the priority for that element. Elements can be inserted in any order (i.e., of alternating priority), but are arranged in order of their priority value in the queue. The elements are deleted from the queue in the order of their priority (i.e., the elements with the highest priority is deleted first). The elements with the same priority are given equal importance and processed accordingly.

27.

Define A Queue?

Answer»

Queue is an ordered COLLECTION of elements in which insertions are restricted to one end CALLED the rear end and deletions are restricted to other end called the FRONT end. Queues are also referred as First-In-First-Out (FIFO) Lists.

Queue is an ordered collection of elements in which insertions are restricted to one end called the rear end and deletions are restricted to other end called the front end. Queues are also referred as First-In-First-Out (FIFO) Lists.

28.

Mention The Advantages Of Representing Stacks Using Linked Lists Than Arrays?

Answer»
  • It is not necessary to specify the number of elements to be stored in a stack during its declaration, SINCE memory is allocated dynamically at run time when an element is added to the stack.
  • Insertions and deletions can be handled easily and efficiently.
  • Linked LIST representation of STACKS can grow and shrink in size without wasting memory SPACE, depending upon the insertion and DELETION that occurs in the list.
  • Multiple stacks can be represented efficiently using a chain for each stack.

29.

State The Difference Between Stacks And Linked Lists?

Answer»

The DIFFERENCE between STACKS and linked lists is that insertions and deletions MAY OCCUR anywhere in a linked list, but only at the top of the STACK.

The difference between stacks and linked lists is that insertions and deletions may occur anywhere in a linked list, but only at the top of the stack.

30.

State The Rules To Be Followed During Infix To Prefix Conversions?

Answer»
  • Fully parenthesize the EXPRESSION starting from left to right. During parenthesizing, the OPERATORS having HIGHER precedence are first parenthesized.
  • Move the operators one by one to their left, such that each operator replaces their corresponding left parenthesis.
  • The part of the expression, which has been CONVERTED into PREFIX is to be treated as single operand.
  • Once the expression is converted into prefix form, remove all parenthesis.

31.

State The Rules To Be Followed During Infix To Postfix Conversions?

Answer»
  • Fully PARENTHESIZE the expression STARTING from left to RIGHT. During parenthesizing, the operators having higher precedence are first parenthesized.
  • Move the operators one by one to their right, such that each operator replaces their corresponding right parenthesis.
  • The part of the expression, which has been converted into postfix is to be treated as single operand.
  • Once the expression is converted into postfix form, remove all parenthesis.

32.

State The Advantages Of Using Postfix Notations?

Answer»
  • Need not worry about the RULES of precedence.
  • Need not worry about the rules for right to LEFT associativity.
  • Need not need PARENTHESIS to override the above rules.

33.

State The Advantages Of Using Infix Notations?

Answer»

34.

State The Different Ways Of Representing Expressions?

Answer»

The different WAYS of REPRESENTING EXPRESSIONS are

The different ways of representing expressions are

35.

List Out The Basic Operations That Can Be Performed On A Stack ?

Answer»

The BASIC OPERATIONS that can be PERFORMED on a stack are

  • Push OPERATION.
  • Pop operation.
  • Peek operation.
  • Empty check.
  • Fully occupied check.

The basic operations that can be performed on a stack are

36.

Define A Stack?

Answer»

STACK is an ordered collection of elements in which insertions and deletions are restricted to one end. The end from which elements are added and/or removed is referred to as top of the stack. STACKS are ALSO referred as piles, push-down lists and last-in-first-out (LIFO) lists.

Stack is an ordered collection of elements in which insertions and deletions are restricted to one end. The end from which elements are added and/or removed is referred to as top of the stack. Stacks are also referred as piles, push-down lists and last-in-first-out (LIFO) lists.

37.

State The Difference Between Arrays And Linked Lists?

Answer»

 

 

38.

List Out The Applications Of A Linked List?

Answer»

Some of the important APPLICATIONS of linked lists are manipulation of POLYNOMIALS, SPARSE matrices, stacks and QUEUES.

Some of the important applications of linked lists are manipulation of polynomials, sparse matrices, stacks and queues.

39.

List Out The Disadvantages Of Using A Linked List?

Answer»

40.

List Out The Advantages Of Using A Linked List?

Answer»
  • It is not necessary to specify the number of elements in a LINKED list during its declaration.
  • Linked list can grow and shrink in size depending upon the insertion and deletion that occurs in the list.
  • Insertions and deletions at any PLACE in a list can be handled easily and EFFICIENTLY.
  • A linked list does not waste any memory SPACE.

41.

List The Basic Operations Carried Out In A Linked List?

Answer»

The basic operations CARRIED out in a LINKED LIST include:

  • Creation of a list.
  • Insertion of a NODE.
  • Deletion of a node.
  • Modification of a node.
  • TRAVERSAL of the list.

The basic operations carried out in a linked list include:

42.

State The Different Types Of Linked Lists?

Answer»

The different types of LINKED LIST include SINGLY linked list, DOUBLY linked list and circular linked list.

The different types of linked list include singly linked list, doubly linked list and circular linked list.

43.

Define Linked Lists?

Answer»

Linked list consists of a series of structures, which are not necessarily adjacent in memory. Each STRUCTURE CONTAINS the element and a POINTER to a structure containing its successor. We call this the Next Pointer. The LAST cell’s Next pointer points to NULL.

Linked list consists of a series of structures, which are not necessarily adjacent in memory. Each structure contains the element and a pointer to a structure containing its successor. We call this the Next Pointer. The last cell’s Next pointer points to NULL.

44.

Define Non-linear Data Structures?

Answer»

Non-LINEAR DATA structures are data structures that don’t have a linear relationship between its adjacent ELEMENTS but have a hierarchical relationship between the elements.

EG; Trees and Graphs.

Non-linear data structures are data structures that don’t have a linear relationship between its adjacent elements but have a hierarchical relationship between the elements.

Eg; Trees and Graphs.

45.

Define Linear Data Structures?

Answer»

LINEAR data structures are data structures having a linear relationship between its ADJACENT ELEMENTS.

EG; Linked LISTS.

Linear data structures are data structures having a linear relationship between its adjacent elements.

Eg; Linked lists.

46.

List Some Of The Dynamic Data Structures In C?

Answer»

Some of the DYNAMIC DATA structures in C are LINKED lists, stacks, queues, TREES etc.

Some of the dynamic data structures in C are linked lists, stacks, queues, trees etc.

47.

Define Dynamic Data Structures?

Answer»

A DATA STRUCTURE FORMED when the number of data items are not KNOWN in advance is known as dynamic data structure or VARIABLE size data structure.

A data structure formed when the number of data items are not known in advance is known as dynamic data structure or variable size data structure.

48.

List Some Of The Static Data Structures In C?

Answer»

Some of the static DATA structures in C are ARRAYS, pointers, structures ETC.

Some of the static data structures in C are arrays, pointers, structures etc.

49.

Define Static Data Structures?

Answer»

A data STRUCTURE formed when the NUMBER of data items are known in ADVANCE is referred as static data structure or fixed SIZE data structure.

A data structure formed when the number of data items are known in advance is referred as static data structure or fixed size data structure.

50.

Define Primary Data Structures?

Answer»

Primary data structures are the BASIC data structures that directly OPERATE UPON the machine INSTRUCTIONS. All the basic constants (integers, floating-point numbers, character constants, STRING constants) and pointers are considered as primary data structures.

Primary data structures are the basic data structures that directly operate upon the machine instructions. All the basic constants (integers, floating-point numbers, character constants, string constants) and pointers are considered as primary data structures.