1
How to pass a array to a function without me having to inform the amount of indexes it has?
Stating the size
#include "stdafx.h"
#include <Windows.h>
void imprimir(int _array[], int _tamanho) {
    for (int i = 0; i < _tamanho; i++) {
        printf("%d\n", _array[i]);
    }
}
int main()
{
    int myArray[] = { 1, 2, 3, 4, 5 };
    imprimir(myArray, 5);
    getchar();
    return 0;
}
Without the size
#include "stdafx.h"
#include <Windows.h>
void imprimir(int _array[]) {
    // Aqui ele deve ser capaz de descobrir sozinho o tamanho da array.
    int tamanho = _array[].tamanho; // Apenas uma abstração.
    for (int i = 0; i < tamanho ; i++) {
        printf("%d\n", _array[i]);
    }
}
int main()
{
    int myArray[] = { 1, 2, 3, 4, 5 };
    imprimir(myArray);
    getchar();
    return 0;
}
I would like to give my program intelligence so that it will be able to figure out the size of the array without having to pass it as a parameter.