목록분류 전체보기 (373)
Silver Library (Archived)
https://www.hackerrank.com/challenges/js10-loops/problem Personal note: the code makes sense but how on earth I can remember such a method on that day...? whatever the condition is; I need to keep rolling this. 'use strict'; process.stdin.resume(); process.stdin.setEncoding('utf-8'); let inputString = ''; let currentLine = 0; process.stdin.on('data', inputStdin => { inputString += inputStdin; })..
Personally, this algorithm is very useful & did not know how to do this thing. According to other people, this can be better off. function getLetter(s) { let letter; // Write your code here let characterA = "aeiou"; let characterB = "bcdfg"; let characterC = "hjklm"; let characterD = "npqrstvwxyz"; for(let i in s){ if (characterA.includes(s[0])){ letter = "A"; } else if (characterB.includes(s[0]..
hackerrank, 10days of JS. Title: Day 2: conditional statement if-else Personal note: This is for the record to see how I figured out the algorithm. Initially, function getGrade(score) { let grade; is given. Then the question is; how to implement the following condition. If (25 < score
Pros: (of practising the algorithm) 1. Good revision to learn the language I use. 2. Increase the possibility to get a proper job. 3. Hope rises Cons: 1. Motivation falls drastically Conclusion: Do focus on algorithm 70%, 30% is the usual work (e.g. practising React and JS). From now on, do not all-in to the algorithm.