Digits eliminate
Complete the function my_f(n,b) to return, for a given integer, the number obtained by removing the digits '0' and 'b'. If there...
27 days ago
Solved
Remove the diagonal of a square matrix
Some Cody problems ask solvers to remove columns (e.g., CP 7), and others ask solvers to remove rows (e.g., CP 44033).
Write a...
27 days ago
Solved
Conditional transpose II
As in problem 60734, you're given two vectors, x and y, which might be row or a column vectors. Your task is to ensure that y ha...
27 days ago
Solved
Diagonal Product of A Square Matrix
For a matrix A, calculate the product of its diagonal elements.
* Assume all input matrices are square & corresponding element...
Describe n from right to left
If you were to describe the number 46 from right to left, you could say “one 6, one 4”, or 1614. The number 8663 would be “one 3...
27 days ago
Solved
Conditional transpose
You're given two vectors of the same length, x and y, which might be row or a column vectors. Your task is to ensure that y has ...
27 days ago
Solved
Beads on a Necklace (Convex Hulls)
We may describe a <http://en.wikipedia.org/wiki/Convex_hull convex hull> as a rubber band stretched around a list of points. Som...