PHP Interview Questions
How is typecasting achieved in PHP?
The name of the output type needs to be specified in parentheses before the variable that is to be cast. Some examples are :
 
* (array) – casts to array
* (bool), (boolean) – casts to Boolean
* (double), (float), (real) – casts to float
* (int), (integer) – casts to integer
* (object) – casts to object
* (string) – casts to string