Find max prime number
Given integer number n. Find the max prime number (mpn) that smaller than or equal to n.
Example:
n = 10
--> mpn = 7
2 years 前
已解决
Resistance of a light bulb
The current through two identical light bulbs connected in series is C Amperes. The total voltage across both bulbs is V Volts....
Project Euler: Problem 10, Sum of Primes
The sum of the primes below 10 is 2 + 3 + 5 + 7 = 17.
Find the sum of all the primes below the input, N.
Thank you <http:/...
Sum of first n positive integers
Given n, find the sum of first n positive integers
Example: If n=10, then x=1,2,3,4,5,6,7,8,9,10. The sum of these terms is 55
First N Perfect Squares
*Description*
Return the first N perfect squares
*Example*
input = 4;
output = [ 1 4 9 16 ];
2 years 前
已解决
Create a square matrix of multiples
Given an input, N, output a matrix N x N with each row containing multiples of the first element of each row.
This also applies...
2 years 前
已解决
Area-01
Given the radius of the circle inscribed in a square, find the area that is not bounded by the circle but inside the square.
...
Linear Motion 5
A robot moving down an incline for 3 seconds undergoes a uniform acceleration of a ft/s2. If the robot has an initial velocity o...
2 years 前
已解决
Travel time
Calculate the time (in hours) it takes a car traveling at a given uniform speed of s km/hour to travel a distance of d km. For i...
2 years 前
已解决
Compound Interest : Future Value
Theorem : Compound Interest
where,
F : Future value at the end of n periods
P : Present value
r : Annual nominal rate
n :...
2 years 前
已解决
Octoberfest festival
A group of students decided to visit Octoberfest festival. First they ordered one beer, then after half-hour they taken one more...
2 years 前
已解决
Volume Pillar
Calculate the volume of a pillar with radius l and heigth ar.