When should `const` be used within a function?

Playpen link

It appears that both arrays are stored in the executable, but foo copies it onto the stack before using it.