일 | 월 | 화 | 수 | 목 | 금 | 토 |
---|---|---|---|---|---|---|
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 |
- 자바스크립트
- JavaScript
- 제로베이스 프론트엔드 스쿨
- Algorithm
- 구조체
- 제로베이스
- 프론트엔드 스쿨
- C++
- 백트래킹
- 메모리 배리어
- 코딩테스트 스터디
- N과 M(2)
- map
- BFS
- 문자열&연산자
- 멀티스레드
- 알고리즘
- 프로그래머스
- socket
- 구현
- Server
- dfs
- 백준
- c#
- MemoryBarrier
- 서버
- React
- 코딩테스트
- leetcode
- 완전탐색
- Today
- Total
목록알고리즘 (19)
Written
백준과 프로그래머스 알고리즘 문제를 풀면 Github 레포지토리에 자동으로 저장되는 기능이 있습니다. 저도 현재 사용중입니다. 모든 문제를 블로그에 올리고있지는 않아서, 혹시 풀이를 보시려면 https://github.com/steeringhead steeringhead - Overview 화이팅. steeringhead has 4 repositories available. Follow their code on GitHub. github.com 레포지토리에 있는 Baekjoon-PS에서 보실 수 있습니다. 최근에도 매일 꾸준히 풀고 있으니 혹시 제 풀이를 보고 궁금한게 있으시면 쪽지 주시면 알려드리겠습니다!

백준에서 알고리즘 문제를 푸는건 오랜만입니다. 뭐니뭐니해도 역시 알고리즘 문제풀이 할 때가 가장 재미있는 것 같습니다.. https://www.acmicpc.net/problem/2231 2231번: 분해합 어떤 자연수 N이 있을 때, 그 자연수 N의 분해합은 N과 N을 이루는 각 자리수의 합을 의미한다. 어떤 자연수 M의 분해합이 N인 경우, M을 N의 생성자라 한다. 예를 들어, 245의 분해합은 256(=245+2+4+5)이 www.acmicpc.net 어떤 수 N이 주어지면 N을 만드는 또다른 M중 최솟값을 구하는 문제였습니다. 여기서 M은 M과 각 자리수의 합을 더했을 때 N을 만드는, 문제에서 말하는 생성자입니다. 처음에는 특별한 규칙이 있나 생각을 해봤는데 딱히 그런건 없는 느낌이 들어서 시..
https://leetcode.com/problems/sqrtx/ Sqrt(x) - LeetCode Can you solve this real interview question? Sqrt(x) - Given a non-negative integer x, return the square root of x rounded down to the nearest integer. The returned integer should be non-negative as well. You must not use any built-in exponent function or o leetcode.com Example 1: Input: x = 4 Output: 2 Explanation: The square root of 4 is 2..
https://leetcode.com/problems/longest-palindromic-substring/ Longest Palindromic Substring - LeetCode Longest Palindromic Substring - Given a string s, return the longest palindromic substring in s. Example 1: Input: s = "babad" Output: "bab" Explanation: "aba" is also a valid answer. Example 2: Input: s = "cbbd" Output: "bb" Constraints: * 1
https://leetcode.com/problems/remove-element/ Remove Element - LeetCode Remove Element - Given an integer array nums and an integer val, remove all occurrences of val in nums in-place [https://en.wikipedia.org/wiki/In-place_algorithm]. The relative order of the elements may be changed. Since it is impossible to change the leng leetcode.com Given an integer array nums and an integer val, remove a..
https://leetcode.com/problems/remove-duplicates-from-sorted-array/ Remove Duplicates from Sorted Array - LeetCode Remove Duplicates from Sorted Array - Given an integer array nums sorted in non-decreasing order, remove the duplicates in-place [https://en.wikipedia.org/wiki/In-place_algorithm] such that each unique element appears only once. The relative order of the e leetcode.com Given an integ..

https://leetcode.com/problems/merge-two-sorted-lists/ Merge Two Sorted Lists - LeetCode Merge Two Sorted Lists - You are given the heads of two sorted linked lists list1 and list2. Merge the two lists in a one sorted list. The list should be made by splicing together the nodes of the first two lists. Return the head of the merged linked list. leetcode.com You are given the heads of two sorted li..
https://www.acmicpc.net/problem/1655 1655번: 가운데를 말해요 첫째 줄에는 백준이가 외치는 정수의 개수 N이 주어진다. N은 1보다 크거나 같고, 100,000보다 작거나 같은 자연수이다. 그 다음 N줄에 걸쳐서 백준이가 외치는 정수가 차례대로 주어진다. 정수는 -1 www.acmicpc.net 시간초과로 인해 애를 많이 먹었던 문제입니다. 맨 처음에 문제를 보고 떠올린 풀이는 vector에 넣고 sort함수를 사용해서 가운데 수를 출력하는 것이었습니다. 문제의 시간제한이 0.1초이기 때문에 왠지 시간초과가 날 것 같다는 생각이 들었지만 ... 다른 풀이가 딱히 떠오르지 않아 풀이를 제출해보았는데 역시나 시간초과가 났습니다 :D 그래서 밑에 힌트를 확인해보니 , 우선순위 ..