You are passing the arrays to sameNumberCheckOfTwoArrays as pointers. In this process, the “array-ness” is dropped. Your function only sees an int* and reports the size accordingly.
More Related Contents:
- What is the difference between '.' and '->' when used in array? [closed]
- Why is sizeof giving incorrect number of bytes in C++?
- What is array to pointer decay?
- How do I use arrays in C++?
- Passing a 2D array to a C++ function
- Return array in a function
- determine size of array if passed to function
- Are arrays Pointers? [duplicate]
- Why does cout print char arrays differently from other arrays?
- C++ pass an array by reference
- Address of an array
- Determine the size of a C++ array programmatically?
- Returning arrays from a function in c++
- C/C++ int[] vs int* (pointers vs. array notation). What is the difference?
- May I take the address of the one-past-the-end element of an array? [duplicate]
- What is the purpose of allocating a specific amount of memory for arrays in C++?
- A pointer to 2d array
- Pointer-to-pointer dynamic two-dimensional array
- How to get the real and total length of char * (char array)?
- Casting pointer to Array (int* to int[2])
- How to make an array with a dynamic size? General usage of dynamic arrays (maybe pointers too)? [closed]
- Pointer interconvertibility vs having the same address
- Pointer to array with const qualifier in C & C++
- Pointer to array of unspecified size “(*p)[]” illegal in C++ but legal in C
- array decay to pointer and overload resolution
- array of pointers as function parameter
- Difference between passing array, fixed-sized array and base address of array as a function parameter
- how do arrays work internally in c/c++
- How can a char pointer be initialized with a string (Array of characters) but an int pointer not with an array of integer? [duplicate]
- Polymorphism & Pointers to arrays [duplicate]