Haskell (FP101.x) – Chapter 2

edx 의 FP101.x (Introduction to Functional Programming) 수업 중 2 번째 챕터입니다.   이번시간엔 list comprehension 을 배웁니다. 수학에서는 집합의 원소를 이용해 새로운 집합을 만들 때 사용하는데요, In mathematics, the comprehension notion can be used to construct new sets from old sets. 비슷하게 하스켈에선 컬렉션에다 사용 할 수 있죠. In Haskell, a similar comprehension notion can … Continue reading Haskell (FP101.x) – Chapter 2

Haskell (FP101.x) – Chapter 1

edx 의 FP101.x (Introduction to Functional Programming) 수업 중 1 번째 챕터입니다. 먼저 이 글은 edx 의 FP101.x (Introduction to Functional Programming) 수업을 기반으로 작성되었음을 알려드립니다. 시작에 앞서서, 하스켈을 설치하려면 Haskell Platform 을 설치하신 후 터미널에서 ghci 를 입력하면 됩니다. 하스켈 플랫폼은 하스켈 구현체로 Glasgow Haskell Compiler, GHC 를 포함하고 있습니다. ghci 를 입력하면 하스켈 인터프리터를 … Continue reading Haskell (FP101.x) – Chapter 1

Algorithm Design & Analysis 6 – Hash Table, Universal Hashing, Bloom filters

Coursera 에서 제공하는 Stanford 대학교의 Algorithm Design & Analysis 수업 중 6 번째 챕터입니다. Hash Table 해시 테이블의 연산은 key 를 이용해 이런 작업들을 한다. (1) insert: add new record (2) delete: delete existing record (2) lookup: check for a particular record 가끔 사람들이 dictionary 라 부르기도 하는데, 해시테이블은 알파벳 순서같은 특정 order 로 데이터를 … Continue reading Algorithm Design & Analysis 6 – Hash Table, Universal Hashing, Bloom filters

Algorithm Design & Analysis 5 – Dijkstra, Heap, Red-Black Tree

Coursera 에서 제공하는 Stanford 대학교의 Algorithm Design & Analysis 수업 중 5 번째 챕터입니다. Dijkstra’s Shortest-Path Algorithm BFS 는 undirected graph 에서 최단 경로를 찾지만, 이건 모든 edge 의 길이가 1일때만 그렇다. 다익스트라(dijkstra, 데이크스트라) 알고리즘은 directed graph 에서 non-negative length 에 대한 최단 경로를 찾아낼 수 있다. 각 edge 가 음수라면, 모든 수에 특정 수를 … Continue reading Algorithm Design & Analysis 5 – Dijkstra, Heap, Red-Black Tree

Algorithm Design & Analysis 4 – Graph Search and Connectivity

Coursera 에서 제공하는 Stanford 대학교의 Algorithm Design & Analysis 수업 중 4 번째 챕터입니다. 기본적인 그래프 탐색 방법 DFS, BFS 에 대해 배우고 약간씩 응용하여 shortest path, conncected components, topological order, strongly connected components 등을 찾는 방법을 배운다. 마지막 부분에선 웹이 어떻게 생겼을까 잠깐 고민해 본다. Graph Search 그래프 탐색은 다양하게 활용할 수 있다. (1) … Continue reading Algorithm Design & Analysis 4 – Graph Search and Connectivity