随笔分类 - codewars-js
摘要:问题描述: Pete likes to bake some cakes. He has some recipes and ingredients. Unfortunately he is not good in maths. Can you help him to find out, how man
阅读全文
摘要:问题描述: A happy number is a number defined by the following process: starting with any positive integer, replace the number by the sum of the squares of
阅读全文
摘要:问题描述: A Hamming number is a positive integer of the form 2i3j5k, for some non-negative integers i, j, and k. Write a function that computes the nth sm
阅读全文
摘要:问题描述: Consider the following expansion: Given a string, return the expansion of that string. Input will consist of only lowercase letters and numbers
阅读全文
摘要:问题描述: In this kata, you will make a function that converts between camelCase, snake_case, and kebab-case. You must write a function that changes to a
阅读全文
摘要:问题描述: The rgb() method is incomplete. Complete the method so that passing in RGB decimal values will result in a hexadecimal representation being retu
阅读全文
摘要:问题描述: In mathematics, the factorial of integer n is written as n!. It is equal to the product of n and every integer preceding it. For example: 5! = 1
阅读全文
摘要:问题描述: A format for expressing an ordered list of integers is to use a comma separated list of either individual integers or a range of integers denote
阅读全文
摘要:问题描述: Two Joggers Description Bob and Charles are meeting for their weekly jogging tour. They both start at the same spot called "Start" and they each
阅读全文
摘要:问题描述: Write a program that will calculate the number of trailing zeros in a factorial of a given number. N! = 1 * 2 * 3 * ... * N Be careful 1000! has
阅读全文
摘要:问题描述: Write a function that takes a string of braces, and determines if the order of the braces is valid. It should return true if the string is valid
阅读全文
摘要:问题描述:(将阿拉伯数字转换成罗马数字) Create a function taking a positive integer as its parameter and returning a string containing the Roman Numeral representation o
阅读全文
摘要:问题描述:(找出奇数数组中唯一的偶数,或是偶数数组中唯一的奇数) You are given an array (which will have a length of at least 3, but could be very large) containing integers. The arr
阅读全文
摘要:问题描述: 对输入的str按照sz个数进行分块,若一块内所有数字的立方和是偶数,则倒序;否则,向左移动一位。然后将修改过的块整合到一个字符串,作为输出。 The input is a string str of digits. Cut the string into chunks (a chunk
阅读全文
摘要:问题描述: Write a function, which takes a non-negative integer (seconds) as input and returns the time in a human-readable format (HH:MM:SS) HH = hours, p
阅读全文
摘要:问题描述: you will be given a number and you will need to return it as a string in Expanded Form. For example: NOTE: All numbers will be whole numbers gre
阅读全文
摘要:Write a function that accepts an array of 10 integers (between 0 and 9), that returns a string of those numbers in the form of a phone number. Example
阅读全文
摘要:题目: You live in the city of Cartesia where all roads are laid out in a perfect grid. You arrived ten minutes too early to an appointment, so you decid
阅读全文
摘要:问题描述: Return the number (count) of vowels in the given string. We will consider a, e, i, o, and u as vowels for this Kata. The input string will only
阅读全文
摘要:题目描述: Count the number of Duplicates Write a function that will return the count of distinct case-insensitive alphabetic characters and numeric digits
阅读全文

浙公网安备 33010602011771号