목록LeetCode (7)
어흥
문제 링크: https://leetcode.com/problems/construct-binary-tree-from-preorder-and-inorder-traversal/description/?envType=study-plan-v2&envId=top-100-liked LeetCode - The World's Leading Online Programming Learning Platform 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 1. 주의할 점 - 재귀문으로 접근하며, re..
문제 링크: https://leetcode.com/problems/find-the-duplicate-number/description/?envType=study-plan-v2&envId=top-100-liked Find the Duplicate Number - LeetCode Can you solve this real interview question? Find the Duplicate Number - Given an array of integers nums containing n + 1 integers where each integer is in the range [1, n] inclusive. There is only one repeated number in nums, return this repea..
문제 링크: https://leetcode.com/problems/max-number-of-k-sum-pairs/description/?envType=study-plan-v2&envId=leetcode-75 Max Number of K-Sum Pairs - LeetCode Can you solve this real interview question? Max Number of K-Sum Pairs - You are given an integer array nums and an integer k. In one operation, you can pick two numbers from the array whose sum equals k and remove them from the array. Return the..
문제 링크: https://leetcode.com/problems/string-to-integer-atoi/description/?envType=list&envId=rdlarbki String to Integer (atoi) - LeetCode Can you solve this real interview question? String to Integer (atoi) - Implement the myAtoi(string s) function, which converts a string to a 32-bit signed integer (similar to C/C++'s atoi function). The algorithm for myAtoi(string s) is as follows: 1. Read leet..
문제 링크: https://leetcode.com/problems/product-of-array-except-self/description/?envType=list&envId=rdlarbki Product of Array Except Self - LeetCode Can you solve this real interview question? Product of Array Except Self - Given an integer array nums, return an array answer such that answer[i] is equal to the product of all the elements of nums except nums[i]. The product of any prefix or suffix ..
문제 링크: https://leetcode.com/problems/lru-cache/description/ LRU Cache - LeetCode Can you solve this real interview question? LRU Cache - Design a data structure that follows the constraints of a Least Recently Used (LRU) cache [https://en.wikipedia.org/wiki/Cache_replacement_policies#LRU]. Implement the LRUCache class: * LRUCache(int c leetcode.com 1. 주의할 점 - DoubleLinkedList와 HashMap을 사용 및 구현 할..
문제 링크: https://leetcode.com/problems/next-permutation/description/ Next Permutation - LeetCode Can you solve this real interview question? Next Permutation - A permutation of an array of integers is an arrangement of its members into a sequence or linear order. * For example, for arr = [1,2,3], the following are all the permutations of arr: [1,2,3], leetcode.com 1. 순열의 순서는 어떻게 정해질까?에 대한 의문을 직접 구..