Solved


convert matrix to single column
given any matrix, convert it to single column

nästan 3 år ago

Solved


Specific Element Count
Given a vector _v_ and a element _e_, return the number of occurrences of _e_ in _v_. Note: NaNs are equal and there may be n...

nästan 3 år ago

Solved


Create incrementing array
Given a and b generate an output matrix as shown in following examples: a=2 b=5 output=[2 20 200 2000 20000] a=4 b...

nästan 3 år ago

Solved


Matrix indexing with two vectors of indices
Given a matrix M and two index vectors a and b, return a row vector x where x(i) = M(a(i),b(i)).

nästan 3 år ago

Solved


Back to basics 9 - Indexed References
Covering some basic topics I haven't seen elsewhere on Cody. Given an input matrix and row and column, output the index of th...

nästan 3 år ago

Solved


07 - Common functions and indexing 2
Define _eMat_: <<http://samle.dk/STTBDP/Assignment1_3e.png>> Calculate eMean as the mean across the rows of _eMat_. The an...

nästan 3 år ago

Solved


Who is the smartest MATLAB programmer?
Who is the smartest MATLAB programmer? Examples: Input x = 'Is it Obama?' Output = 'Me!' Input x = 'Who ?' Ou...

nästan 3 år ago

Solved


Cell joiner
You are given a cell array of strings and a string delimiter. You need to produce one string which is composed of each string fr...

nästan 3 år ago

Solved


Godfather or Goodfather
Recently, I watched the movie called the Godfather. In my opinoin, Vito Corleone is not just a godfather, he is also a good fat...

nästan 3 år ago

Solved


Y=X
Given an input variable x, output a variable y that is equal in value to x. Example: Input x = 1 Output y is 1 Inp...

nästan 3 år ago

Solved


Column norms of a matrix
Given a matrix M, return a vector y such that for each k y(k)=norm(M(:,k)) (y(k) is the Euclidean norm of the k-th col...

nästan 3 år ago

Solved


Back to basics 8 - Matrix Diagonals
Covering some basic topics I haven't seen elsewhere on Cody. Given an input vector of numbers, output a square array with the...

nästan 3 år ago

Solved


Sum of Two Numbers
Given two integer numbers x and y, calculate their sum and put it in z. Examples: Inputs x = 2, y = 4 Output z is 6 ...

nästan 3 år ago

Solved


Volume of a box
Given a box with a length a, width b, and height c. Solve the volume of the box.

nästan 3 år ago

Solved


give nth decimal place of pi
max 15th place after the decimal point is ok for now

nästan 3 år ago

Solved


Which quadrant?
Given a complex number, output quadrant 'I' 'II' 'III' or 'IV' | II | I | ...

nästan 3 år ago

Solved


Celsius to Kelvin
Convert Celsius degrees to Kelvin temperature.

nästan 3 år ago

Solved


Weighted average
Given two lists of numbers, determine the weighted average as follows Example [1 2 3] and [10 15 20] should result in 33.3...

nästan 3 år ago

Solved


Beginner's Problem - Squaring
Try out this test problem first. Given the variable x as your input, square it by two and put the result in y. Examples: ...

nästan 3 år ago

Solved


Replace May with April
For instance, if the input is input_str = 'The flowers may bloom in April'; then the output is output_str = 'The flo...

nästan 3 år ago

Solved


Building matrices
If you have matrix A, create matrix B using matrix A as an "element" A = [1 2 3 4; 5 6 7 8...

nästan 3 år ago

Solved


03 - Matrix Variables 4
Make the following variable: <<http://samle.dk/STTBDP/Assignment1_3d.png>> A 3x4 NaN (Not a Number) matrix (Hint: use ...

nästan 3 år ago

Solved


pressure to dB?
given x ratio of pressure, find corresponding y dB

nästan 3 år ago

Solved


Create a Multiplication table matrix...
Create a product table in this format: P = [ 1 2 3 4 5; 2 4 6 8 10; 3 6 9 12 15; 4 8 12 1...

nästan 3 år ago

Solved


Rounding off numbers to n decimals
Inspired by a mistake in one of the problems I created, I created this problem where you have to round off a floating point numb...

nästan 3 år ago

Solved


Solve the Sudoku Row
*Description* A simple yet tedious task occurs near the end of most Sudoku-solving algorithms, computerized or manual. The ta...

nästan 3 år ago

Solved


06 - Matrix Equations 3
Define the matrices _aMat_, _bMat_, and _cMat_: <<http://samle.dk/STTBDP/Assignment1_3a.png>> ( _aMat_ = 9x9 matrix full o...

nästan 3 år ago

Solved


Square the input
Given a scalar or vector x, return the square of each element. Example x = [7 2] answer = [49 4]

nästan 3 år ago

Solved


Matlab Basics - Create a row vector
Write a Matlab script to create a row vector of 10 consecutive numbers x = [1 2 3 4 5 6 7 8 9 10]

nästan 3 år ago

Solved


Vectors counting by 2
Create a vector numbers from 7 to 15 in increments of 2

nästan 3 år ago

Load more