what are the various memory handling mechanisms in C ?

Answer Posted / venkatesh kr

In C Language we can use the malloc, calloc & ralloc for memory handling but if we use the above function we should free the memory when the memory is not required.It can be done by "free" function. And also one important point is, suppose if we allocate a memory for an structure and in the process time if the structure is not required the it should be removed by using the "free" function because the system or process will be get crashed on some situations.

Is This Answer Correct ?    2 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Explain goto?

934


What is d'n in c?

846


What is a void * in c?

852


How can you invoke another program from within a C program?

837


What is #include stdio h and #include conio h?

786


Write a client and server program in C language using UDP, where client program interact with the Server as given below: i) The client begins by sending a request to send a string of 8 characters or series of 7 numbers, the server sends back a characters or numbers as per the request of the client. ii) In case of series of 7 numbers: The client sends a multiplication of numbers, to the server. iii) In case of a string of 8 characters: The client sends a reverse order of string to the server.. iv) Server will send an acknowledgment to the client after receiving the correct answer

4120


What is difference between main and void main?

877


How to declare pointer variables?

923


How does pointer work in c?

858


Explain what does it mean when a pointer is used in an if statement?

850


Do variables need to be initialized?

826


What does c value mean?

879


What is calloc malloc realloc in c?

831


How can you find out how much memory is available?

830


A global variable when referred to in another file is declared as this a) local variable b) external variable c) constant d) pointers

892