Solved


Remove element(s) from cell array
You can easily remove an element (or a column in any dimension) from a normal matrix, but assigning that value (or range) empty....

meer dan 4 jaar ago

Solved


Cell Counting: How Many Draws?
You are given a cell array containing information about a number of soccer games. Each cell contains one of the following: * ...

meer dan 4 jaar ago

Solved


String Array Basics, Part 2: Convert String Array to Cell Array; No Missing Values
<http://www.mathworks.com/help/matlab/characters-and-strings.html String array> and cell array are two types of containers for s...

meer dan 4 jaar ago

Solved


String Array Basics, Part 1: Convert Cell Array to String Array; No Missing Values
<http://www.mathworks.com/help/matlab/characters-and-strings.html String array> and cell array are two types of containers for s...

meer dan 4 jaar ago

Solved


Fix the last element of a cell array
Note: this is lifted directly from <http://www.mathworks.com/matlabcentral/answers/82825-puzzler-for-a-monday Puzzler for a Mond...

meer dan 4 jaar ago

Solved


Natural numbers in string form
Create a cell array of strings containing the first n natural numbers. _Slightly_ harder than it seems like it should be. Ex...

meer dan 4 jaar ago

Solved


Remove the polynomials that have positive real elements of their roots.
The characteristic equation for a dynamic system is a polynomial whose roots indicate its behavior. If any of the <http://www.ma...

meer dan 4 jaar ago

Solved


Shuffle
Shuffle a vector by breaking it up to segments of |n| elements, and rearranging them in a reversed order. For example, the ve...

meer dan 4 jaar ago

Solved


Vector push
Append an element |x| to the end of the vector |v| and return both the extended vector and the new number of its elements. |x| c...

meer dan 4 jaar ago

Solved


Vector pop
Take |n| elements from the end of the vector |v| and return both the shorten vector |v| and the |n| elements in a separate vecto...

meer dan 4 jaar ago

Solved


Remove the small words from a list of words.
Your job is to tidy up a list of words that appear in a string. The words are separated by one or more spaces. Remove all words ...

meer dan 4 jaar ago

Solved


Reverse the Words (not letters) of a String
*Description* Change the words of a string such that the words appear in reverse order. You may assume that the string is a n...

meer dan 4 jaar ago

Solved


Find the average of a random sequance
Write a function that generates random integers within a loop, and calculates the mean of the positive numbers only. At each ...

meer dan 4 jaar ago

Solved


Encode Roman Numerals
Create a function taking a non-negative integer as its parameter and returning a string containing the Roman Numeral representat...

meer dan 4 jaar ago

Solved


Separate even from odd numbers in a vector - with a loop
*Using a loop*, rearrange a vector of integers such that the odd numbers appear at the beginning, and even numbers at the end. T...

meer dan 4 jaar ago

Solved


Triangle of numbers
Create a matrix with the integers from 1 to |n| arranged in a triangular shape. Every row |i| of the matrix contains |i| inte...

meer dan 4 jaar ago

Solved


Get the combinations
Consider p,q = 2 vectors of same or different length. Get a Output Array which has all the possible combinations of Elements o...

meer dan 4 jaar ago

Solved


New Matrix with vector addition on diagonal
consider 2 vectors x=[1 2 3] y=[4 5 6] then generate a new Matrix, where Addition of x & y will be diagonal Elements...

meer dan 4 jaar ago

Solved


Number Power
Raise a number to itself.

meer dan 4 jaar ago

Solved


Transpose the Matrix
Transpose the given matrix, e.g. x=[a b;c d] transpose of x = [a c;b d]

meer dan 4 jaar ago

Solved


Return all matrix elements except elements on diagonal
Consider a given Matrix A=[a b c; d e f; g h i] then return a row vector T such that it contains all the El...

meer dan 4 jaar ago

Solved


Reverse the Matrix
Given a Matrix A, reverse it. Such that, last element of A becomes 1st and vice versa. for example: Input = [1 2 3;4 5 ...

meer dan 4 jaar ago

Solved


Diagonal Pattern
For a positive integer |n|, return an |nXn| matrix |mat| such that the value of each element in row |i| and column |j| is given ...

meer dan 4 jaar ago

Solved


Rearrange the given matrix to have all its zeros climb up to the top of each column - using for loops.
Given a matrix x, *using loops only* return a matrix y, in which all the zeros have "climbed" up to the top. That is, any zeros ...

meer dan 4 jaar ago

Solved


Given a matrix A return a vector of the product of the elements in each column using a loop without using prod.
--------------------- for m: 3 1 3 3 10 1 9 1 9 4 1 4 5 6 5 ...

meer dan 4 jaar ago

Solved


Given a matrix A (size m x n) create a matrix B which consists of matrix A sorted in descending order by columns and then by rows.
--------------- A= [ 2 6 -3 7 12 0 -12 5 1] --------------- B= [12 7 1 6 2 0 5 -3 ...

meer dan 4 jaar ago

Solved


cross in array
Make a cross from "1" in odd size array. Other value from array should be equal to "0"; As input you get length of side of arra...

meer dan 4 jaar ago

Solved


Basics - not so easy division
Please make a function whcih divides x/y, but pay attention for some exceptions with NaN,0,Inf. Sometimes return "ERROR" instead...

meer dan 4 jaar ago

Solved


Ounces to Kilograms
convert ounces to kilograms, easy

meer dan 4 jaar ago

Solved


subtraction of two nos
given a and b, subtract and give the answer

meer dan 4 jaar ago

Load more