What happens when a char array is initialized to '\0'?
I have a char array of size 512 i.e

    char buffer [512];

This variable after some point is modified to this

    buffer [40] = '\0';

What does this assignment does to the variable? Does it initialize the first 40 char in the array to null?

What happens when a char array is initialized to '\0'?
===

I have a char array of size 512 i.e

    char buffer [512];

This variable after some point is modified to this

    buffer [40] = '\0';

What does this assignment does to the variable? Does it initialize the first 40 char in the array to null?
