One Convergence
30+ Theoddcoders Technologies Interview Questions and Answers
Given the head node of the singly linked list, return a pointer pointing to the middle of the linked list.
If there are an odd number of elements, return the middle element if there are eve...read more
You have been given two Strings “STR1” and “STR2” of characters. Your task is to find the length of the longest common subsequence.
A String ‘a’ is a subsequence of a String ‘b’ if ‘a’...read more
You are given an array of integers ARR[] of size N consisting of zeros and ones. You have to select a subset and flip bits of that subset. You have to return the count of maximum one’s that you can obt...read more
You are given a positive integer ‘N’. Your task is to find the total number of ‘1’ in the binary representation of all the numbers from 1 to N.
Since the count of ‘1’ can be huge, you are required...read more
You have been given a Binary Search Tree of integers. You are supposed to convert it to a greater sum tree such that the value of every node in the given BST is replaced with ...read more
You are given a string 'STR'. The string contains [a-z] [A-Z] [0-9] [special characters]. You have to find the reverse of the string.
For example:
If the given string is: STR = "abcde". You h...read more
What is deadlock?
What is segmentation fault?
What is page fault?
What is exception?
What will be stored in data section, heap, stack in memory?
What are application of stacks?
What is TTL in ipv...read more
Q8. What is IPC(inter process communication) and ITC(inter thread communication) and how it happens and how to implement it
IPC is a mechanism for communication between processes, while ITC is for communication between threads within a process.
IPC allows processes to exchange data and synchronize their actions.
ITC allows threads to share data and coordinate their activities.
IPC can be implemented using various techniques such as pipes, sockets, shared memory, and message queues.
ITC can be achieved through shared variables, message passing, and synchronization primitives.
Example of IPC: A client-se...read more
Q9. What are different types of memory segment and tell about different parts of program and where they are stored?
Memory segments include code, data, stack, and heap. Each segment stores different parts of a program in memory.
Code segment: stores the executable code of the program
Data segment: stores global and static variables
Stack segment: stores local variables and function call information
Heap segment: stores dynamically allocated memory
Q10. What is little endian ,big endian. How to implement it’s code?
Little endian and big endian are byte ordering formats. Little endian stores the least significant byte first, while big endian stores the most significant byte first.
Little endian and big endian refer to the order in which bytes are stored in memory.
In little endian, the least significant byte is stored first, followed by the more significant bytes.
In big endian, the most significant byte is stored first, followed by the less significant bytes.
Implementing code for little en...read more
Q11. Explain zombie, daemon and orphan processes and how they are different?
Zombie, daemon, and orphan processes are different types of processes in operating systems.
Zombie processes are dead processes that have completed execution but still have an entry in the process table.
Daemon processes are background processes that run continuously and perform specific tasks.
Orphan processes are child processes that continue to run even after their parent process has terminated.
Zombie processes consume system resources until they are removed from the process ...read more
Q12. How client and server establish their communication. How to create socket , explain step by step?
Client and server establish communication through sockets. Creating a socket involves several steps.
Client and server each create a socket object.
Server socket binds to a specific port number on the server machine.
Server socket listens for incoming client connections.
Client socket connects to the server socket using the server's IP address and port number.
Once the connection is established, client and server can exchange data through the socket.
What is SSH, SSL, SDN ?
Difference between TCP and UDP ?
What is virtual, physical memory?
What is critical section?
Q14. How to use gcc to compile program and what are different options available?
gcc is a command-line compiler used to compile programs written in C or C++.
To compile a program using gcc, use the command 'gcc
-o '. The '-o' option is used to specify the name of the output file.
By default, gcc compiles C programs. To compile C++ programs, use the '-x' option with 'c++' argument.
To enable warnings during compilation, use the '-Wall' option.
To optimize the compiled code, use the '-O' option followed by a level (e.g., '-O2' for level 2 optimization).
To inclu...read more
Q15. Describe switch in n/w and how will you implement its s/w
A switch in a network is a device that connects multiple devices together and forwards data packets between them.
A switch operates at the data link layer of the OSI model.
It uses MAC addresses to determine the destination of data packets.
Switches improve network performance by reducing collisions and providing dedicated bandwidth to each connected device.
Switches can be implemented using software-defined networking (SDN) technologies.
Examples of switch software include Cisco ...read more
What is NAT and what are its functions?
What is little endian and big endian?
Q18. How to create parent and child process and different threads?
To create parent and child processes, use fork() system call. To create threads, use pthread_create() function.
To create a child process, use fork() system call. The child process is an exact copy of the parent process.
To create threads, use pthread_create() function from pthread library.
Parent and child processes can communicate using inter-process communication mechanisms like pipes or shared memory.
Threads share the same memory space and can communicate directly through sh...read more
Q19. What are common segment used by parent and child processes?
The common segments used by parent and child processes are code segment, data segment, and stack segment.
Code segment: Contains the executable code of the program.
Data segment: Stores global and static variables.
Stack segment: Used for local variables and function calls.
What is the function of a bridge?
What is symbol table?
Q22. What is symbol table and what is it used for?
A symbol table is a data structure used by compilers and interpreters to store information about the variables, functions, and other symbols in a program.
It maps each symbol to its attributes, such as its data type, memory location, and scope.
Symbol tables are used during the compilation or interpretation process to resolve references to symbols and perform semantic analysis.
They enable efficient lookup and retrieval of symbol information during program execution.
Symbol table...read more
Q23. Write program to check common sequence in two string
Program to check common sequence in two strings
Iterate through each character of the first string
Check if the current character is present in the second string
If yes, add it to the common sequence array
Return the common sequence array
Q24. What is NAT and its functions ?
NAT stands for Network Address Translation. It is a process of translating IP addresses between different networks.
NAT allows multiple devices in a private network to share a single public IP address.
It provides security by hiding the internal IP addresses from external networks.
NAT enables the conservation of public IP addresses by allowing multiple devices to use a single IP.
It facilitates the routing of traffic between different networks.
NAT can be implemented using variou...read more
Difference between Zombie, Orphan and Daemon Processes
Explain the memory layout of a C program.
Q28. What are common segment used by threads?
The common segments used by threads are code segment, data segment, and stack segment.
Code segment: Contains the executable code of the program.
Data segment: Stores global and static variables.
Stack segment: Used for local variables and function call information.
Q29. What is linking? Explain in detail
Linking is the process of connecting different web pages or resources together through hyperlinks.
Linking is an essential aspect of the World Wide Web.
It allows users to navigate between different web pages by clicking on hyperlinks.
Hyperlinks can be text, images, or other elements that when clicked, direct the user to another web page or resource.
Linking helps in organizing and structuring information on the web.
It enables search engines to discover and index web pages.
Linki...read more
Q32. Write program to the bits which is set
This program finds and prints the bits that are set in a given number.
Use bitwise AND operator (&) to check if a bit is set.
Iterate through each bit of the number and print the position of the set bits.
Q33. Write program to reverse bits of number
Program to reverse the bits of a number
Convert the number to binary representation
Reverse the binary representation
Convert the reversed binary back to decimal
Q34. What is socket buffer?
A socket buffer is a data structure used by the operating system to store data being sent or received over a network socket.
Socket buffers are typically implemented as circular buffers.
They are used to temporarily hold data until it can be processed by the application.
Socket buffers have a fixed size and can be filled or emptied by the operating system or the application.
They help in managing the flow of data between the network and the application.
Examples of socket buffer i...read more
Q35. Write program to reverse string
Program to reverse a string
Use a loop to iterate through the characters of the string
Create a new string and append each character in reverse order
Return the reversed string
Q36. What is function of bridge?
A bridge is a structure that connects two separate areas, allowing for the passage of people, vehicles, or other forms of transportation.
Bridges provide a means of crossing obstacles such as rivers, valleys, or roads.
They facilitate the movement of people, vehicles, and goods from one place to another.
Bridges can be made of various materials such as concrete, steel, or wood.
They can be designed in different styles and shapes, including arches, suspension bridges, or beam brid...read more
Q37. What is VLAN ?
VLAN stands for Virtual Local Area Network. It is a technology that allows the creation of multiple virtual networks within a single physical network.
VLANs provide segmentation and isolation of network traffic.
They improve network performance and security.
VLANs can be used to group devices based on department, function, or security requirements.
They enable easier network management and troubleshooting.
VLANs are commonly used in large organizations, data centers, and cloud env...read more
Top Interview Questions from Similar Companies
Reviews
Interviews
Salaries
Users/Month