본문 바로가기
반응형

🖥️ 문제 풀이/리트코드(Leetcode)62

[LeetCode 해석 및 풀이] 213. House Robber II(집도둑 2) LeetCode 문제 해석 및 풀이 방법문제 213. House Robber II(집도둑 2)난이도 : 중간🟡 바로가기 문제 설 명영문You are a professional robber planning to rob houses along a street. Each house has a certain amount of money stashed. All houses at this place are arranged in a circle. That means the first house is the neighbor of the last one. Meanwhile, adjacent houses have a security system connected, and it will automatically conta.. 2024. 9. 19.
[LeetCode 해석 및 풀이] 198. House Robber(집도둑) LeetCode 문제 해석 및 풀이 방법문제 198. House Robber(집도둑)난이도 : 중간🟡 바로가기 문제 설명영문You are a professional robber planning to rob houses along a street. Each house has a certain amount of money stashed, the only constraint stopping you from robbing each of them is that adjacent houses have security systems connected and it will automatically contact the police if two adjacent houses were broken into on the sa.. 2024. 9. 17.
[LeetCode 해석 및 풀이] 746. Min Cost Climbing Stairs(최소 비용 계단 오르기) LeetCode 문제 해석 및 풀이 방법문제 746. Min Cost Climbing Stairs(최소 비용 계단 오르기)난이도 : 쉬움🟢 바로가기 문제 설명영문You are given an integer array cost where cost[i] is the cost of ith step on a staircase. Once you pay the cost, you can either climb one or two steps. You can either start from the step with index 0, or the step with index 1. Return the minimum cost to reach the top of the floor. 한글 cost[i]가 계단의 i th 단계에서.. 2024. 9. 17.
[LeetCode 해석 및 풀이] 70. Climbing Stairs(계단 오르기) LeetCode 문제 해석 및 풀이 방법문제 70. Climbing Stairs(계단 오르기)난이도 : 쉬움🟢 바로가기 문제 설명영문You are climbing a staircase. It takes n steps to reach the top. Each time you can either climb 1 or 2 steps. In how many distinct ways can you climb to the top? 한글당신은 계단을 오르고 있습니다. 꼭대기에 도달하려면 n단계가 필요합니다. 매번 1단계 또는 2단계를 오를 수 있습니다. 정상까지 올라갈 수 있는 방법은 몇 가지입니까? 제한조건1  입출력 예입력출력n = 22n = 33 해답 및 해설파이썬 (Python)class Solution: .. 2024. 9. 17.
[LeetCode 해석 및 풀이] 17. Letter Combinations of a Phone Number(전화번호의 문자 조합) LeetCode 문제 해석 및 풀이 방법문제 17. Letter Combinations of a Phone Number(전화번호의 문자 조합)난이도 : 중간🟡 바로가기 문제 설명영문Given a string containing digits from 2-9 inclusive, return all possible letter combinations that the number could represent. Return the answer in any order. A mapping of digits to letters (just like on the telephone buttons) is given below. Note that 1 does not map to any letters.  한글2-9 까지의 숫자.. 2024. 9. 17.
[LeetCode 해석 및 풀이] 131. Palindrome Partitioning(회문 분할) 문제 131. Palindrome Partitioning(회문 분할)난이도 : 중간🟡 바로가기 문제 설명영문Given a string s, partition s such that every substring of the partition is a palindrome. Return all possible palindrome partitioning of s. 한글문자열 s가 주어지면, 분할한 s의 모든 분할의 하위 문자열이 회문이 되도록 합니다. s 의 모든 가능한 회문 분할을 반환합니다. 제한조건1 s contains only lowercase English letters. 입출력 예입력출력s = "aab"[["a","a","b"],["aa","b"]]s = "a"[["a"]] 해답 및 해설파이썬 (Py.. 2024. 9. 16.
반응형