0

How to assign length of Array through input, in C

11th Nov 2018, 6:04 PM
Elliot
Elliot - avatar
2 odpowiedzi
+ 11
int size ; scanf("%d", &size) ; // 1D Dynamic Array int *arr = malloc(size * sizeof(int)) ; // Freeing memory free(arr) ;
11th Nov 2018, 6:37 PM
blACk sh4d0w
blACk sh4d0w - avatar
+ 1
nAutAxH AhmAd thanks👍
12th Nov 2018, 4:50 AM
Elliot
Elliot - avatar