iLink Digital
Khansaheb Civil Engineering LLC Interview Questions and Answers
Q1. what's difference in pass by reference and pass by pointer which one is better?
Pass by reference and pass by pointer are both ways to pass data to a function, but they differ in how they access and modify the data.
Pass by reference uses a reference to the original variable, allowing direct access and modification.
Pass by pointer uses a pointer to the memory address of the variable, requiring dereferencing to access and modify the data.
Pass by reference is generally considered safer and more convenient, while pass by pointer offers more flexibility and c...read more
Q2. what's thread synchronization semaphores in threading what's critical section in threading One threading problem with 3 threads and how will you synchronize them?
Thread synchronization is the coordination of multiple threads to ensure they access shared resources in a controlled manner.
Thread synchronization prevents race conditions and data inconsistencies.
Semaphores are synchronization primitives used to control access to resources.
Critical sections are code segments that must be executed atomically.
A common threading problem is the producer-consumer problem.
Synchronization mechanisms like locks, semaphores, or condition variables c...read more
Q3. what is pure virtual function write one example of pure virtual function
A pure virtual function is a function declared in a base class that has no implementation and must be overridden in derived classes.
Pure virtual functions are used to create abstract classes, which cannot be instantiated.
They provide a common interface for derived classes to implement their own functionality.
An example of a pure virtual function is a 'draw' function in a base 'Shape' class, which must be implemented by derived classes like 'Circle' or 'Rectangle'.
Q4. Why OOP is needed what's encapsulation, abstraction, polymorphism different types of polymorphism
OOP is needed for modular and reusable code. Encapsulation hides implementation details. Abstraction simplifies complex systems. Polymorphism allows objects to take on multiple forms.
OOP promotes code reusability and modularity
Encapsulation hides implementation details and protects data
Abstraction simplifies complex systems by focusing on essential features
Polymorphism allows objects to be used in multiple ways
Types of polymorphism include compile-time and runtime polymorphis...read more
Q5. What's manage and unmage in C++
manage and unmanage are not standard terms in C++
There are no standard terms or concepts called 'manage' and 'unmanage' in C++
These terms might be specific to a particular framework or library
Without more context, it is difficult to provide a specific answer
Q6. what's vtable and vpointer explain by drawing
vtable is a virtual function table used in object-oriented programming to implement dynamic dispatch.
vtable is a data structure that contains pointers to the virtual functions of a class.
vpointer is a pointer that points to the vtable of an object.
It allows objects of different derived classes to be treated as objects of the base class.
When a virtual function is called, the vpointer is used to find the correct function in the vtable.
Q7. how to make dll. Can you make simple dll file
A DLL (Dynamic Link Library) is a file containing code and data that can be used by multiple programs simultaneously.
To create a DLL, you need to write the code in a programming language like C++ or C#.
Compile the code into an object file and then link it with a DLL linker to create the DLL file.
DLLs can contain functions, classes, variables, and resources that can be accessed by other programs.
DLLs provide code reusability, modularity, and allow for easier maintenance and up...read more
Q8. Difference between C and C++
C is a procedural programming language, while C++ is an extension of C with object-oriented programming features.
C is a procedural language, while C++ supports both procedural and object-oriented programming paradigms.
C++ has additional features like classes, objects, inheritance, and polymorphism.
C++ supports exception handling and templates, which are not available in C.
C++ has a standard template library (STL) that provides ready-to-use data structures and algorithms.
C++ a...read more
Q9. Write a basic code you know in python
A basic code in Python
Print 'Hello, World!' using print() function
Create a variable and assign a value to it
Use if-else statement to check a condition
Create a function and call it
Interview Process at Khansaheb Civil Engineering LLC
Top Software Engineer Interview Questions from Similar Companies
Reviews
Interviews
Salaries
Users/Month