What are the best practices for structuring PHP functions to ensure reusability and readability in code?

To ensure reusability and readability in PHP code, it is important to follow best practices when structuring functions. This includes using clear and descriptive function names, keeping functions concise and focused on a single task, using parameters to make functions more flexible, and avoiding global variables within functions.

// Example of a well-structured PHP function
function calculateSum($num1, $num2) {
    return $num1 + $num2;
}