已解决


Non trivial identities - flipping
Return x by flipping it.

6 years 前

已解决


Find the diagonal of the square of side L
You are given a square of side length L, find D the length of its diagonal.

6 years 前

已解决


Area of polygon
Given the vertices in vectors X,Y, return the area of the polygon they define.

6 years 前

已解决


Polynomial evaluation
Compute the value of a polynomial of degree n with coeffcients in vector a, at value x. p(x)=a(1)+a(2)x+a(3)x^2+...+a(n+1)x...

6 years 前

已解决


Number of even divisors of a given number
Given a Number n, return the number of its even divisors without listing them. example: n=14 ; EvenDivisors={2,14} ; y=2 ...

6 years 前

已解决


The number of trailing zero digit of a factorial
For given positive integer n, take factorial of that number. How many trailing zeros does it have? Example: factorial(11) = 3...

6 years 前

已解决


The last non-zero digit of a factorial
For given positive integer n, what is the last non-zero digit of n!? Example: factorial(11) = 39916800 Last non-zero d...

6 years 前

问题


Investigate the frequency of last digits of prime numbers
The last digit of a prime number greater than 5 can be 1, 3, 7, or 9. If the primes are distributed randomly, then these digits ...

6 years 前 | 4 | 28 个解题者

已解决


Find my secret function II
If give my function a x value it will give me a y value, so find the secret of it: Examples: input x=23 ---- >>> output y=1...

6 years 前

已解决


Find the average of a random sequance
Write a function that generates random integers within a loop, and calculates the mean of the positive numbers only. At each ...

6 years 前

已解决


Separate even from odd numbers in a vector - with a loop
*Using a loop*, rearrange a vector of integers such that the odd numbers appear at the beginning, and even numbers at the end. T...

6 years 前

已解决


Sudoku square
We have a small Sudoku square, but one number is missing. x = [ 1 5 4 8 6 3 0 9 7 ] Make a function, wher...

6 years 前

已解决


Sum the rows
Sum the rows of the given matrix. Example x = [ 1 2 3 4 ] y = [ 3 7 ]

6 years 前

已解决


grazing cows
Here is a fun problem I encountered in high school. Two cows are grazing in an enclosed square-shaped field of side length s ...

6 years 前

已解决


Twins in a Window
<http://en.wikipedia.org/wiki/Twin_primes Twin primes> are prime numbers that differ by 2, such as [11,13] or [41,43]. Write a f...

6 years 前

已解决


Check if integer is a prime number
Check if integer i is a prime number. Returns logical true '1' if it is.

6 years 前

已解决


prime to each other
Given two integers n1, n2 greater than 1, find out if they have common divisors or are prime to each other. Return "true" if the...

6 years 前

已解决


*Prime number check 2 (in construction)
Another way to see if a number is prime is to count the number of factors. For example, the number 4 has 2 factors, [ 2 4 ]...

6 years 前

已解决


Given a number N, find the smallest prime P>N
Given a number N, find the smallest prime P greater than N. For example: If N=10 then P=11. If N=13 then P=17.

6 years 前

已解决


Find the nearest prime
Given a positive integer 'n', the task is to find a prime number greater than or equal to 'n'. Example 1 If given 'n' is ...

6 years 前

已解决


Evaluate Polynomial
Given a polynomial equation coefficients in a vector p, you have to return its value at x. Example: For inputs p and x ...

6 years 前

已解决


Polynomial Multiplication
Multiply two polynomial equation.Given polynomial coefficients a and b.

6 years 前

已解决


Hilbert numbers
Given a positive integer, n, return h as follows: 1. If n is not a <https://en.wikipedia.org/wiki/Hilbert_number Hilbert numb...

6 years 前

已解决


Check prime numbers
Let x, return 1 if x is a prime number, 0 otherwise e.g x = 7, return y =1; x = 6 return y = 0;

6 years 前

已解决


Prime number removal
remove all prime numbers from the input e.g. input = 1 2 3 4 5 6 7 8 9 10 11 12 ...

6 years 前

已解决


Ugly numbers - 01
Ugly numbers are those whose prime factors are 2, 3 or 5. find the nth ugly number.

6 years 前

已解决


GPA
Math's credit is 5 and you got x | Physics's credit 7 and you got y what is your GPA

6 years 前

已解决


Nth root of a number
Given an input and a number N, find the Nth root of the number(s)

6 years 前

已解决


Check if there are white spaces in the input string
If there are white spaces in the input string, output=1 else 0

6 years 前

已解决


ASCII sum of phrases
Find the sum of the numeric equivalents of all characters entered in a phrase. For example: for the phrase 'My name is test', th...

6 years 前

加载更多