A résolu


Find prime number couples
Given a vector a, which will always contain at least one pair of prime numbers couple, return a matrix called 'couple' in which ...

environ 2 mois il y a

A résolu


Tricky timing
Write a function that takes between 0.5 seconds and 0.6 seconds to run.

environ 2 mois il y a

A résolu


Split array into pieces according to corresponding array
An array x of length n has values 1...m with each value appearing at least once. The values are sorted (n>=m). A second...

environ 2 mois il y a

A résolu


Find smallest integer type to accommodate your number
MATLAB supports 1-, 2-, 4-, and 8-byte storage for integer data. Find the smallest integer type to accomodate a scalar integer. ...

environ 2 mois il y a

A résolu


Solve for factorial of X
It gives you the number x, and set y equal to x factorial. Ex. There are 52 cards in a deck, each specific order of all 52 car...

environ 2 mois il y a

A résolu


Monty Python and the Holy Grail: Crossing the Bridge of Death
To cross the Bridge of Death, your function must return the numerical value for the airspeed velocity of an unladen swallow

environ 2 mois il y a

A résolu


Pascal's Triangle
Create a matrix of size N x N containing a Pascal's Triangle that starts from the upper left corner according to the test cases ...

environ 2 mois il y a

A résolu


Easy Sequences 2: Trigonometric function with integral input and output
The function 'F', defined as: , will always return an integer if the input is a natural number (in radian...

2 mois il y a

A résolu


Find longest run
Write a function longest_run that takes as input an array of 0's and 1's and outputs the length and index of the longest consecu...

2 mois il y a

A résolu


Sum of Elements of a matrix
It sums the elemets of a 2x2 matrix

2 mois il y a

A résolu


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

2 mois il y a

A résolu


Create formatted value string Cell array of a vector
This Challenge is to create a cell array that contains strings of vector components in a given format. c=vector2formattedstri...

2 mois il y a

A résolu


Write a string
The answer should be a string that is the value: "I like apples!" (Ignore the quotation marks, just write what is inside the ...

2 mois il y a

A résolu


PEMDAS

2 mois il y a

A résolu


Point on a line
Find the slope of the straight line between the points a and b. Then find y at x=20.

2 mois il y a

A résolu


Squares
Find the square of x.

2 mois il y a

A résolu


Division
Divide a by b.

2 mois il y a

A résolu


Subtraction
Subtract a from b.

2 mois il y a

A résolu


Multiplication
Multiply a and b.

2 mois il y a

A résolu


Addition
Add together the values of a and b.

2 mois il y a

A résolu


Count the Even Digits in a Number
Given a positive integer n, write a function that returns how many digits of n are even. Even digits are: 0, 2, 4, 6, 8

2 mois il y a

A résolu


Invert a 3D rotation matrix
Given a 3D rotation matrix, belonging to the matrix group SO(3), compute its inverse without using the functions inv() or pinv()...

3 mois il y a

A résolu


Sum of even numbers in a vector
Write a function that takes a vector of numbers and returns the sum of all the even numbers in the vector.

3 mois il y a

A résolu


Linearly Spaced Array
Create a linearly spaced array from 0 to x consisting of y elements.

3 mois il y a

A résolu


Minimum number of crossings in a complete graph
This problem is related to problem 58384. A complete graph may be drawn in different ways, such that the number of line crossin...

3 mois il y a

A résolu


Addition II
find a+b+c+d

3 mois il y a

A résolu


Breaking up a chocolate bar
You've got a chocolate bar of size , and you want to break it up into bite-sized () pieces. How many steps are required to do th...

3 mois il y a

A résolu


X-intercepts of a quadratic.
Find the y value of the quadratic of the function at a point x.

3 mois il y a

A résolu


Repeat string n times
You will be provided a string (s = 'string1_') a starting point (num1 = 6) (always bigger than or equal to zero) and n (n = 3)...

3 mois il y a

A résolu


Return the Square of a Number
Write a function that takes a single numeric input x and returns its square. That is, given x, your function should output x^2....

3 mois il y a

Charger plus