The value of PI is: 3.14159
The greeting message is: Hello, world!
Constants in PHP are identifiers (names) for values that cannot be changed during the execution of the script. Unlike variables, their values remain constant throughout the script's execution.
Variables, on the other hand, can vary; their values can be assigned and reassigned throughout the script's execution.
Constants are useful for defining values that are used repeatedly and should not be changed, such as mathematical constants, configuration settings, or messages.