일 | 월 | 화 | 수 | 목 | 금 | 토 |
---|---|---|---|---|---|---|
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 | 29 |
30 | 31 |
Tags
- t1
- Python Implementation
- 109. Convert Sorted List to Binary Search Tree
- Regular Expression
- kaggle
- Generator
- Class
- shiba
- Substring with Concatenation of All Words
- data science
- 315. Count of Smaller Numbers After Self
- 시바견
- Convert Sorted List to Binary Search Tree
- LeetCode
- 밴픽
- 715. Range Module
- 프로그래머스
- 30. Substring with Concatenation of All Words
- DWG
- attribute
- Decorator
- concurrency
- Python Code
- Python
- Protocol
- 운영체제
- 43. Multiply Strings
- 파이썬
- iterator
- 컴퓨터의 구조
Archives
- Today
- Total
목록1610. Maximum Number of Visible Points (1)
Scribbling
LeetCode: 1610. Maximum Number of Visible Points
class Solution: def visiblePoints(self, points: List[List[int]], angle: int, location: List[int]) -> int: from math import atan2, pi from bisect import bisect_right numLoc = 0 angles = [] for point in points: x, y = point[0] - location[0], point[1] - location[1] if x == 0 and y == 0: numLoc += 1 else: val = atan2(y, x) * 180 / pi if val < 0: val += 360 angles.append(val) angles.sort() angles += ..
Computer Science/Coding Test
2022. 3. 7. 14:29