Skip to content

Instantly share code, notes, and snippets.

@pkrll
Created May 26, 2019 12:03
Show Gist options
  • Save pkrll/b045db245269381ef62daee930d28513 to your computer and use it in GitHub Desktop.
Save pkrll/b045db245269381ef62daee930d28513 to your computer and use it in GitHub Desktop.
Question 4
#include <stdlib.h>
int main() {
//!showGraph()
int **x = malloc(sizeof(int*)*2);
int *y = malloc(sizeof(int));
*x = y;
free(y);
int *z = malloc(sizeof(int));
x[1] = z;
return 0;
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment