Solved


Convert a vector into a number
This is a sub problem related to this problem: <http://www.mathworks.com/matlabcentral/cody/problems/621-cryptomath-addition>...

13 hours ago

Solved


How to add?
* Imagine you are in 2222 Anno Domini, when everyone must learn how to add, * and competing for the highly prestigious post of,...

13 hours ago

Solved


Stuff the Board
You have a stack of tiles to put onto an array-like playing board. Each tile has a number (always an integer), and the board var...

13 hours ago

Solved


How to multiply?
Imagine you are in 3012 Anno Domini, when everyone must learn how to multiply, and competing for the highly prestigious post of...

13 hours ago

Solved


How many palindromes?
* Given a set of letters, count all possible palindromes, using all of those letters. * For example, if the set is {'A' 'A' 'A'...

13 hours ago

Solved


Create One Large Eye of size N x N Quickly?
*<http://en.wikipedia.org/wiki/Aye_(yes) Aye !!!>*

14 hours ago

Solved


convert?
* Given a string containing a number followed by pounds or kgs, for example: * 'Billy lost 22 pounds in four weeks.' * 'Maria ...

14 hours ago

Solved


Converting Decimal to Binary
Given a decimal number that may include a fractional component, convert it into binary representation. The numbers you are given...

14 hours ago

Solved


Spot the rectangle (Part 2)
This problem is related to the 17x17 challenge. See also Part 1 of this problem. Given a matrix in which each element is either ...

14 hours ago

Solved


Spot the rectangle
This problem is related to the 17x17 challenge. Given a matrix filled with ones and zeros, determine whether or not any rectangl...

14 hours ago

Solved


Find the Kronecker Tensor Product without using KRON
The Kronecker Tensor Product is the result of multiplying all elements of a matrix with each of the elements of another matrix. ...

14 hours ago

Solved


Dick Van Dyck?
Not the celebrity, Dick Van Dyke, this problem relates to balanced strings of parentheses, Dyck Language. Please attach the de...

14 hours ago

Solved


Fastest shortest-path-finder in the west
Given connectivity information about a graph, your job is to find the shortest-path distance between every pair of vertices in t...

14 hours ago

Solved


Formatting currency numbers
Given a number, format it properly for textual display using the notation $xxx,xxx,xxx.xx. Assume that no more than two digits ...

14 hours ago

Solved


Aufbau principle
Given the order e=[1s, 2s, 2p, 3s, 3p, 4s, 3d, 4p, 5s, 4d, 5p, 6s, 4f, 5d, 6p, 7s, 5f, 6d, 7p], find a vector x with these condi...

14 hours ago

Solved


love is an n-letter word
Given a list of *N words*, return the *N-letter word* (choosing one letter from each word) with the property of having the least...

14 hours ago

Solved


bad colorimeter?
You have tested one good and one bad colorimeters with a colored solution at two path lengths of light and recorded transmittanc...

14 hours ago

Solved


Recurring Cycle Length (Inspired by Project Euler Problem 26)
Preface: This problem is inspired by Project Euler Problem 26 and uses text from that question to explain what a recurring cycle...

14 hours ago

Solved


drowsy?
This dog() may be drowsy or function immediately when you call, return 1 or 0 accordingly within 2/10 second.

14 hours ago

Solved


Decimal Comparison
*Background* A utility of particular interest to Cody and other MATLAB ventures is comparing the equality of two numbers. In ...

14 hours ago

Solved


Back to basics 2 - Function Path
Covering some basic topics I haven't seen elsewhere on Cody. Given a string that is the name of a MATLAB function, return a s...

14 hours ago

Solved


Find matching string from a list of strings
Write a function that returns a string that is a unique match (if it exists) of the string inStr from a list of strings strList....

14 hours ago

Solved


chance in percent for minimum K heads when a good coin is tossed N times?
For example, chance is 100% for minimum 0 heads when a coin is tossed 7 times. Chance is 50% for minimum 2 heads when a coin is...

14 hours ago

Solved


Generalized N-Cards Problem
Preface: This is a generalized version of the problem I presented <http://www.mathworks.com/matlabcentral/cody/problems/271-n-ca...

14 hours ago

Solved


N-Cards Problem
You have a deck of _N_ cards numbered in order from 1 to _N_. You discard the top card (card 1) and place the next card (card 2)...

14 hours ago

Solved


Project Euler: Problem 16, Sums of Digits of Powers of Two
2^15 = 32768 and the sum of its digits is 3 + 2 + 7 + 6 + 8 = 26. What is the sum of the digits of the number 2^N? Thanks ...

16 hours ago

Solved


Distance walked 3D
suppose you go from x-y-z coordinates [3,4,2] to [0,0,2] to [0,1,2] to [1,1,2], to [1,1,20] then you walked 25 units of distance...

16 hours ago

Solved


Filter values in a vector
Cody often benefits from a functional style of programming. For example, your score is often better when you compose multiple fu...

16 hours ago

Solved


Create a dictionary
The goal is to write a function that returns a dictionary from a list of words or phrases and their definitions. Here is an exam...

16 hours ago

Solved


fly fly away
A fly moves following a predefined sequence of discrete jumps (defined by the vectors _dx_ and _dy_) repeating the same sequence...

16 hours ago

Load more