very simple JS solution but not efficient
\n\n/**\n * @param {number} n\n * @return {number[][]}\n */\nvar findPrimePairs = function (n) {\n    if (n <= 2) return []\n    const res = []\n    let i, j\n 
\n```\n/**\n * @param {number} n\n * @return {number[][]}\n */\nvar findPrimePairs = function (n) {\n    if (n <= 2) return []\n    const res = []\n    let i, j\n    if (n % 2 == 0) {\n        i = n / 2\n        j = n / 2\n    } else {\n        i = Math.floor(n / 2)\n        j = Math.ceil(n / 2)\n    }\n\n    for (i, j; i >= 0, j <= n; i--, j++) {\n        if (isPrime(i) && isPrime(j)) res.push([i, j])\n    }\n\n    return res.sort((a, b) => a[0] - b[0])\n};\n\nfunction isPrime(number) {\n    if (number < 2) return false;\n\n    for (let i = 2; i <= Math.sqrt(number); i++) {\n        if (number % i === 0) {\n            return false;\n        }\n    }\n\n    return true;\n}\n```
['JavaScript']