string \x00 value at the end | C++

I am facing issue as per below screenshot. Any CPP developer can help me ? i don't know why its adding \x00 in end !
diff is nothing but wrong ans.
image

Comments (1)