A résolu


Calculate the nth Fibonacci number USING 'Golden Ratio' concept
f = [1 1 2 3 5 8 13 ...] If n=6, f(6)=8

presque 10 ans il y a

A résolu


CARDS PROBLEM
Read my mind and tell me the card number that I have now in my hands.

presque 10 ans il y a

A résolu


Weave two vectors into one
Weave the two given vectors into one as shown below. Example: If a = [1 1 1] b = [0 0 0] then y = [1 0 1 0 ...

presque 10 ans il y a

A résolu


Solving a quadratic equation
Given a, b ​​and c, Return the solution of the following quadratic equation: a*x^2 + b*x + c = 0.

presque 10 ans il y a

A résolu


Largest Prime Number
Given a matrix X, find the largest prime number in X.

presque 10 ans il y a

A résolu


Concatenate strings
concatenate a variable number of input strings to produce one outputstring

presque 10 ans il y a

A résolu


Convert a vector into numbers
Suppose a vector x = [ 1 2 4 7] is given. You have to convert this vector into string number y = '1247'. Examples x = [ 1...

presque 10 ans il y a

A résolu


Speed of car
Calculate the Speed of car given its Distance travelled and time taken in x and y respectively

presque 10 ans il y a

A résolu


Output a vector which is table of 9
Output a vector which is table of 9

presque 10 ans il y a

A résolu


Convert yards to feet
The goal of this script is to convert a value given in yards to feet.

presque 10 ans il y a

A résolu


Sum the squares of numbers from 1 to n
For a given value of n return the sum of square of numbers from 1 to n. Example For n = 2 then sum of squares = 5 (1^2 + ...

presque 10 ans il y a

A résolu


Calculate square and cube of number
Calculate square and cube of number x

presque 10 ans il y a

A résolu


find the surface area of a cube
given cube side length x, find the surface area of the cube, set it equal to y

presque 10 ans il y a

A résolu


Kinetic Energy
Given the mass m and velocity v of an object, determine its <http://en.wikipedia.org/wiki/Kinetic_energy kinetic energy>.

presque 10 ans il y a

A résolu


Square the input
Given a scalar or vector x, return the square of each element. Example x = [7 2] answer = [49 4]

presque 10 ans il y a

A résolu


Create an anti-identity matrix
Create an anti-identity matrix of given dimension. Examples n = 2 A = [0 1; 1 0] n = 3 A = [0 0 1; 0 1 0; 1 0 0...

presque 10 ans il y a

A résolu


Find out value of sine given by degree.
Find out value of sine given by degree. If theta=30, it's value must be 0.5.

presque 10 ans il y a

A résolu


Sort complex numbers into complex conjugate pairs
Sort complex numbers into complex conjugate pairs. Example: Input x = [3-6i -1-4i -1+4i 3+6i] Sorted output = [-1 - ...

presque 10 ans il y a

A résolu


Convert Two Character String into a Binary Vector
Given a string "XOXXO" convert it into a binary vector. [1 0 1 1 0] Paul Berglund implemented an optimal method in <http://ww...

presque 10 ans il y a

A résolu


Create an n-by-n null matrix and fill with ones certain positions
The positions will be indicated by a z-by-2 matrix. Each row in this z-by-2 matrix will have the row and column in which a 1 has...

presque 10 ans il y a

A résolu


Fibonacci-Sum of Squares
Given the Fibonacci sequence defined by the following recursive relation, * F_n = F_(n-1) + F_(n-2) * where F_0 = 0 and F_1 ...

presque 10 ans il y a

A résolu


Narcissistic problem
How many likes has this problem?

presque 10 ans il y a

A résolu


Make a Star Pyramid
Create a star pyramid. First line will have 1 star, second will have two stars and so on... a basic program which is easily done...

presque 10 ans il y a

A résolu


Sum the real and imaginary parts of a complex number
Sum the real and imaginary parts of a complex number. Example c = 1+2i has the solution 1 + 2 = 3

presque 10 ans il y a

A résolu


Find maximum value of a curve
Two vectors shall be already defined: - Input vector x (e.g. x = 0:1:10) - Result vector y (e.g. y = sin(x)) Create a n...

presque 10 ans il y a

A résolu


UICBioE240 2.1
This will be useful later in the course, in conjunction to clc and clear all, what is the command to close all figure windows th...

presque 10 ans il y a

A résolu


Replace every 3rd element in a vector with 4
x is a vector of undetermined length You are to replace every 3rd element with the number 4, example: x = [11 23 34 43 2 3...

presque 10 ans il y a

A résolu


Help the Patriots get to the Super Bowl
Given a football by the Patriots, return it to them with 2 psi less air in it. (The original psi is passed as a number to the...

presque 10 ans il y a

A résolu


Forward difference approximation: Car temperatures
Column arrays measuredTemperature and sampleTime contain engine temperature measurement samples, and the time each sample was co...

presque 10 ans il y a

A résolu


Find the maximum two numbers of every column of a matrix
Find the maximum two numbers of every column of a matrix. Example: If we input a matrix A = [ 1 2 4 6 0 3 ...

presque 10 ans il y a

Charger plus