What is segmentation fault in C with example?

What is segmentation fault in C with example?
Answer
A segmentation fault occurs when a program attempts to access a memory location that it is not allowed to access, or attempts to access a memory location in a way that is not allowed (for example, attempting to write to a read-only location, or to overwrite part of the operating system).
 

Tìm kiếm

Back
Top