sji

  • 홈
  • 태그
  • 방명록

Graph 2

133. Clone Graph

leetcode.com/problems/clone-graph/ Clone Graph - LeetCode Level up your coding skills and quickly land a job. This is the best place to expand your knowledge and get prepared for your next interview. leetcode.com 그래프를 클론하는 문제다. dfs로 접근했다. top to bottom으로 뻗어나갔다가 바텀 찍고 돌아오면서 자식 노드를 생성과 동시에 리턴하면서 부모로 모으는 식으로 하려 했는데 중복 체크에 있어서 애매한 부분이 있어 top to bottom으로 나가되 노드를 미리 생성하고 빈 껍데기라도 미리 리스팅 해서 부모에 추가하는 식으로..

algorithm 2020.11.01

785. Is Graph Bipartite?

leetcode.com/problems/is-graph-bipartite/ Is Graph Bipartite? - LeetCode Level up your coding skills and quickly land a job. This is the best place to expand your knowledge and get prepared for your next interview. leetcode.com 주어진 그래프가 bipartite(이분 그래프)인지 판단하는 문제다. 큐를 이용해서 dfs를 구현하였다. 168 ms, faster than 81.64% from collections import deque class Solution: def isBipartite(self, graph: List[List..

algorithm 2020.11.01
1
더보기
  • 분류 전체보기 (87)
    • intro. (0)
    • DL&ML (38)
      • concept (19)
      • papers (9)
      • code.data.tips (10)
    • http&server (7)
    • dist. system (6)
    • docker (5)
    • algorithm (24)
    • design pattern (1)
    • architecture (1)
    • trouble shooting (3)
    • better way (1)
    • problems (0)

Tag

Graph, Likelihood, Docker, gunicorn, string, dp, CrossEntropy, queue, gaussian mixture, Dynamic Programming, seq2seq, React Native, flask, nginx, tree, summarization, MLE, docker-compose, stack, Zookeeper,

최근글과 인기글

  • 최근글
  • 인기글
250x250

Calendar

«   2025/07   »
일 월 화 수 목 금 토
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

방문자수Total

  • Today :
  • Yesterday :

Designed by Tistory.

티스토리툴바