문제를 풀었습니다


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

8년 초과 전

문제를 풀었습니다


Return the largest number that is adjacent to a zero
This example comes from Steve Eddins' blog: <http://blogs.mathworks.com/steve/2009/05/27/learning-lessons-from-a-one-liner/ Lear...

8년 초과 전

문제를 풀었습니다


Which values occur exactly three times?
Return a list of all values (sorted smallest to largest) that appear exactly three times in the input vector x. So if x = [1 2...

8년 초과 전

문제를 풀었습니다


Find the minimal value in N*N Matrix
Suppose that we have N by N matrix, we try to find the minimal value in that matrix. examples: Input A=[1 2 3 5 6;52 58 56 45...

8년 초과 전

문제를 풀었습니다


Get derivarive of polynomial given as vector array.
Get derivarive of polynomial given as vector array. Example p=[ 1 2 0 5 0 3 ]; result=[ 5 8 0 10 ...

8년 초과 전

문제를 풀었습니다


Logarithm with base other than 'e'
The standard log() function in Matlab returns the natural logarithm (base equal to Euler's constant). Compute the logarithm for ...

8년 초과 전

문제를 풀었습니다


Calculate solution of given polynomial
For example, y=function([3 -2 -4]) In here, input vector indicate 3*x^2-2*x-4, y is solution of former equation. y=[1.5...

8년 초과 전

문제를 풀었습니다


Add the positive numbers
Add only the positive numbers of x example: x = [-2 -1 0 1 2 3] the positive numbers are: 1 2 3, so their sum is 6

8년 초과 전

문제를 풀었습니다


Find the sum of the negative elements under the main diagonal.
Example Input A=[1 2; -3 0] Output -3

8년 초과 전

문제를 풀었습니다


Find product of eigenvalues of n*n magic matrix.
Find product of eigenvalues of n*n magic matrix. Example n=3 Matrix= [ 8 1 6; 3 5 7; 4 ...

8년 초과 전

문제를 풀었습니다


Approximation of Pi
Pi (divided by 4) can be approximated by the following infinite series: pi/4 = 1 - 1/3 + 1/5 - 1/7 + ... For a given numbe...

8년 초과 전

문제를 풀었습니다


Does this dress make me look fat
For the input string "Does xyz make me look fat" output the string "No, xyz does not make you look fat"

8년 초과 전

문제를 풀었습니다


How many bottles
Sometimes if you buy a drink in a glass bottle you can return that bottle and get some money back. Let's assume we have "x" amo...

8년 초과 전

문제를 풀었습니다


Detect pair of equal values in a Matrix
A 2D matrix of 2 rows and N columns with random integer numbers. A = [3 1 2 4 6 6 7; 7 3 2 1 5 2 4] ...

8년 초과 전

문제를 풀었습니다


determine the sum of the squares
if x = 4, the solution will be: y = 1^2+2^2+3^2+4^2=1+4+9+16 = 30.

8년 초과 전

문제를 풀었습니다


Save variables
a=[1] Save variable a that is located in workspace into current folder. File name should be 'a.mat'

8년 초과 전

문제를 풀었습니다


Normalize by maximum
Subtract the maximum value in a column from the corresponding columns of a matrix.

8년 초과 전

문제를 풀었습니다


Find the Area of a Polygon
Consider 2-D geometry and assume that the points are given in form of rows of a matrix. Find the area of polygon enclosed by the...

8년 초과 전

문제를 풀었습니다


Beat the test suite if you can :)
Solve this problem based on clues in the test suite.

8년 초과 전

문제를 풀었습니다


Vector Multiplication
Vector Multiplication of three matrix as shown in test cases.

8년 초과 전

문제를 풀었습니다


Height of a right-angled triangle
Given numbers a, b and c, find the height of the right angled triangle with sides a and b and hypotenuse c, for the base c. If a...

8년 초과 전

문제를 풀었습니다


Sum the rows
Sum the rows of the given matrix. Example x = [ 1 2 3 4 ] y = [ 3 7 ]

8년 초과 전

문제를 풀었습니다


Baseball Pitch Question
One pitcher made 10 practice pitches during his warm up before the game. Using the given information, create a vector matrix an...

8년 초과 전

문제를 풀었습니다


Compare two strings.
Compare two strings, whether they are equal or not.

8년 초과 전

문제를 풀었습니다


"Find out the best cricket"
This is how I originally read Problem 2013, so let's just go with it. Give me the first and last name of the best cricket, rega...

8년 초과 전

문제를 풀었습니다


vector to string
Determine what the ASCII characters spell out. Example: input = [ 72 73 71 72] output = 'HIGH'

8년 초과 전

문제를 풀었습니다


Unit conversion
Convert x degree Celsius to y degree Fahrenheit.

8년 초과 전

문제를 풀었습니다


MATLAB Basic: rounding II
Do rounding nearest integer. Example: -8.8, answer -9 +8.1 answer 8 +8.50 answer 9

8년 초과 전

문제를 풀었습니다


A quadrant matrix
Write a function called quadrants that takes as its input argument a scalar integer named n. The function returns Q, a 2n-by-2n ...

8년 초과 전

문제를 풀었습니다


Cannon Ball
Given g (acceleration due to gravity) and desired altitude x, find the minimum ground velocity of a cannon ball to reach x.

8년 초과 전

더 보기