Filter interviews by
malloc is used to allocate memory without initializing it, while calloc is used to allocate memory and initialize it to zero.
malloc allocates a block of memory of specified size but does not initialize the memory contents
calloc allocates a block of memory of specified size and initializes all bytes to zero
malloc is faster than calloc as it does not initialize the memory
calloc is useful when you want to ensure that the ...
malloc will return a pointer to the allocated memory block
malloc returns a void pointer (void *)
It returns NULL if it fails to allocate memory
Example: int *ptr = (int *)malloc(sizeof(int));
Top trending discussions
I am currently working on developing a mobile application for a client in the hospitality industry.
The application will allow users to make reservations and order food and drinks from their mobile devices.
We are using React Native for the front-end and Node.js for the back-end.
We are also implementing a payment gateway to allow for secure transactions.
The client has requested that the app be available in both iOS and A...
To debug a particular program without affecting others, use breakpoints and step through the code.
Set a breakpoint in the program you want to debug
Step through the code using a debugger to identify the issue
Use logging statements to track the flow of the program
Check the call stack to see which functions are being called
Use conditional breakpoints to stop the program at specific points
I applied via Walk-in and was interviewed before Jun 2021. There were 2 interview rounds.
HR told about the company on the first day, how it works, told the rules, showed the management and a lot
I applied via Referral and was interviewed in May 2021. There was 1 interview round.
I applied via Campus Placement and was interviewed before Feb 2020. There were 4 interview rounds.
If and Switch Case statements are used for conditional branching in programming.
If statements are used for simple conditional branching.
Switch Case statements are used for multiple conditional branching.
If statements are more flexible than Switch Case statements.
Switch Case statements are more efficient than If statements for large number of conditions.
If statements can be nested, but Switch Case statements cannot.
Exam...
Yes, algorithms and pseudocodes are still important in IT Services.
Algorithms are used in various fields of IT such as machine learning, data analysis, and cryptography.
Pseudocodes are used to plan and design algorithms before coding them.
Understanding algorithms and pseudocodes is essential for software engineers to write efficient and optimized code.
Examples of algorithms include sorting algorithms, search algorithms...
Yes, I am comfortable using both CLIs and IDEs for my daily tasks.
I have experience using various CLIs such as Git Bash, Windows Command Prompt, and Terminal on macOS.
I am proficient in using IDEs such as Visual Studio Code, Eclipse, and IntelliJ IDEA.
I understand the benefits and drawbacks of both CLIs and IDEs and can choose the appropriate tool for the task at hand.
I applied via Campus Placement and was interviewed in Nov 2020. There were 6 interview rounds.
OOPs concepts are the fundamental principles of object-oriented programming.
Encapsulation - binding data and functions that manipulate the data
Inheritance - creating new classes from existing ones
Polymorphism - ability of objects to take on many forms
Abstraction - hiding implementation details and showing only functionality
Storage classes in C define the scope and lifetime of variables.
There are four storage classes in C: auto, register, static, and extern.
Auto variables are local to a block and have automatic storage duration.
Register variables are stored in CPU registers for faster access.
Static variables have a lifetime throughout the program and are initialized only once.
Extern variables are declared outside any function and can be a...
I applied via Campus Placement and was interviewed in Sep 2021. There was 1 interview round.
Linked list is a linear data structure. DFS and BFS are graph traversal algorithms.
Linked list is a collection of nodes where each node points to the next node.
DFS (Depth First Search) is a traversal algorithm that explores as far as possible along each branch before backtracking.
BFS (Breadth First Search) is a traversal algorithm that explores all the vertices of a graph in breadth-first order.
Example of linked list: ...
Optimize O(n2) program to O(log n)
Use binary search instead of linear search
Divide and conquer approach can be used
Implement efficient data structures like heap, AVL tree, etc.
Reduce unnecessary iterations and comparisons
Use memoization to avoid redundant calculations
I applied via Campus Placement and was interviewed in May 2021. There were 4 interview rounds.
based on 1 interview experience
Difficulty level
Duration
Software Developer
18
salaries
| ₹3.1 L/yr - ₹6.1 L/yr |
Java Developer
12
salaries
| ₹5.2 L/yr - ₹7 L/yr |
Information Technology Recruiter
9
salaries
| ₹1.2 L/yr - ₹3 L/yr |
Linux System Administrator
7
salaries
| ₹4.5 L/yr - ₹7.5 L/yr |
Software Engineer
6
salaries
| ₹4.5 L/yr - ₹6.1 L/yr |
TCS
Accenture
Wipro
Cognizant