C Pointers Exercise 4 : Storing and print array elements using pointers [C Programming]

preview_player
Показать описание
Write a program in C to store n elements in an array and print the elements using pointer.

Test Data:
Input the number of elements to store in the array : 5
Input 5 input number of elements in the array :
element - 0 : 5
element - 1 : 7
element - 2 : 2
element - 3 : 9
element - 4 : 8

Expected Output:
The elements you entered are :
element - 0 : 5
element - 1 : 7
element - 2 : 2
element - 3 : 9
element - 4 : 8

==================================


Рекомендации по теме
Комментарии
Автор

I didn't understand the logic behind scanf("%d", userInputs + elementCounter); and *(userInputs + elementCounter);
Why did you wrote like that? Can you explain to me please?

Great videos btw.. These videos are helping me a lot :)

pinkechowdhury
join shbcf.ru