Risolto


only input
Return the output without writing any code into the function.

quasi 13 anni fa

Risolto


Dots in a Circle
Return how many integer grid points there are inside a circle of radius _r_ centred at (0,0) (including points on the edge). ...

quasi 13 anni fa

Risolto


Rotate a Matrix
Input a Matrix x, Output y is the matrix rotating x 90 degrees clockwise

quasi 13 anni fa

Risolto


Determine Whether an array is empty
Input a matrix x, output y is TRUE if x is empty, otherwise FALSE.

quasi 13 anni fa

Risolto


All your base are belong to us
Find the base _b_ logarithm of the input decimal number _x_. Express the output as a decimal number. The first argument is the n...

quasi 13 anni fa

Risolto


Back to basics 6 - Column Vector
Covering some basic topics I haven't seen elsewhere on Cody. Given an input vector, output true or false whether it is a colu...

quasi 13 anni fa

Risolto


Find the largest value in the 3D matrix
Given a 3D matrix, A, find the largest value. E.g. >> A = 1:9; >> A=reshape(A,[3 1 3]); >> islargest(A) ans = 9

quasi 13 anni fa

Risolto


Rotate a Matrix by 90 degrees
Rotate a Matrix by 90 degrees Example: If the input is: X = 1 2 3 4 5 6 7 8 9 ...

quasi 13 anni fa

Risolto


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

quasi 13 anni fa

Risolto


Filter AC, pass DC
Input x is the sampled signal vector, may have both AC and DC components. Output vector y should not contain any AC component. ...

quasi 13 anni fa

Risolto


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...

quasi 13 anni fa

Risolto


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...

quasi 13 anni fa

Risolto


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

quasi 13 anni fa

Risolto


How to find the position of an element in a vector without using the find function
Write a function posX=findPosition(x,y) where x is a vector and y is the number that you are searching for. Examples: fin...

quasi 13 anni fa

Risolto


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.

quasi 13 anni fa

Risposto
Use abslolute colormap scale.
Hi. [x,y]=meshgrid(-7:.02:7); f=x.^2+y.^2; imshow(f,[23 47]) colormap(jet)

quasi 13 anni fa | 1

| accettato

Risolto


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

quasi 13 anni fa

Risposto
Logic issues for creating a random walk
Hi. plot([x1 x2],[y1,y2]) For all lines: xCor = rand(1,10) yCor = rand(1,10) Cor = [xCor; yCor] subplot(1,...

quasi 13 anni fa | 0

| accettato

Risolto


Find the numeric mean of the prime numbers in a matrix.
There will always be at least one prime in the matrix. Example: Input in = [ 8 3 5 9 ] Output out is 4...

quasi 13 anni fa

Risolto


Swap the first and last columns
Flip the outermost columns of matrix A, so that the first column becomes the last and the last column becomes the first. All oth...

quasi 13 anni fa

Risolto


Back and Forth Rows
Given a number n, create an n-by-n matrix in which the integers from 1 to n^2 wind back and forth along the rows as shown in the...

quasi 13 anni fa

Risolto


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

quasi 13 anni fa

Risposto
Variance and mean isn't calculated properly
Hi. Your noise is very large and the output image must be between 0 and 1, so the values greater than 1 became 1 and values les...

quasi 13 anni fa | 1

Risolto


Bottles of beer
Given an input number representing the number of bottles of beer on the wall, output how many are left if you take one down and ...

quasi 13 anni fa

Risolto


radius of a spherical planet
you just measured its surface area, that is the input.

quasi 13 anni fa

Risolto


Make one big string out of two smaller strings
If you have two small strings, like 'a' and 'b', return them put together like 'ab'. 'a' and 'b' => 'ab' For extra ...

quasi 13 anni fa

Risolto


Love triangles
Given a vector of lengths [a b c], determines whether a triangle with non-zero area (in two-dimensional Euclidean space, smarty!...

quasi 13 anni fa

Risolto


Remove DC
Input x is the sampled signal vector, may have both AC and DC components. Output y should not contain any DC component. Examp...

quasi 13 anni fa

Risolto


Program an exclusive OR operation with logical operators
Program an exclusive or operation *without* using the MATLAB function xor. Use logical operators like |, &, ~, ... instead. ...

quasi 13 anni fa

Risolto


Arrange Vector in descending order
If x=[0,3,4,2,1] then y=[4,3,2,1,0]

quasi 13 anni fa

Carica altro