937 | JavaScript 1-line solution
\uD83C\uDD95 Now updated for the new additional tests. \uD83C\uDF89\n\uD83C\uDD95 Now updated with just one sort. \uD83C\uDF89\n\n> Runtime: 115 ms, faster than
\uD83C\uDD95 Now updated for the new additional tests. \uD83C\uDF89\n\uD83C\uDD95 Now updated with just one sort. \uD83C\uDF89\n\n> Runtime: **115 ms**, faster than *32.97%* of JavaScript online submissions\n> Memory Usage: **48 MB**, less than *19.97%* of JavaScript online submissions\n\n```javascript\n/**\n * @param {string[]} logs\n * @return {string[]}\n */\nconst reorderLogFiles = logs =>\n  logs.sort((a, b) =>\n    /^\\S+[\\d\\s]+$/.test(a) ? 1 :\n      /^\\S+[\\d\\s]+$/.test(b) ? -1 :\n        a.replace(/\\S+\\s(.+)/, \'$1\').localeCompare(\n          b.replace(/\\S+\\s(.+)/, \'$1\')) || a.localeCompare(b)\n  );\n```
['JavaScript']