Echo and Print are both language constructs used to output data to the screen.

The difference between echo and print is that echo has no return value while print has a return value of 1 which can be used in expressions.

Example:

echo “Hello World”;

print “Hello World”;

Leave a Reply

Your email address will not be published. Required fields are marked *