Home

[백준] 행운의 바퀴

문제 class Node(): def __init__(self, value, next_node = None, prev_node = None): self.value = value self.next_node = next_node self.prev_node = prev_node n, k = map(int, input().split()) head = Node('?') tail = Node('?') head.next_node = tail tail.prev_node = head cur = head for _ in range(1, n - 1): new = Node('...

Read more

[DL Basic] 인공지능, 머신러닝, 딥러닝

인공 지능, 머신 러닝, 딥러닝 인공지능이란 간단하게 인공지능과 머신 러닝, 딥러닝을 각각 정리해보면, 인공지능은 인간의 지능을 모방하여 사람이 하는 일을 컴퓨터가 할 수 있게 하는 기술이다. 이 인공 지능의 방법으로 머신 러닝과 딥러닝이 있는 것이다. 관계를 정리해보면 인공 지능 안에 머신 러닝이 있고, 머신 러닝 안에 딥러닝이 포함되는 관계이다.→ 인공지능 > 머신러닝 > 딥러닝 여기서 머신러닝과 딥러닝 모두 학습 모델을 제공하여 데이터를 분류하는 기술이다. 이 둘은 특징 추출을 사람이 하느냐 모델이 스스로 하느냐의 차이가 있다. 특징 추출이란 데...

Read more

[프로그래머스] 파일명 정렬

문제 def solution(files): answer = [] for f in files: head, number, tail = '', '', '' number_check = False for i in range(len(f)): if f[i].isdigit(): number += f[i] number_check = True elif not number_check: head += f[i] else: ...

Read more

[프로그래머스] 오픈채팅방

문제 def solution(record): answer = [] dic = {} for i in record: p = i.split(' ') if p[0] == 'Enter' or p[0] == 'Change': dic[p[1]] = p[2] for i in record: p = i.split(' ') if p[0] == 'Enter': answer.append('{}님이 들어왔습니다.'.format(dic[p[1]])) elif p[0] == 'Leave': ...

Read more

[프로그래머스] 뉴스 클러스터링

문제 from collections import Counter def intersection(ls1, ls2): if not ls1 and not ls2: return 1 cnt1 = Counter(ls1) cnt2 = Counter(ls2) inter = cnt1 & cnt2 return sum(inter.values()) def union(ls1, ls2): if not ls1 and not ls2: return 1 cnt1 = Counter(ls1) cnt2 = Counter(ls2) inter = cnt1...

Read more