Exam Answer

JPDev@programming.dev to Programmer Humor@programming.dev – 781 points –
128

You are viewing a single comment

Good thing this only uses ASCii characters, else you get into some fun discussions about UTF encoding

But does it count the null byte or not?

In most languages, length method doesn't count the null terminator. Might result in some fun memory errors