$words1 = file('firstword.txt');
$words1MaxIndex = count($words1) - 1;
$words2 = file('secondword.txt');
$words2MaxIndex = count($words2) - 1;
$randomPhrase = $words1[mt_rand(0, $words1MaxIndex)] . ' ' . $words2[mt_rand(0, $words2MaxIndex)];
$n = rand(0, count($result_array) - 1)