본문 바로가기

JavaScript554

[Codewars] Remove duplicates from list( kyu) / JavaScript https://www.codewars.com/kata/57a5b0dfcf1fa526bb000118 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: Define a function that removes duplicates from an array of numbers and .. 2023. 5. 6.
[백준] 11282: 한글 / Node.js (JavaScript) https://www.acmicpc.net/problem/11282 11282번: 한글 한글의 각 글자는 초성, 중성, 종성으로 이루어져 있고, 이 세 가지를 모아써서 한 글자를 나타낸다. 초성은 ㄱ, ㄲ, ㄴ, ㄷ, ㄸ, ㄹ, ㅁ, ㅂ, ㅃ, ㅅ, ㅆ, ㅇ, ㅈ, ㅉ, ㅊ, ㅋ, ㅌ, ㅍ, ㅎ로 총 19개가 있 www.acmicpc.net 문제 한글의 각 글자는 초성, 중성, 종성으로 이루어져 있고, 이 세 가지를 모아써서 한 글자를 나타낸다. 초성은 ㄱ, ㄲ, ㄴ, ㄷ, ㄸ, ㄹ, ㅁ, ㅂ, ㅃ, ㅅ, ㅆ, ㅇ, ㅈ, ㅉ, ㅊ, ㅋ, ㅌ, ㅍ, ㅎ로 총 19개가 있고, 중성은 ㅏ, ㅐ, ㅑ, ㅒ, ㅓ, ㅔ, ㅕ ㅖ, ㅗ, ㅘ, ㅙ, ㅚ, ㅛ, ㅜ, ㅝ, ㅞ, ㅟ, ㅠ, ㅡ, ㅢ, ㅣ로 총 21개, 종.. 2023. 5. 6.
[백준] 2523: 별 찍기 - 13 / Node.js (JavaScript) https://www.acmicpc.net/problem/2523 2523번: 별 찍기 - 13 첫째 줄부터 2×N-1번째 줄까지 차례대로 별을 출력한다. www.acmicpc.net 문제 예제를 보고 규칙을 유추한 뒤에 별을 찍어 보세요. 입력 첫째 줄에 N(1 ≤ N ≤ 100)이 주어진다. 출력 첫째 줄부터 2×N-1번째 줄까지 차례대로 별을 출력한다. 예제 입력 1 3 예제 출력 1 * ** *** ** * 코드 const N = parseInt(require('fs').readFileSync('/dev/stdin').toString()); const result = []; for(let i = 1; i 0; i--){ result.push("*".repeat(i)); } console.log(r.. 2023. 5. 5.
[Codewars] Grasshopper - Messi goals function (8 kyu) / JavaScript https://www.codewars.com/kata/55f73be6e12baaa5900000d4 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: Messi goals function Messi is a soccer player with goals in three leagu.. 2023. 5. 5.