My Cody Challenge Solutions
Cody Challenge found here: http://www.mathworks.com/matlabcentral/cody/?sort=&term=group%3A%22Cody+Challenge%22
Solutions are what I have created and not the best solution possible.
Complete = 34/96
- 1: Times 2
- 2: Make the vector - [1 2 3 4 5 6 7 8 9 10]
- 3: Find the sum of the input vector
- 4: Make a checkerboard matrix
- 5: Triangle Numbers
- 6: Select every other element of a vector
- 7: Column Removal
- 8: Add two numbers
- 9: Who Has the Most Change
- 10: Determine if vector is monotonically increasing
- 11: Back and Forth Rows
- 12: Fibonacci sequence
- 13
- 14: Find the mean of the prime numbers in a matrix
- 15
- 16: Return the largest number adjacent to a zero
- 17: Replace elements less than 0 or greater than 10 with NaN
- 18: Bullseye Matrix
- 19: Swap the first and last columns
- 20: Summing digits
- 21: Return the 3n+1 sequence
- 22
- 23: Finding Perfect Squares
- 24
- 25
- 26: Determine if input is odd
- 27
- 28: Counting Money
- 29: Nearest Numbers
- 30: Sort a list of complex numbers
- 31
- 32: Most nonzero elements in row
- 33: Create times-tables
- 34
- 35
- 36
- 37: Pascal's Triangle
- 38
- 39: Which values occur three times?
- 40
- 41
- 42
- 43
- 44
- 45
- 46: Which doors are open?
- 47
- 48: Making Change
- 49
- 50
- 51: Find the two most distant points
- 52
- 53
- 54
- 55
- 56
- 57
- 58
- 59
- 60: The Goldbach Conjecture
- 61
- 62
- 63
- 64
- 65
- 66
- 67
- 68
- 69
- 70
- 71
- 72
- 73
- 74
- 75
- 76
- 77
- 78
- 79
- 80
- 81
- 82
- 83
- 84
- 85
- 86
- 87: Indexed Probability Table
- 88
- 89
- 90
- 91
- 99
- 93
- 94: Target sorting
- 95
- 96