Tip 1 : Must do Previously asked Interview as well as Online Test Questions.
Tip 2 : Go through all the previous interview experiences from Codestudio and Leetcode.
Tip 3 : Do at-least 2 good projects and you must know every bit of them.
Tip 1 : Have at-least 2 good projects explained in short with all important points covered.
Tip 2 : Every skill must be mentioned.
Tip 3 : Focus on skills, projects and experiences more.
Technical interview round with questions based on DSA and OOPS.
How to dynamically allocate a 2D array in C?
Using pointer to a pointer : We can create an array of pointers also dynamically using a double pointer. Once we have an array pointers allocated dynamically, we can dynamically allocate memory and for every row.
int** arr = (int**)malloc(r * sizeof(int*));
for (i = 0; i < r; i++)
arr[i] = (int*)malloc(c * sizeof(int));
What are virtual functions in C++?
A virtual function is a member function which is declared within a base class and is re-defined (overridden) by a derived class. When you refer to a derived class object using a pointer or a reference to the base class, you can call a virtual function for that object and execute the derived class’s version of the function. Virtual functions ensure that the correct function is called for an object, regardless of the type of reference (or pointer) used for function call.
Features :
They are mainly used to achieve Runtime polymorphism
Functions are declared with a virtual keyword in base class.
The resolving of function call is done at runtime.
What are virtual base classes?
Virtual base classes are used in virtual inheritance in a way of preventing multiple “instances” of a given class appearing in an inheritance hierarchy when using multiple inheritances.
If you already have a memory, how will use that memory to allocate a new buffer?
Placement new operator can be used here. In placement new, we can pass a pre-allocated memory and construct an object in the passed memory.
Syntax :
new (address) (type) initializer
As we can see, we can specify an address where we want a new object of given type to be constructed.
Technical interview round with questions based on OS/Networking etc.
What is the system call which creates a seperate connection?
The accept() system call with the connection-based socket types(SOCK_STREAM, SOCK_SEQPACKET). It extracts the first connection request on queue of pending connections for the listening socket, sockfd, creates a new connected socket, and returns a new file descriptor referring to that socket. The newly created socket is not in the listening state. The original socket sockfd is unaffected by this call.
What does the epoll_wait() system call do?
The epoll_wait() system call waits for events on the epoll(7) instance referred to by the file descriptor epfd. The buffer pointed to by events is used to return information from the ready list about file descriptors in the interest list that have some events available.
What are the different protocols in transport layer?
The transport layer is represented by two protocols: TCP and UDP. The IP protocol in the network layer delivers a datagram from a source host to the destination host. Nowadays, the operating system supports multiuser and multiprocessing environments, an executing program is called a process. When a host sends a message to other host means that source process is sending a process to a destination process. The transport layer protocols define some connections to individual ports known as protocol ports. An IP protocol is a host-to-host protocol used to deliver a packet from source host to the destination host while transport layer protocols are port-to-port protocols that work on the top of the IP protocols to deliver the packet from the originating port to the IP services, and from IP services to the destination port. Each port is defined by a positive integer address, and it is of 16 bits.
Difference between TCP and UDP
1. Type of Service : TCP is a connection-oriented protocol. Connection-orientation means that the communicating devices should establish a connection before transmitting data and should close the connection after transmitting the data. UDP is the Datagram-oriented protocol. This is because there is no overhead for opening a connection, maintaining a connection, and terminating a connection. UDP is efficient for broadcast and multicast types of network transmission.
2. Reliability : TCP is reliable as it guarantees the delivery of data to the destination router. The delivery of data to the destination cannot be guaranteed in UDP.
3. Error checking mechanism : TCP provides extensive error-checking mechanisms. It is because it provides flow control and acknowledgment of data. UDP has only the basic error checking mechanism using checksums.
4. Acknowledgment : An acknowledgment segment is present in TCP. No acknowledgment segment in UDP.
5. Sequence : Sequencing of data is a feature of Transmission Control Protocol (TCP). this means that packets arrive in order at the receiver. There is no sequencing of data in UDP. If the order is required, it has to be managed by the application layer.
6. Speed : TCP is comparatively slower than UDP. UDP is faster, simpler, and more efficient than TCP.
7. Retransmission : Retransmission of lost packets is possible in TCP, but not in UDP. There is no retransmission of lost packets in the User Datagram Protocol (UDP).
Technical interview round with questions based on Networking etc.
What is the purpose of ICMP?
IP does not have a built-in mechanism that sends control messages and error messages. That is why a protocol like ICMP is needed. Practically, ICMP offers error control and often it is employed to report errors, send management queries and operations information. Network devices like routers need to use the ICMP in order to send the error messages. That is why ICMP is considered as a supporting protocol. It is a known fact that the lower Internet Layer does not need to be concerned with assuring the connection, yet ICMP is very much needed for important feedback when things go out of order.
Types of connection release supported by TCP
1. Graceful connection release –
In the Graceful connection release, the connection is open until both parties have closed their sides of the connection.
2. Abrupt connection release –
In an Abrupt connection release, either one TCP entity is forced to close the connection or one user closes both directions of data transfer.
Protocols used by MAC Layer ?
Following Protocols are used by Medium Access Layer :
1. ALOHA : ALOHA is a system for coordinating and arbitrating access to a shared communication channel. It was developed in the 1970s at the University of Hawaii. The original system used terrestrial radio broadcasting, but the system has been implemented in satellite communication systems. A shared communication system like ALOHA requires a method of handling collisions that occur when two or more systems attempt to transmit on the channel at the same time.
2. Carrier Sensed Multiple Access (CSMA) : CSMA is a network access method used on shared network topologies such as Ethernet to control access to the network. Devices attached to the network cable listen (carrier sense) before transmitting. If the channel is in use, devices wait before transmitting.
3.CSMA/CD (Carrier Sense Multiple Access/Collision Detection) : CD (collision detection) defines what happens when two devices sense a clear channel, then attempt to transmit at the same time. A collision occurs, and both devices stop transmission, wait for a random amount of time, and then retransmit. This is the technique used to access the 802.3 Ethernet network channel.
4.CSMA/CA (Carrier Sense Multiple Access/Collision Avoidance) : In CA collision avoidance), collisions are avoided because each node signals its intent to transmit before actually doing so. This method is not popular because it requires excessive overhead that reduces performance.
5. Ethernet : IEEE 802.3 Local Area Network (LAN) Protocols : Ethernet protocols refer to the family of local-area network (LAN)covered by the IEEE 802.3. In the Ethernet standard, there are two modes of operation: half-duplex and full-duplex modes. In the half duplex mode, data are transmitted using the popular Carrier-Sense Multiple Access/Collision Detection (CSMA/CD) protocol on a shared medium.
What is ARP protocol?
ARP stands for (Address Resolution Protocol) it is responsible to find the hardware address of a host from a know IP address there are three basic ARP terms.
ARP Cache: After resolving the MAC address, the ARP sends it to the source where it is stored in a table for future reference. The subsequent communications can use the MAC address from the table
ARP Cache Timeout: It indicates the time for which the MAC address in the ARP cache can reside
ARP request: This is nothing but broadcasting a packet over the network to validate whether we came across the destination MAC address or not.
The physical address of the sender.
The IP address of the sender.
The physical address of the receiver is FF:FF:FF:FF:FF:FF or 1’s.
The IP address of the receiver
ARP response/reply: It is the MAC address response that the source receives from the destination which aids in further communication of the data.

Here's your problem of the day
Solving this problem will increase your chance to get selected in this company
How do you remove whitespace from the start of a string?