알고리즘

알고리즘/DP

[프로그래머스] 경주로 건설 (BFS, DP) - Java

프로그래머스 코드 중심의 개발자 채용. 스택 기반의 포지션 매칭. 프로그래머스의 개발자 맞춤형 프로필을 등록하고, 나와 기술 궁합이 잘 맞는 기업들을 매칭 받으세요. programmers.co.kr 문제 [카카오 인턴] 경주로 건설 더보기 문제 설명 건설회사의 설계사인 죠르디는 고객사로부터 자동차 경주로 건설에 필요한 견적을 의뢰받았습니다. 제공된 경주로 설계 도면에 따르면 경주로 부지는 N x N 크기의 정사각형 격자 형태이며 각 격자는 1 x 1 크기입니다. 설계 도면에는 각 격자의 칸은 0 또는 1 로 채워져 있으며, 0은 칸이 비어 있음을 1은 해당 칸이 벽으로 채워져 있음을 나타냅니다. 경주로의 출발점은 (0, 0) 칸(좌측 상단)이며, 도착점은 (N-1, N-1) 칸(우측 하단)입니다. 죠르디..

알고리즘/탐색

[LeetCode] 637. Average of Levels in Binary Tree - Java

Average of Levels in Binary Tree - LeetCode Can you solve this real interview question? Average of Levels in Binary Tree - Given the root of a binary tree, return the average value of the nodes on each level in the form of an array. Answers within 10-5 of the actual answer will be accepted. Examp leetcode.com 문제 더보기 Given the root of a binary tree, return the average value of the nodes on each l..

알고리즘/탐색

[LeetCode] 199. Binary Tree Right Side View - Java

Binary Tree Right Side View - LeetCode Can you solve this real interview question? Binary Tree Right Side View - Given the root of a binary tree, imagine yourself standing on the right side of it, return the values of the nodes you can see ordered from top to bottom. Example 1: [https://asse leetcode.com 문제 더보기 Given the root of a binary tree, imagine yourself standing on the right side of it, r..

알고리즘/자료구조

[LeetCode] 230. Kth Smallest Element in a BST - Java

Kth Smallest Element in a BST - LeetCode Can you solve this real interview question? Kth Smallest Element in a BST - Given the root of a binary search tree, and an integer k, return the kth smallest value (1-indexed) of all the values of the nodes in the tree. Example 1: [https://assets.leetco leetcode.com 문제 더보기 Given the root of a binary search tree, and an integer k, return the kth smallest v..

알고리즘/자료구조

[LeetCode] 530. Minimum Absolute Difference in BST - Java

Minimum Absolute Difference in BST - LeetCode Can you solve this real interview question? Minimum Absolute Difference in BST - Given the root of a Binary Search Tree (BST), return the minimum absolute difference between the values of any two different nodes in the tree. Example 1: [https://assets.l leetcode.com 문제 더보기 Given the root of a Binary Search Tree (BST), return the minimum absolute diff..

알고리즘/자료구조

[LeetCode] 242. Valid Anagram - Java

Valid Anagram - LeetCode Can you solve this real interview question? Valid Anagram - Given two strings s and t, return true if t is an anagram of s, and false otherwise. An Anagram is a word or phrase formed by rearranging the letters of a different word or phrase, typically using leetcode.com 문제 더보기 Given two strings s and t, return true if t is an anagram of s, and false otherwise. An Anagram ..

알고리즘/자료구조

[LeetCode] 383. Ransom Note - Java

Ransom Note - LeetCode Can you solve this real interview question? Ransom Note - Given two strings ransomNote and magazine, return true if ransomNote can be constructed by using the letters from magazine and false otherwise. Each letter in magazine can only be used once in ranso leetcode.com 문제 더보기 Given two strings ransomNote and magazine, return true if ransomNote can be constructed by using t..

알고리즘/자료구조

[LeetCode] 219. Contains Duplicate II - Java

Contains Duplicate II - LeetCode Can you solve this real interview question? Contains Duplicate II - Given an integer array nums and an integer k, return true if there are two distinct indices i and j in the array such that nums[i] == nums[j] and abs(i - j)

알고리즘/자료구조

[LeetCode] 1. Two Sum - Java

Two Sum - LeetCode Can you solve this real interview question? Two Sum - Given an array of integers nums and an integer target, return indices of the two numbers such that they add up to target. You may assume that each input would have exactly one solution, and you may not leetcode.com 문제 더보기 Given an array of integers nums and an integer target, return indices of the two numbers such that they..

알고리즘/자료구조

[LeetCode] 150. Evaluate Reverse Polish Notation - Java

Evaluate Reverse Polish Notation - LeetCode Can you solve this real interview question? Evaluate Reverse Polish Notation - You are given an array of strings tokens that represents an arithmetic expression in a Reverse Polish Notation [http://en.wikipedia.org/wiki/Reverse_Polish_notation]. Evaluate t leetcode.com 문제 더보기 You are given an array of strings tokens that represents an arithmetic expres..

jny0
'알고리즘' 카테고리의 글 목록