[JavaScript] - easy solution
Complexity\n- Time complexity: O(1)\n- Space complexity: O(1)\n\n# Code\n\n/**\n * @param {number[]} nums\n * @return {string}\n */\nvar triangleType = function
# Complexity\n- Time complexity: $$O(1)$$\n- Space complexity: $$O(1)$$\n\n# Code\n```\n/**\n * @param {number[]} nums\n * @return {string}\n */\nvar triangleType = function(nums) {\n    nums.sort((a, b) => a - b);\n    if (nums[0] + nums[1] <= nums[2]) {\n        return \'none\';\n    }\n    if (nums[0] === nums[1] && nums[1] === nums[2]) {\n        return \'equilateral\';\n    }\n    if (nums[0] === nums[1] || nums[1] === nums[2]) {\n        return \'isosceles\';\n    }\n    return \'scalene\';\n};\n```
['JavaScript']