| 일 | 월 | 화 | 수 | 목 | 금 | 토 |
|---|---|---|---|---|---|---|
| 1 | 2 | 3 | 4 | 5 | 6 | 7 |
| 8 | 9 | 10 | 11 | 12 | 13 | 14 |
| 15 | 16 | 17 | 18 | 19 | 20 | 21 |
| 22 | 23 | 24 | 25 | 26 | 27 | 28 |
Tags
- Regular Expression
- concurrency
- Protocol
- 밴픽
- LeetCode
- 시바견
- Python
- attribute
- 파이썬
- 30. Substring with Concatenation of All Words
- Python Code
- Generator
- 프로그래머스
- iterator
- 315. Count of Smaller Numbers After Self
- Convert Sorted List to Binary Search Tree
- 43. Multiply Strings
- 컴퓨터의 구조
- data science
- 715. Range Module
- t1
- Decorator
- DWG
- kaggle
- 운영체제
- shiba
- 109. Convert Sorted List to Binary Search Tree
- Substring with Concatenation of All Words
- Class
- Python Implementation
Archives
- Today
- Total
목록permutations (1)
Scribbling
LeetCode: 46. Permutations
DFS Solution. from itertools import permutations class Solution: def permute(self, nums: List[int]) -> List[List[int]]: # Using Library # return list(permutations(nums, len(nums))) ret = [] self.helper(nums, [], ret) return ret def helper(self, nums, element, ret): if not nums: ret.append(element) for i, num in enumerate(nums): self.helper(nums[:i]+nums[i+1:], element+[num], ret) A lazy solution..
Computer Science/Coding Test
2021. 9. 7. 21:30