Feeds
已解决
Find a Pythagorean triple
Given four different positive numbers, a, b, c and d, provided in increasing order: a < b < c < d, find if any three of them com...
21 hours 前
已解决
Triangle sequence
A sequence of triangles is constructed in the following way: 1) the first triangle is Pythagoras' 3-4-5 triangle 2) the second...
21 hours 前
已解决
Is this triangle right-angled?
Given three positive numbers a, b, c, where c is the largest number, return true if the triangle with sides a, b and c is right-...
21 hours 前
已解决
Side of an equilateral triangle
If an equilateral triangle has area A, then what is the length of each of its sides, x? Image courtesy of Wikipedia.
21 hours 前
已解决
Length of a short side
Calculate the length of the short side, a, of a right-angled triangle with hypotenuse of length c, and other short side of lengt...
21 hours 前
已解决
Reverse the vector
Reverse the vector elements. Example: Input x = [1,2,3,4,5,6,7,8,9] Output y = [9,8,7,6,5,4,3,2,1]
21 hours 前
已解决
Convert a Cell Array into an Array
Given a square cell array: x = {'01', '56'; '234', '789'}; return a single character array: y = '0123456789'
21 hours 前
已解决
Convert a numerical matrix into a cell array of strings
Given a numerical matrix, output a *cell array of string*. For example: if input = 1:3 output is {'1','2','3'} whic...
21 hours 前
已解决
Create a cell array out of a struct
Create a cell array out of a (single) struct with the fieldname in the first column and the value in the second column: in: ...
21 hours 前
已解决
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...
21 hours 前
已解决
Laws of motion 4
Given the initial velocity 'u', final velocity 'v' and acceleration 'a', find the distance travelled.
21 hours 前
已解决
Stress-Strain Properties - 5
Similar to the previous problem, materials may be characterized by their stiffness-to-weight ratio, which is the elastic modulus...
1 day 前
已解决
Stress-Strain Properties - 4
A common measure of the ability of a material to carry load per unit mass is termed strength-to-weight ratio and is calculated b...
1 day 前
已解决
Stress-Strain Properties - 3
A brittle material will not exhibit a yield point. In other words, the yield point and failure point coincide. In such cases, th...
1 day 前
已解决
Stress-Strain Properties - 2
The resilience of a material is its ability to resist permanent (or plastic) deformation. The resilience coincides with the elas...
1 day 前
已解决
Stress-Strain Properties - 1
This is the first in a series of problems regarding mechanics of materials, in particular, material properties drawn from stress...
1 day 前
已解决
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.
1 day 前
已解决
Magic is simple (for beginners)
Determine for a magic square of order n, the magic sum m. For example m=15 for a magic square of order 3.
1 day 前
已解决
Make a random, non-repeating vector.
This is a basic MATLAB operation. It is for instructional purposes. --- If you want to get a random permutation of integer...
1 day 前
已解决
Number of 1s in a binary string
Find the number of 1s in the given binary string. Example. If the input string is '1100101', the output is 4. If the input stri...
1 day 前
已解决
Return the first and last characters of a character array
Return the first and last character of a string, concatenated together. If there is only one character in the string, the functi...
1 day 前
已解决
Create times-tables
At one time or another, we all had to memorize boring times tables. 5 times 5 is 25. 5 times 6 is 30. 12 times 12 is way more th...
1 day 前


