My program is as follows;
#include #include int main() { char string[] = \"Gentlemen start your engines!\";
Using incorrect format specifier in printf() invokes Undefined Behaviour. Correct format specifier should be %zu (not %d) because the return type of strlen() is size_t
printf()
%zu
%d
strlen()
size_t
Note: Length modifier z in %zu represents an integer of length same as size_t
z