+ 1
Setting a Array to 0
Hello, can I in some way set an array=0? int array[]={0}; Works fine to set every value of the array =0, but when i use it inside the programm without the 'int' it won't work? Any ideas why?
3 ответов
+ 4
The first element of an array is termed with array[0], but your question requires more description
+ 1
Where is your program?
+ 1
Did you mention array[0] while using in your program? Since it has only one element inside it.
You can also use a pointer variable to access it. For eg --> int *a = array;