Notice
Recent Posts
Recent Comments
Link
일 | 월 | 화 | 수 | 목 | 금 | 토 |
---|---|---|---|---|---|---|
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 |
Tags
- 공부
- web
- memory
- js to ts
- 스프링
- 기초100제
- 자료구조
- CPU 스케줄링
- Operating System
- 백준
- 정렬
- 토이프로젝트
- 코드업
- react
- 프로그래머스
- OS
- C++
- 파이썬
- 알고리즘
- Java
- react-redux
- codeup
- 타입스크립트
- 일상
- Redux
- 분할메모리할당
- error
- Spring
- 협업
- 리덕스장바구니
Archives
- Today
- Total
목록insertionSort (1)
감자튀김 공장🍟
[python] 삽입 정렬(Insertion sort)
내용 정리 ➡ https://good-potato.tistory.com/38 [C++] 삽입 정렬(Insertion Sort) 삽입 정렬 정렬되어 있는 리스트에 새로운 레코드를 적절한 위치에 삽입하는 과정을 반복한다. 정렬되어 있지 않은 부분의 첫 번째 숫자가 정렬된 부분의 어느 위치에 삽입되어야 하는가를 판 good-potato.tistory.com 코드 정리 #삽입 정렬 def insertion(arr): n = len(arr) for i in range(1, n): j = i temp = arr[i] while j > 0 and arr[j-1] > temp: arr[j] = arr[j - 1] j -= 1 arr[j] = temp
Algorithm/정렬
2022. 3. 21. 14:47