0

@jakeseo_me

대전에 있는 (주) 아이와즈라는 회사에서 풀스택 웹개발자로 일하고 있는 서진규입니다. JS는 제 이니셜이기도 하며 가장 관심이 많은 분야입니다.

2019년 3월 12일

SERIES

15/18

- it's a type of datastructure
- it has Node and Vertex(정점), Edge(간선)
- Vertex and Node mean same thing. Circled ones in the image.
- Edge means lines connecting circles.
- This represents the relationship between vertices.

- G = (V, E)
- for example) on facebook
- friends are vertices
- relationships are edges

- it has 5 Vertices and 7 Edges
- Path from A to B
- A->C->D->E->B
- A->B
- A->C->B
- A->C->E->B

- This refers to a case where the origin and destination are the same.
- A to A
- B to B

- Cycle about A to A
- A->C->B->A
- A->C->E->B->A
- A->C->D->E->B->A

- we usually need some shortest path
- express conditions as a graph and solve it

- Graph which is not visiting the same vertex more than once in a path or cycle
- When nothing is mentioned, the commonly used path or cycle is this case.

- if there is arrow at the end of the edges
- in case of graph above
- A->C is possible
- but C->A is impossible

- there is no arrow at the end of the edges
- it is also called Bidirected Graph
- when it comes to code, write about two edges

- there can be multiple edges between two vertices
- if there are two edges which has different weight
- smaller weight one would be win and bigger weight one would be ignored

- it also can be possible that one edge's start point and end point are the same.
- A -> A

- when there is weight, it is a really important thing.
- it is about how much it will cost or take...
- if there is no weight, we can think that all weights get value of 1

- Degree means edges of each vertice
- if a has 3 edges, a's degree is also 3
- in case of directed graph
- it is divided into indegree and outdegree

로그인 후 댓글을 작성 할 수 있습니다.

2019년 3월 14일

Search of Graph - There are two kinds of way to search graph - DFS and BFS - DFS - Depth First Search Algorithm - Search graph as deeply and many as it can - It ...

2019년 3월 12일

Representation of Graph Graph_Expression1.png - in case of this graph, it has 6 vertices and 8 edges - it doesn't have direction so it is undirected graph - vertices : {1, 2, 3, 4, 5, 6} - edges : {(1...

2019년 3월 12일

Graph ImageOfGraph.png - it's a type of datastructure - it has Node and Vertex(정점), Edge(간선) - Vertex and Node mean same thing. Circled ones in the image. - Edge means lines connecting circles. ...

2019년 3월 9일

Card - boj/11652 - Junkyu has cards which contain a number between -2^62 and 2^62 - Which kind of card does Junkyu have the most? - It can be solved after sorted - After sorting cards, it can be solve...

2019년 3월 8일

Sort - there are a lot of sort algorithms - selection, bubble, insertion, quick, heap and merge sort ... - use sort algorithm which has time complexity of O(NlgN) - it's better to use sort in STL than...