Feeds
문제를 풀었습니다
Calculate a modified Levenshtein distance between two strings
Inspired by the Cody problem found here. The Levenshtein distance is a charater-based string metric used to measure the differe...
3일 전
문제를 풀었습니다
Calculate the Hamming distance between two strings
Inspired by a similar Cody problem found <http://www.mathworks.com/matlabcentral/cody/problems/93-calculate-the-levenshtein-dist...
3일 전
문제를 풀었습니다
Calculator spelling - Letters to Numbers
Using the numbers on a calculator, and rotating the display 180 degrees, many words can be spelled. In particular, the following...
4일 전
문제를 풀었습니다
Legend of Zelda - Rupee Count (Item Purchase)
Building off of <https://www.mathworks.com/matlabcentral/cody/problems/3025-zelda-rupee-count Problem 3025>, suppose that an arr...
4일 전
문제를 풀었습니다
Legend of Zelda - Rupee Count (Compact)
Building off of <https://www.mathworks.com/matlabcentral/cody/problems/3025-zelda-rupee-count Problem 3025>, suppose that Link's...
4일 전
문제를 풀었습니다
Pi Digit Probability
Assume that the next digit of pi constant is determined by the historical digit distribution. What is the probability of next di...
4일 전
문제를 풀었습니다
Pi Estimate 1
Estimate Pi as described in the following link: <http://www.people.virginia.edu/~teh1m/cody/Pi_estimation1.pdf>
4일 전
문제를 풀었습니다
Given a square and a circle, please decide whether the square covers more area.
You know the side of a square and the diameter of a circle, please decide whether the square covers more area.
4일 전
문제를 풀었습니다
Approximation of Pi
Pi (divided by 4) can be approximated by the following infinite series: pi/4 = 1 - 1/3 + 1/5 - 1/7 + ... For a given number of...
4일 전
문제를 풀었습니다
Linear primes p' = mp + n
Problem statement List the prime numbers of the form p' = mp + n for a given (m,n) couple and such that p' < k, k positive in...
4일 전
문제를 풀었습니다
Find the starting index of a consecutive condition
Given a logical vector |v|, and a positive integer |n|, return the smallest index |i| that satisfies: all( v(i : i+n-1) ) =...
9일 전
문제를 풀었습니다
Calculator spelling - Numbers to Letters
Using the numbers on a calculator, and rotating the display 180 degrees, many words can be spelled. In particular, the following...
17일 전
문제를 풀었습니다
Did you say please? - Find one string within another without strfind or regexp/regexpi
For a given string sentence, determine if the string word 'please' is present or not. If so, return the string 'OK', else return...
17일 전
문제를 풀었습니다
most frequent character
Obtain the most frequent character. For example, s='balaram'; output='a'; If there is a tie between letters, return t...
23일 전
문제를 풀었습니다
Backslang, odds are you used it at some point in time...
So backslang is a language that can be used to communicate in an easy decode code, if people know the rules of decoding it. Wel...
23일 전
문제를 풀었습니다
Concatenate strings
concatenate a variable number of input strings to produce one outputstring
23일 전
문제를 풀었습니다
Split a given string from the first instance of a given character
A simple operation to split a given string into two substrings at the point where the desired character is first found. e.g. ...
23일 전
문제를 풀었습니다
NO _________ ALLOWED....
So you're given a sentence where if there is a particular word in the sentence then the output is 1, if it is not there then the...
23일 전
문제를 풀었습니다
ABBREVIATION
Abbreviate the given string. Consider Only Capital Letters. EXAMPLE If input is 'Abbreviation of The Given String' then ou...
23일 전
문제를 풀었습니다
Make a list string
Given a cell string, produce a string separating the items with spaces and commas and with an 'and' preceding the final item, an...
23일 전
문제를 풀었습니다
Convert Two Character String into a Binary Vector
Given a string "XOXXO" convert it into a binary vector. [1 0 1 1 0] Paul Berglund implemented an optimal method in <http://ww...
23일 전
문제를 풀었습니다
Join Strings with Multiple Different Delimiters
The idea is to form the string S by interleaving the elements of a cell array of strings DELIMITER and another cell array of st...
23일 전
문제를 풀었습니다
How many digits are there?
Input(s) - any string Output(n) - number of digits within string s
23일 전
문제를 풀었습니다
Alternately upper-lower case
Modify the string to alternate between upper and lower case. For example, s='achyuta' output='AcHyUtA' Update - Test case...
23일 전
문제를 풀었습니다
Beauty of Parentheses
Given a string consisting of closed parentheses, form a string array in the following way so that the orders of these parenthese...
23일 전
문제를 풀었습니다
Genome decoding
Inspired by a question on the answer forum: You are given a matrix of 8-bit integers which encodes a genome. Each integer can...
23일 전











