Risolto


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

circa un mese fa

Risolto


Area of a triangle
A triangle is given with base *'b'* ,vertical hight *'h'* . then find it's area.

circa un mese fa

Risolto


Back to basics 1 - Saving
Covering some basic topics I haven't seen elsewhere on Cody. Given an input variable 'x', save it to disk in a file named 'co...

circa un mese fa

Risolto


Most nonzero elements in row
Given the matrix a, return the index r of the row with the most nonzero elements. Assume there will always be exactly one row th...

circa un mese fa

Risolto


kmph to mps
convert kilometer per hour to meter per second

circa un mese fa

Risolto


Vectors counting by 2
Create a vector numbers from 7 to 15 in increments of 2

circa un mese fa

Risolto


Find the hypotenuse
Given a and b (the two sides of a right-triangle), find c, the hypotenuse.

circa un mese fa

Risolto


Try 1.5.4: Celsius to Fahrenheit
Write a program to convert an input given in Celsius to Fahrenheit. Examples: Input celsiusValue = 100 Output fahrValu...

circa un mese fa

Risolto


Bullseye Matrix
Given n (always odd), return output a that has concentric rings of the numbers 1 through (n+1)/2 around the center point. Exampl...

circa un mese fa

Risolto


Is A the inverse of B?
Given a matrix A and a matrix B, is A the inverse of B? >>A=[2,4;3,5]; >>B=[-2.5,2;1.5,-1]; >>isInverse...

circa un mese fa

Risolto


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

circa un mese fa

Risolto


Reverse a string
Reverse the given string. Example input = 'reverse' output = 'esrever'

circa un mese fa

Risolto


Finding perimeter of a rectangle
A rectangle has a length of x centimeters and a width of w centimeters. Find the perimeter.

circa un mese fa

Risolto


Equal to their cube
Tell me three real numbers that are equal to their cubes?

circa un mese fa

Risolto


Tell me the slope
Tell me the slope, given a vector with horizontal run first and vertical rise next. Example input: x = [10 2];

circa un mese fa

Risolto


Area of an Isoceles Triangle
An isosceles triangle has equal sides of length x and a base of length y. Find the area, A, of the triangle. <<https://imgur...

circa un mese fa

Risolto


Side of a rhombus
If a rhombus has diagonals of length x and x+1, then what is the length of its side, y? <<https://imgur.com/x6hT6mm.png>> ...

circa un mese fa

Risolto


Find out magnitude of vector
Find out magnitude of vector. Say x=[1 2 3], then answer must sqrt(1^2+2^2+3^2) Please don't use sum function. If you l...

circa un mese fa

Risolto


Element by element multiplication of two vectors
Given two input vectors, return the element-by-element product. Example A = [1 2 3] B = [7 3 1] The answer should be...

circa un mese fa

Risolto


Basics: 'Find the eigenvalues of given matrix
Find the eigenvalues y for a given matrix x.

circa un mese fa

Risolto


Laws of motion 4
Given the initial velocity 'u', final velocity 'v' and acceleration 'a', find the distance travelled.

circa un mese 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.

circa un mese fa

Risolto


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.

circa un mese fa

Risolto


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

circa un mese fa

Risolto


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

circa un mese fa

Risolto


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

circa un mese fa

Risolto


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

circa un mese fa

Risolto


Getting the indices from a vector
This is a basic MATLAB operation. It is for instructional purposes. --- You may already know how to find the logical indices o...

circa un mese fa

Risolto


Determine whether a vector is monotonically increasing
Return true if the elements of the input vector increase monotonically (i.e. each element is larger than the previous). Return f...

circa un mese fa

Risolto


Check if number exists in vector
Return 1 if number a exists in vector b otherwise return 0. a = 3; b = [1,2,4]; Returns 0. a = 3; b = [1,2,3]; Returns 1.

circa un mese fa

Carica altro