i forgot to use capital I
When referring to yourself you should write "I" (capital) and not "i".
So correct the input string x, but be aware that other u...
約8年 前
解決済み
Print true if
all elements are larger than 5
a=[1 3 5 8 6];
b=[6 6 6 6 6];
function(a) should be false, and function(b) will be tru...
Diagonal & Anti-Diagonal Matrix: Easy
Create a matrix as shown below from "magic" square.
For example:
if input x=9;then use mgic(x) and create the matrix...
約8年 前
解決済み
Concatenate strings
concatenate a variable number of input strings to produce one outputstring
約8年 前
解決済み
How many jokers?
* Given DNA codes of a group of suspects,
* and a code for certain types of jokers,
* Count how many jokers of that type.
* ...
約8年 前
解決済み
Evil Number
Check if a given natural number is evil or not.
Read more at <https://oeis.org/A001969 OEIS>.
約8年 前
解決済み
Summing Digits within Text
Given a string with text and digits, add all the numbers together.
Examples:
Input str = '4 and 20 blackbirds baked in a...
約8年 前
解決済み
Reverse Run-Length Encoder
Given a "counting sequence" vector x, construct the original sequence y.
A counting sequence is formed by "counting" the entrie...
約8年 前
解決済み
De-dupe
Remove all the redundant elements in a vector, but keep the first occurrence of each value in its original location. So if
a =...
約8年 前
解決済み
Making change
Given an amount of currency, return a vector of this form:
[100 50 20 10 5 2 1 0.5 0.25 0.1 0.05 0.01]
Example:
Input a = ...
約8年 前
解決済み
Quote Doubler
Given a string s1, find all occurrences of the single quote character and replace them with two occurrences of the single quote ...
約8年 前
解決済み
Swap the first and last columns
Flip the outermost columns of matrix A, so that the first column becomes the last and the last column becomes the first. All oth...
約8年 前
解決済み
Which doors are open?
There are n doors in an alley. Initially they are all shut. You have been tasked to go down the alley n times, and open/shut the...