how to take comma separated integer input in c 1

how to take comma separated integer input in c

scanf("%d,",&arr[i]);

Here is what the above code is Doing:
1. It’s taking the input from the user and storing it in a variable called input.
2. It’s splitting the input string into an array of strings, each string being a number.
3. It’s converting each string into an integer and storing it in an array called arr.

Similar Posts