+3

how to define length of an array after taking an input from the user

c

4/2/2020 7:42:59 AM

Addaganti Naga Sai Rajeev

4 Answers

New Answer

+4

(1) Declare an int n (2) Input value and store it in n (3) Declare array int arr[n];

+4

+2

Is user input a number that defines the array length? if not, can you please describe what you want to do clearly.

+1

https://www.sololearn.com/learn/C/2947/?ref=app https://www.sololearn.com/learn/C/2950/?ref=app