본문 바로가기

JavaScript554

[Codewars] Do I get a bonus? (8 kyu) / JavaScript https://www.codewars.com/kata/56f6ad906b88de513f000d96 Codewars - Achieve mastery through coding practice and developer mentorship A coding practice website for all programming levels – Join a community of over 3 million developers and improve your coding skills in over 55 programming languages! www.codewars.com DESCRIPTION: It's bonus time in the big city! The fatcats are rubbing their paws in .. 2023. 2. 16.
[백준] 9659: 돌 게임 5 / Node.js (JavaScript) https://www.acmicpc.net/problem/9659 9659번: 돌 게임 5 첫째 줄에 N이 주어진다. (1 ≤ N ≤ 1,000,000,000,000) www.acmicpc.net 문제 돌 게임은 두 명이서 즐기는 재밌는 게임이다. 탁자 위에 돌 N개가 있다. 상근이와 창영이는 턴을 번갈아가면서 돌을 가져가며, 돌은 1개 또는 3개 가져갈 수 있다. 마지막 돌을 가져가는 사람이 게임을 이기게 된다. 두 사람이 완벽하게 게임을 했을 때, 이기는 사람을 구하는 프로그램을 작성하시오. 게임은 상근이가 먼저 시작한다. 입력 첫째 줄에 N이 주어진다. (1 ≤ N ≤ 1,000,000,000,000) 출력 상근이가 게임을 이기면 SK를, 창영이가 게임을 이기면 CY을 출력한다. 예제 입력 1 5 .. 2023. 2. 15.
[Codewars] Which are in? (6 kyu) / JavaScript https://www.codewars.com/kata/550554fd08b86f84fe000a58 Codewars - Achieve mastery through coding practice and developer mentorship A coding practice website for all programming levels – Join a community of over 3 million developers and improve your coding skills in over 55 programming languages! www.codewars.com DESCRIPTION: Given two arrays of strings a1 and a2 return a sorted array r in lexico.. 2023. 2. 15.
[백준] 9658: 돌 게임 4 / Node.js (JavaScript) https://www.acmicpc.net/problem/9658 9658번: 돌 게임 4 상근이가 게임을 이기면 SK를, 창영이가 게임을 이기면 CY을 출력한다. www.acmicpc.net 문제 돌 게임은 두 명이서 즐기는 재밌는 게임이다. 탁자 위에 돌 N개가 있다. 상근이와 창영이는 턴을 번갈아가면서 돌을 가져가며, 돌은 1개, 3개 또는 4개 가져갈 수 있다. 마지막 돌을 가져가는 사람이 게임을 지게 된다. 두 사람이 완벽하게 게임을 했을 때, 이기는 사람을 구하는 프로그램을 작성하시오. 게임은 상근이가 먼저 시작한다. 입력 첫째 줄에 N이 주어진다. (1 ≤ N ≤ 1000) 출력 상근이가 게임을 이기면 SK를, 창영이가 게임을 이기면 CY을 출력한다. 예제 입력 1 6 예제 출력 1 SK 코.. 2023. 2. 14.