Golang 3 ms 5.1 MB
Complexity\n- Time complexity: O(n)\n- Space complexity: O(n)\n# Code\n\nfunc separateDigits(nums []int) []int {\n\tvar result []int\n\tvar digits [6]int\n\tfor
# Complexity\n- Time complexity: $$O(n)$$\n- Space complexity: $$O(n)$$\n# Code\n```\nfunc separateDigits(nums []int) []int {\n\tvar result []int\n\tvar digits [6]int\n\tfor _, num := range nums {\n\t\ti := 5\n\t\tfor ; num != 0; i, num = i-1, num/10 {\n\t\t\tdigits[i] = num % 10\n\t\t}\n\t\tresult = append(result, digits[i+1:]...)\n\t}\n\treturn result\n}\n```
['Go']