Segmentation fault

What happens in the memory when there is a segmentation fault?

hi @Ayush-Kokande-2816457821730452

Segmentation fault is a specific kind of error caused by accessing memory that “does not belong to you.”

It’s a helper mechanism that keeps you from corrupting the memory and introducing hard-to-debug memory bugs.

Whenever you get a segfault you know you are doing something wrong with memory – accessing variable that has already been freed, writing to a read-only portion of the memory, etc.

i hope this help
if you have more doubts regarding this feel free to ask
if your doubt is resolved mark it as resolved from your doubt section inside your course

if you have more doubts regarding this feel free to ask

if your doubt is resolved mark it as resolved from your doubt section inside your course

I hope I’ve cleared your doubt. I ask you to please rate your experience here
Your feedback is very important. It helps us improve our platform and hence provide you
the learning experience you deserve.

On the off chance, you still have some questions or not find the answers satisfactory, you may reopen
the doubt.