Gelöst


The rabbit problem
Someone discovered that rabbits reproduce at the rate of fibonnaci so you just input the number and it will print the fibonnaci ...

fast 10 Jahre vor

Gelöst


Sum of series I
What is the sum of the following sequence: Σ(2k-1) for k=1...n for different n?

fast 10 Jahre vor

Gelöst


Find out sum of prime number till given number
Find out sum of prime number till given number Example, if number is 10, then answer must be 17.

fast 10 Jahre vor

Gelöst


Find the area of a rectangle if length of the diagonal is given.
if length of a diagnonal in rectangle is 5. Its area is 12.

fast 10 Jahre vor

Gelöst


Vector creation
Create a vector using square brackets going from 1 to the given value x in steps on 1. Hint: use increment.

fast 10 Jahre vor

Gelöst


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

fast 10 Jahre vor

Gelöst


Small Riddle
Mr. Smith has two children. If the older child is a boy, what are the odds that the other child is also a boy?

fast 10 Jahre vor

Gelöst


Solve Linear equations
Solve Linear equations Example: x+y=2 and x+2y=3, then x and y equal to 1.

fast 10 Jahre vor

Gelöst


Time Expansion
How can you slow down any discrete-time signal? Example Input original signal x. x = [1 2 3 -1 -2 -5 -4] We want t...

fast 10 Jahre vor

Gelöst


Matlab Basics II - Unit Conversion
Write a function that converts Kg to lbs, returns the answer to the nearest 1/100th of a pound

fast 10 Jahre vor

Gelöst


Rounding off numbers to n decimals
Inspired by a mistake in one of the problems I created, I created this problem where you have to round off a floating point numb...

fast 10 Jahre vor

Gelöst


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

fast 10 Jahre vor

Gelöst


Perimeter
Given a sequence of points forming a closed path (first and last points are coincident) return the perimeter value. For example...

fast 10 Jahre vor

Gelöst


Summation of array
Given an array, Find the sum of all of the elements in it Examples: Input x = [1 2 3 5; 4 5 6 7]; Output y is 33

fast 10 Jahre vor

Gelöst


Find Out sum of principal diagonal element of given matrix
Find out sum of principal diagonal element of given matrix If A=[1 0 0; 0 1 0;0 0 1], then answer must be 3.

fast 10 Jahre vor

Gelöst


Television Screen Dimensions
Given a width to height ratio of a TV screen given as _w_ and _h_ as well as the diagonal length of the television _l_, return t...

fast 10 Jahre vor

Gelöst


Sum of the Multiplication of Vectors
Given the vectors x and y as input, multiply the vectors and return the summation of its elements. Example: x = [1 2 ...

fast 10 Jahre vor

Gelöst


Find the elements of a matrix according to a defined property.
From A = [5,2,3] and B = [1,2,3,4,5,6,7,8,9,10] produce a vector C where : C(1) is the sum of the first A(1) elements of B, ...

fast 10 Jahre vor

Gelöst


Pascal's Matrix
Given an integer n &ge; 0, generate the ( _n_+1) &times; ( _n_+1) lower triangular <http://en.wikipedia.org/wiki/Pascal_matrix P...

fast 10 Jahre vor

Gelöst


Box!
Given a box, find the volume of the cube. With each side = a.

fast 10 Jahre vor

Gelöst


Square wave average calculation
Given its peak and duty cycle, calculate avg value of square wave

fast 10 Jahre vor

Gelöst


UICBioE240 problem 1.6
Find the tangent line of a right triangle given the two of the sides. So if A = [1 1] B = sqrt(2)

fast 10 Jahre vor

Gelöst


Power supply: 230V to 115V
The problem is simple: we have a wall outlet which supplies 230V and an apparatus that requires 115V. Software is always chea...

fast 10 Jahre vor

Gelöst


Polynomial division
Divide a polynomial u by polynomial v and return the quotients only. Example: u = x^4+3*x^3+5*x+3 v = x^2+1 Answer: ...

fast 10 Jahre vor

Gelöst


Einsteinium-253 decay
Radioactive Einsteinium-253 has a half-life of 1,768,608 seconds. Given 1000mg of Einsteinium-253 at t=0 days, how much is lef...

fast 10 Jahre vor

Gelöst


Upper triangular matrix
Create a function to retrieve the upper triangular matrix of a matrix (without using tril). The matrix will always be square. ...

fast 10 Jahre vor

Gelöst


Find nth maximum
Find nth maximum in a vector of integer numbers. Return NaN if no such number exists. x = [2 6 4 9 -10 3 1 5 -10]; So ...

fast 10 Jahre vor

Gelöst


Writing a recursive math function
Complete the recursive function RaiseToPower(). Ex: If userBase is 2 and userExponent is 4, then raisedValue is assigned wit...

fast 10 Jahre vor

Gelöst


Function call: Kilometers to miles
Assign rateMPH with the corresponding rate in miles per hour given a user defined rateKPH, which is a rate in kilometers per hou...

fast 10 Jahre vor

Gelöst


Generate a vector like 1,2,2,3,3,3,4,4,4,4
Generate a vector like 1,2,2,3,3,3,4,4,4,4 So if n = 3, then return [1 2 2 3 3 3] And if n = 5, then return [1 2 2...

fast 10 Jahre vor

Mehr laden