Basic C Questions


#include <stdio.h>

int main()
{
    char *p = "rak";
    *p = "dkfg";
    printf("p = %s", p);
}

Output: Segmentation fault will happen.

Reasons for a C++ program crash



How to find Segmentation Error in C & C++ ? (Using GDB)

Segmentation Fault (SIGSEGV) vs Bus Error (SIGBUS)


Can you design Netflix in 45 minutes?













































































Comments

Popular posts from this blog

Given a set of non-negative integers, and a value sum, determine if there is a subset of the given set with sum equal to given sum.

[15 Feb 2020] Remove duplicates from a string in O(1) extra space

[18 Feb 2020] Program to check if a matrix is symmetric