Community Profile

photo

Markus Petershofen


Last seen: mer än 2 år ago Active since 2016

Statistics

All
  • 5-Star Galaxy Level 4
  • Personal Best Downloads Level 2
  • First Review
  • First Submission
  • Solver

View badges

Content Feed

View by

Solved


Remove NaN ?
input -> matrix (n*m) with at least one element equal to NaN; output -> matrix(p*m), the same matrix where we deleted the enti...

mer än 2 år ago

Solved


Back to basics 21 - Matrix replicating
Covering some basic topics I haven't seen elsewhere on Cody. Given an input matrix, generate an output matrix that consists o...

mer än 2 år ago

Solved


Remove the air bubbles
Given a matrix a, return a matrix b in which all the zeros have "bubbled" to the top. That is, any zeros in a given column shoul...

mer än 2 år ago

Solved


Flip the main diagonal of a matrix
Given a n x n matrix, M, flip its main diagonal. Example: >> M=magic(5); >> flipDiagonal(M) 9 24 1 ...

mer än 2 år ago

Solved


Flip the vector from right to left
Flip the vector from right to left. Examples x=[1:5], then y=[5 4 3 2 1] x=[1 4 6], then y=[6 4 1]; Request not ...

mer än 2 år ago

Solved


Another colon problem
This is simple problem based on problems 555, 801, 1118, etc. Create an index vector from two input vectors. Example: ...

ungefär 6 år ago

Solved


Back to basics - mean of corner elements of a matrix
Calculate the mean of corner elements of a matrix. e.g. a=[1 2 3; 4 5 6; 7 8 9;] Mean = (1+3+7+9)/4 = 5

ungefär 6 år ago

Submitted


ColorSpill
Color Spill Game

nästan 7 år ago | 2 downloads |

Thumbnail

Submitted


Pacman
Play Pacman, draw your own enemies, create your own levels, adjust configurations, have fun!

nästan 7 år ago | 11 downloads |

Thumbnail

Submitted


TheLastStand
Object-oriented defense game

ungefär 7 år ago | 1 download |

Thumbnail

Solved


Is this triangle right-angled?
Given three positive numbers a, b, c, where c is the largest number, return *true* if the triangle with sides a, b and c is righ...

ungefär 7 år ago

Solved


Length of the hypotenuse
Given short sides of lengths a and b, calculate the length c of the hypotenuse of the right-angled triangle. <<http://upload....

ungefär 7 år ago

Solved


Nearest Numbers
Given a row vector of numbers, find the indices of the two nearest numbers. Examples: [index1 index2] = nearestNumbers([2 5 3...

ungefär 7 år ago

Solved


Target sorting
Sort the given list of numbers |a| according to how far away each element is from the target value |t|. The result should return...

ungefär 7 år ago

Solved


Find the sum of all the numbers of the input vector
Find the sum of all the numbers of the input vector x. Examples: Input x = [1 2 3 5] Output y is 11 Input x ...

ungefär 7 år ago

Solved


Make the vector [1 2 3 4 5 6 7 8 9 10]
In MATLAB, you create a vector by enclosing the elements in square brackets like so: x = [1 2 3 4] Commas are optional, s...

ungefär 7 år ago

Solved


Simple equation: Annual salary
Given an hourly wage, compute an annual salary by multiplying the wage times 40 and times 50, because salary = wage x 40 hours/w...

ungefär 7 år ago

Solved


Reverse the vector
Reverse the vector elements. Example: Input x = [1,2,3,4,5,6,7,8,9] Output y = [9,8,7,6,5,4,3,2,1]

ungefär 7 år ago

Solved


Most nonzero elements in row
Given the matrix a, return the index r of the row with the most nonzero elements. Assume there will always be exactly one row th...

ungefär 7 år ago

Solved


Finding Perfect Squares
Given a vector of numbers, return true if one of the numbers is a square of one of the other numbers. Otherwise return false. E...

ungefär 7 år ago

Submitted


MinesweeperGame
Another Minesweeper Clone

ungefär 7 år ago | 1 download |

Thumbnail

Submitted


RayCasting
Interactive demonstration of raycasting algorithm.

ungefär 7 år ago | 3 downloads |

Thumbnail

Submitted


geneticAlgoWords
My first attempt at genetic algorithms

ungefär 7 år ago | 1 download |

Thumbnail

Solved


Sum all integers from 1 to 2^n
Given the number x, y must be the summation of all integers from 1 to 2^x. For instance if x=2 then y must be 1+2+3+4=10.

ungefär 7 år ago

Solved


Determine whether a vector is monotonically increasing
Return true if the elements of the input vector increase monotonically (i.e. each element is larger than the previous). Return f...

ungefär 7 år ago

Solved


Find all elements less than 0 or greater than 10 and replace them with NaN
Given an input vector x, find all elements of x less than 0 or greater than 10 and replace them with NaN. Example: Input ...

ungefär 7 år ago

Solved


Select every other element of a vector
Write a function which returns every other element of the vector passed in. That is, it returns the all odd-numbered elements, s...

ungefär 7 år ago

Solved


Check if sorted
Check if sorted. Example: Input x = [1 2 0] Output y is 0

ungefär 7 år ago

Solved


Multielement indexing of a row array
The row array birthRateChina stores the China birth rate (per 1000 people) for years 2000 to 2012. Write a statement that create...

mer än 7 år ago

Solved


Create a row array using double colon operator
Create a row array from 9 to 1, using the double colon operator.

mer än 7 år ago

Load more