diff --git "a/Retos/Reto #21 - N\303\232MEROS PRIMOS GEMELOS [Media]/php/kodenook.php" "b/Retos/Reto #21 - N\303\232MEROS PRIMOS GEMELOS [Media]/php/kodenook.php" new file mode 100644 index 0000000000..efcee95f7f --- /dev/null +++ "b/Retos/Reto #21 - N\303\232MEROS PRIMOS GEMELOS [Media]/php/kodenook.php" @@ -0,0 +1,64 @@ += count($numbers)) { + continue; + } + + if ($numbers[$i + 1] - $numbers[$i] === 2) { + $response .= '(' . $numbers[$i] . ',' . $numbers[$i + 1] . ') '; + } + } + + return $response; +} + +echo primeTwins(14) . PHP_EOL; +echo primeTwins(7) . PHP_EOL; +echo primeTwins(2) . PHP_EOL;