Skip to content
Gblog What is System Design – Learn System Design
System Design is the core concept behind the design of any distributed systems. System Design is defined as a process of creating an architecture for… Read More
Following questions have been asked in GATE CS exam. 1. It is desired to design an object-oriented employee record system for a company. Each employee… Read More
A constructor without any arguments or with the default value for every argument is said to be the Default constructor.  What is the significance of the… Read More
Given an unsorted array of size n. Array elements are in the range of 1 to n. One number from set {1, 2, …n} is… Read More
Given two binary trees, check if the first tree is a subtree of the second one. A subtree of a tree T is a tree… Read More
In C/C++, we can assign a struct (or class in C++ only) variable to another variable of same type. When we assign a struct variable… Read More
Initializer List is used in initializing the data members of a class. The list of members to be initialized is indicated with constructor as a… Read More
Predict the output of below C++ programs. Question 1 #include<iostream>    using namespace std;    class Test {     int value; public:     Test (int v =… Read More
Difficulty Level: RookiePredict the output of below C++ programs.Question 1   C++ #include<iostream> using namespace std;   class Test {     int value; public:     Test(int v); };… Read More
When are the constructors called for different types of objects like global, local, static local, dynamic? 1) Global objects: For a global object, constructor is called… Read More
Let us solve the classic “fake coin” puzzle using decision trees. There are the two different variants of the puzzle given below. I am providing… Read More
Difficulty Level: Rookie Predict the output of below C++ programs. Question 1 #include<iostream> using namespace std;    int x = 10; void fun() {     int… Read More
Question: We have discussed Naive String matching algorithm here. Consider a situation where all characters of pattern are different. Can we modify the original Naive… Read More
In C++, variables are passed by reference due to following reasons:1) To modify local variables of the caller function: A reference (or pointer) allows called… Read More
The N Queen is the problem of placing N chess queens on an N×N chessboard so that no two queens attack each other. For example,… Read More

Start Your Coding Journey Now!