Yup, people often miss that PHP is modal and that the default mode is simply to output. So if you put Hello World in a file it actually compiles to these opcodes:
ECHO 'Hello+World%0A'
RETURN 1
Which is identical to the opcodes produced by putting <?php
echo "Hello World"; ?> into a file.