This is one of the standard interview questions but I have never got a straight answer from an prospective applicant.
There are three main differences.
Difference 1:
echo return a void, while print returns a ‘1’. Always.
Difference 2:
echo can have multiple arguments while print cannot. So, echo ‘abcd’, ‘defg’; will work. It will output ‘abcdefgh’.
Difference 3:
echo cannot be used like a function but print can even though both are language constructs. So, this will work echo strlen(print(‘abcd’)); but this won’t echo strlen(echo(‘abcd’)); You will get a parse error.
Hope in your next interview this helps you!