Strange things that i dont understand is going on with a snippet of code. as the Subject hints to. i created a custom function to accept a int low number, int increment, and int array. if you want to find the size of an array you do sizeof(yourArray)/ sizeof(ArrayType) this works if i run that on the first array which is declared out of setup and loop. but if i try to pass the array into my custom function. Shabam. the internet breaks. Yeah not as dramatic but it doesn't give the expected result. as best as i can figure. is that since in C the name of the array is the address to the first element of the array, that and only that element is used in the calculation of the sizeof() function. But why though is my question.
int TempArray[] = {1, 2,3,4,5,6}; //pass this array into the function below
void MakeBoundArray(int low, int inc, int array[]) {
int x = sizeof(array) / sizeof(int); returns 1
for (int i = 0; i < x; i = i + 1) {
array[i] = (low +( i * inc));
}