문제를 풀었습니다


union without repitition
Let a = [9 9 9 9 9 9 8 8 8 8 7 7 7 6 6 6 5 5 4 2 1] b = [1 1 1 3 3 3 3 3 4 4 4 4 4 10 10 10] Output should be [9 8...

5년 초과 전

문제를 풀었습니다


Feeling lucky?
Guess which number Cody is thinking (1 to 10)? (This is a game of luck more than skill. Good luck!)

5년 초과 전

문제를 풀었습니다


Powers Of
Fill the vector with powers of 2, so that vector(1) is 2^1, vector(2) is 2^2, etc. Stop with vector(10). Complete the function ...

5년 초과 전

문제를 풀었습니다


imaginary results
Return the value of the imaginary number i to the power of input argument n.

5년 초과 전

문제를 풀었습니다


Is It a Palindrome?
Given a string or array, determine if it is a palindrome.

5년 초과 전

문제를 풀었습니다


Perimeters/Circumference
Given an array. Determine whether the perimeter is of a circle, triangle or square. Then calculate the perimeter.

5년 초과 전

문제를 풀었습니다


Reshape a Vector
Write a function that accept three inputs. The first one is a row vector S. The second and third arguments are m and n which de...

5년 초과 전

문제를 풀었습니다


Determine the Anti-diagonal of a Magic Square
Determine the anti-diagonal (crossing from top right to lower left) of a magic square of size n. Examples If n = 3 y =...

5년 초과 전

문제를 풀었습니다


Union of two set decreasing order
Union of two set decreasing order Say, x=[1 2 5] and y=[5 7 8] then answer must be [8 7 5 2 1]

5년 초과 전

문제를 풀었습니다


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

5년 초과 전

문제를 풀었습니다


Generate vector according to sign of vector
Generate vector according to sign of vector Example: If A=[-2 0 5] then output must be[-1 0 1] meaning that for negative n...

5년 초과 전

문제를 풀었습니다


Decide whether determinant is zero.
Given a 3 x 3 matrix, find the determinant. Let y = true if the determinant is zero, and let y = false if the determinant is no...

5년 초과 전

문제를 풀었습니다


Moving average (variable kernel length)
Find the moving average in a vector. The kernel length is a variable. For example x = 1:10 kernel_length = 2 would r...

5년 초과 전

문제를 풀었습니다


Remove All elements less than 5
Given an input vector x, remove all elements of x less than 5 . Example: Input x = [ 1 2 5 7 3 ] Output y is [ 5 7 ...

5년 초과 전

문제를 풀었습니다


modulus of a number
find the modulus of a given number

5년 초과 전

문제를 풀었습니다


Values in Array
How many values are in the array

5년 초과 전

문제를 풀었습니다


Change the first and last diagonal element of the identity matrix to zero
Starting with the identity matrix, change first and last diagonal element to zero. Example If n=5 A = 0 0 ...

5년 초과 전

문제를 풀었습니다


Golden ratio
Calculate the golden ratio. Hint: phi^2 = phi + 1.

5년 초과 전

문제를 풀었습니다


Remove entire row and column in the matrix containing the input values
Remove the entire row and column from the matrix containing specific values. The specified value can be a scalar or a vector. Fo...

5년 초과 전

문제를 풀었습니다


Finding peaks
Find the peak values in the signal. The peak value is defined as the local maxima. For example, x= [1 12 3 2 7 0 3 1 19 7]; ...

5년 초과 전

문제를 풀었습니다


metre to feet converter
The idea is to make a converter, which exchange meters to feets. We use a factor of 1m = 3.281*1f. so 3m are equals to 9.843 m...

5년 초과 전

문제를 풀었습니다


What's the missing interior angle?
I'm talking about polygons... The sum of the interior angles of a triangle is 180 degrees. The sum of the interior angles of a...

5년 초과 전

문제를 풀었습니다


Make roundn function
Make roundn function using round. x=0.55555 y=function(x,1) y=1 y=function(x,2) y=0.6 y=function(x,3) ...

5년 초과 전

문제를 풀었습니다


Radians to Degrees
Convert radians to degrees.

5년 초과 전

문제를 풀었습니다


Create an m x n array consisting only of an input value.
Create an array with m rows and n columns wherein all entries are assigned the input value x.

5년 초과 전

문제를 풀었습니다


Where is she?
Given the numbers 12, 3, 6, 9 Tell where the girl is located. That is: Look to your 3 o'clock = look right Example ...

5년 초과 전

문제를 풀었습니다


find the relation...
if given input is 1, output is 4. if input is 55, output is 3136.

5년 초과 전

문제를 풀었습니다


Find the number that has most primes those less than it
Given an vector x of integer numbers, find the element of x that has the most primes less than it.

5년 초과 전

문제를 풀었습니다


BaeIsAlwaysRight
Output yes whatever bae says

5년 초과 전

문제를 풀었습니다


row removal
Remove the nth row from input matrix M and return the resulting matrix in output N.

5년 초과 전

더 보기