In char s = "Hello\0Hi";
s has an embeded '\0' char, the strlen(s) will stop counting as soon as it come across first null terminator hence it reports length as 5
sizeof function/operator does not evaluates it arguments it just counts number of bytes allocated/used, so it counts the full size of the array.
Note \0 is counted as 1 char and there is a hidden '\0' at the end, so the size is 9
Also note that the correct format specifier for both functions should be "%ld" as both returns unsigned long int value.