문제 링크 https://school.programmers.co.kr/learn/courses/30/lessons/60057 프로그래머스 코드 중심의 개발자 채용. 스택 기반의 포지션 매칭. 프로그래머스의 개발자 맞춤형 프로필을 등록하고, 나와 기술 궁합이 잘 맞는 기업들을 매칭 받으세요. programmers.co.kr 문제 설명 이 쯤 되니 카카오의 문자열 사랑이 지독하게 느껴진다. 문자열 반복을 확인해서 가장 짧은 길이를 찾으면 된다. 문제 풀이 문자열 길어봐야 1000이고 달리 방법도 없으니 브루트포스를 이용한다. 코드 #include #include #include using namespace std; int solution(string s) { int len = s.length(); int a..
문제 링크 https://school.programmers.co.kr/learn/courses/30/lessons/42890 프로그래머스 코드 중심의 개발자 채용. 스택 기반의 포지션 매칭. 프로그래머스의 개발자 맞춤형 프로필을 등록하고, 나와 기술 궁합이 잘 맞는 기업들을 매칭 받으세요. programmers.co.kr 문제 설명 16.09%의 정답률을 가졌다. 세번 째 문제던데 보통 여기서 무너졌을 듯 (아마 나도) 데이터베이스 수업을 들었다면 이해가 좀 빠를 것 같은데, 청년 치매를 앓고있는 나에겐 너무나 새로웠다... 후보키를 캐주얼하게 설명하면 속성 차집합 중 튜플들을 유일하게 식별할 수 있으면서 필요없는 속성은 들어가있지 않은 것을 의미한다. 처음 접하는 사람이라면 유일성은 이해가 쉽지만 최소..
문제 링크 https://school.programmers.co.kr/learn/courses/30/lessons/42888 프로그래머스 코드 중심의 개발자 채용. 스택 기반의 포지션 매칭. 프로그래머스의 개발자 맞춤형 프로필을 등록하고, 나와 기술 궁합이 잘 맞는 기업들을 매칭 받으세요. programmers.co.kr 문제 설명 문제가 길어서 겁먹을 수 있지만(내가 겁먹음) 실패율보다 쉬운 문제이다. 코딩테스트 당시 정답률은 실패율(55.57%)보다 약간 높은 59.91%이라고 한다. 주어진 string을 명령문으로 생각하면 첫번째 단어로 동작을 분기해서 각 동작을 처리해주면 된다. 문제 풀이 변하지 않는 아이디라고하면 생각나야하는게 있다. map이다. 닉네임을 골백번 바꿔도 아이디는 변하지 않으므로..
문제 링크 https://school.programmers.co.kr/learn/courses/30/lessons/42889 프로그래머스 코드 중심의 개발자 채용. 스택 기반의 포지션 매칭. 프로그래머스의 개발자 맞춤형 프로필을 등록하고, 나와 기술 궁합이 잘 맞는 기업들을 매칭 받으세요. programmers.co.kr 문제 설명 나머지 문제 중에서 가장 쉬운 문제로, 실제 코딩테스트가 이루어졌을 때의 정답률은 55.57%이다. 주어진 N개의 스테이지에 대해 실패율을 구하고 실패율에 따라 내림차순으로 정렬한 배열을 리턴하는 문제이다. 문제 설명이 모호하지만, 예시를 보면 스테이지 n의 실패율은 stages 중 n의 갯수 / stages 중 n 이상인 것의 갯수 이다. 문제 풀이 문제는 총 4단계 페이즈..
Problem https://leetcode.com/problems/maximum-depth-of-binary-tree/ Maximum Depth of Binary Tree - LeetCode Can you solve this real interview question? Maximum Depth of Binary Tree - Given the root of a binary tree, return its maximum depth. A binary tree's maximum depth is the number of nodes along the longest path from the root node down to the farthest leaf leetcode.com Hint Try using recursi..
Problem https://leetcode.com/problems/longest-repeating-character-replacement/ Longest Repeating Character Replacement - LeetCode Can you solve this real interview question? Longest Repeating Character Replacement - You are given a string s and an integer k. You can choose any character of the string and change it to any other uppercase English character. You can perform this operati leetcode.co..
Problem https://leetcode.com/problems/insert-interval/ Insert Interval - LeetCode Can you solve this real interview question? Insert Interval - You are given an array of non-overlapping intervals intervals where intervals[i] = [starti, endi] represent the start and the end of the ith interval and intervals is sorted in ascending order b leetcode.com Hint Solution Code Simple class Solution { pub..
Problem https://leetcode.com/problems/longest-substring-without-repeating-characters/
내 블로그 - 관리자 홈 전환 |
Q
Q
|
---|---|
새 글 쓰기 |
W
W
|
글 수정 (권한 있는 경우) |
E
E
|
---|---|
댓글 영역으로 이동 |
C
C
|
이 페이지의 URL 복사 |
S
S
|
---|---|
맨 위로 이동 |
T
T
|
티스토리 홈 이동 |
H
H
|
단축키 안내 |
Shift + /
⇧ + /
|
* 단축키는 한글/영문 대소문자로 이용 가능하며, 티스토리 기본 도메인에서만 동작합니다.