This is what I found during my learning period:
#include
using namespace std;
int dis(char a[1])
{
int length = strlen(a);
char c = a
It's a fun feature of C that allows you to effectively shoot yourself in the foot if you're so inclined.
I think the reason is that C is just a step above assembly language. Size checking and similar safety features have been removed to allow for peak performance, which isn't a bad thing if the programmer is being very diligent.
Also, assigning a size to the function argument has the advantage that when the function is used by another programmer, there's a chance they'll notice a size restriction. Just using a pointer doesn't convey that information to the next programmer.