Calculating Ring Area
In two-dimensional space, a ring can be constructed by using two concentric circles. Determine the area of a ring which has r1 ...
約4年 前
解決済み
Solve the Sudoku Row
*Description*
A simple yet tedious task occurs near the end of most Sudoku-solving algorithms, computerized or manual. The ta...
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:
...
Determine given vector is even or odd
Find the numbers of the input vector is odd or even then replace even with 1 and odd with 0
Example
x = [ 3 3 4 6 1]
...
約4年 前
解決済み
Multiply a column by a row
* Given a column vector C and and a row vector R.
* Output a matrix M.
* Every column of M equals to C multiplied by correspon...
CONVERT TAN TO SIN
In a right angle triangle ABC given the tan(A) then find sin(A)
For example tan(A)=3/4 then sin(A)=3/5
約4年 前
解決済み
Replace multiples of 5 with NaN
It is required to replace all values in a vector that are multiples of 5 with NaN.
Example:
input: x = [1 2 5 12 10 7]
...
約4年 前
解決済み
Square the input
Given a scalar or vector x, return the square of each element.
Example
x = [7 2]
answer = [49 4]
Let's make puddings !
We will make puddings with eggs, milk and sugar.
To make one pudding, we need one egg, 140(cc) of milk, 15 (g) of sugar.
Now W...
約4年 前
解決済み
what's my tax amount this year ?
given an annual salary x and a tax rate i calculate the amount that you have to pay.Example
x = 70000;
i=.10
y_correc...
Divisible by 5
Pursuant to the <http://www.mathworks.com/matlabcentral/cody/problems/42404-divisible-by-2 first problem> in this series, this o...
約4年 前
解決済み
Divisible by 2
This is the first problem in a set of "divisible by x" problems. You will be provided a number as a string and the function you ...
約4年 前
解決済み
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:
* ...
約4年 前
解決済み
Square a Number
Given an input x, return y, which is equal to the square of x.
約4年 前
解決済み
Add two numbers
Calculate the sum of two numbers.
Example
input = [2 3]
output = 5