Stable Setup (Decision Algorithm)

Problem N stables are on a vertical line. Each stable has the coordinates of x1, x2, x3, …, xN, and there is no overlap of coordinates between the stables. Hyeonsu has C horses, who don’t like being close to each other. Each stable can only hold one horse, and we want the horses to be placed in the…

Read More

Music Video (Decision Tree Algorithm)

Problem Genie Records is trying to sell the live video of the undisputed singer Youngpil Cho on DVD. A total of N songs are included in a DVD, and when recording on a DVD, the order in live should be maintained. Our singer Youngpil Cho hates the change of order. That is, in order to record songs…

Read More

Binary Search

Problem Any N numbers are given as input. Write a program that sorts N numbers in ascending order and, given M, which is one of the N numbers, uses binary search to find the number of M in the sorted state. However, there are no duplicate values. input The first line gives the natural numbers N (…

Read More

When your image source not loading well... encodeURI() VS encodeURIComponent()

Introduction Sometimes we encounter URL problems because of special letters such as , , , blank space, and etc. In this case, we can apply some useful method: and . But, what’s the difference here? and encodes a by replacing reserved characters with their encoding. More specifically these…

Read More

Meeting Room Assignment

Problem Conference Room There is one conference room, and we want to create a conference room usage table for n conferences that we want to use. Find the maximum number of meetings that are given the time and can use the conference room without overlapping each meeting. However, once a meeting…

Read More
Page 4 Of 26