src/Helpers/Request/Inflector.php
public function sentence(array $words, $twoWordsConnector = null, $lastWordConnector = null, $connector = ', ')
    {
        return $this->proxy(__FUNCTION__, [$words, $twoWordsConnector, $lastWordConnector, $connector]);
    }
public function sentence(array $words, $twoWordsConnector = null, $lastWordConnector = null, $connector = ', ')
    {
        return $this->proxy(__FUNCTION__, [$words, $twoWordsConnector, $lastWordConnector, $connector]);
    }
Converts a list of words into a sentence.

Special treatment is done for the last few words. For example,

```php
$words = ['Spain', 'France'];
echo Inflector::sentence($words);
// output: Spain and France

$words = ['Spain', 'France', 'Italy'];
echo Inflector::sentence($words);
// output: Spain, France and Italy

$words = ['Spain', 'France', 'Italy'];
echo Inflector::sentence($words, ' & ');
// output: Spain, France & Italy
```

@param array $words the words to be converted into an string
@param string $twoWordsConnector the string connecting words when there are only two
@param string $lastWordConnector the string connecting the last two words. If this is null, it will
take the value of `$twoWordsConnector`.
@param string $connector the string connecting words other than those connected by
$lastWordConnector and $twoWordsConnector
@return string the generated sentence
@see \Reaction\Helpers\Inflector::sentence()