What is the correct syntax for accessing nested values in an array in PHP?

When accessing nested values in an array in PHP, you need to use multiple square brackets to navigate through the nested levels. Each pair of square brackets represents accessing a level deeper in the array structure. For example, if you have an array $arr that contains another array as one of its elements, you can access a value in the nested array by chaining square brackets.

// Example array with nested values
$arr = array(
    'key1' => 'value1',
    'key2' => array(
        'nested_key' => 'nested_value'
    )
);

// Accessing the nested value
$nestedValue = $arr['key2']['nested_key'];
echo $nestedValue; // Output: nested_value