init
npm init
global package 설치 디렉토리 확인
npm root -g
def solution(t, p):
num_list = [t[num: num + len(p)] for num in range(len(t) - len(p) + 1)]
return len([num for num in num_list if int …
from datetime import datetime
from dateutil.relativedelta import relativedelta
# 2년 반 후
two_and_half_later = datetime.strptime("2023.01.01", "%Y.%m.%d") + relativedelta(years=2, months=6, days=-1)
print(two_and_half_later)
# => 2025-06-30 00:00:00
from datetime import datetime
str = "2023.10.08"
format = "%Y.%m.%d"
dt = datetime.strptime(str, format)
print(dt)
# => 2023-10-08 00:00:00
ascii_lowercase
사용ascii_uppercase
사용from string import ascii_lowercase
from string import ascii_uppercase
# 소문자 알파뱃 리스트
# => ['a', 'b', 'c', 'd', 'e', 'f', 'g', 'h', 'i', 'j', 'k …
값이 true인 프로퍼티는 값의 변경여부를 체크하도록 함
interface Props {
treeItem: Tree;
sameDepthTreeNames: Map<TreeType, string[]>;
setRootTree: Dispatch<SetStateAction<Tree>>
setMethodType: Dispatch<SetStateAction<MethodTypeForRecursivTreeItem>>
setMethodTargetTree: Dispatch<SetStateAction …
def solution(cards1, cards2, goal):
answer = ''
for target in goal:
if len(cards1) > 0 and target == cards1[0]:
cards1.pop(0)
elif …