You are on page 1of 3

Questions (basically for 1st years beginner/intermediate level) :1.

Take an input file of 3000 random dice throws, calculate how many doubles were rolled.
It is known for this problem that each die are fair in that they are labeled with the numbers 1,2,3,4,5 and 6. It is also known that a double is defined as both dice showing the same number after they are rolled. note : each throw has 3 die rolled together.. take only 2 die having the same number

2. In math, a Cartesian plane is most commonly known as an X,Y graph. This graph has 4 quadrants. Here is the listing for the Quadrants and the relation to the (x,y) pair:
Quad. I: Quad. II: Quad. III: Quad. IV: (x, y) (-x, y) (-x, -y) (x, -y)

The pair (3, -5) lies in Quardant IV. The pair (3, 3) lies in Quard. I

generate a data (array , file , linked list , stack anything) of 1000 randomly generated x, y how many of those pairs lie in Quadrant III?

3. sum of squares of all the numbers which does not have a perfect root (limit till 10,000) eg : 12 not a perfect root take 12*12 and add it to sum 4. Generate Pascals triangle and find the sum of each row and column and display it in a 2d array or stack as far as your convenience 5. In a projectile motion the distance travelled by the figure is given by

So let me push a body with a Velocity V at an angle 0 (theeta) now if the experiment is carried in a platform that after the objects hits the ground then it is returned back with a force square root to it and but in the same angle then calculate how many times the projectile distance function will be called and the total distance traveled by it.. BONUS : do it using recursion

6. Mr. Red has 50 red discs; Mr. Blue has 75 blue discs and Mr. Green has 100 green discs.
Mr. Red's discs contain the first 50 prime numbers. Mr. Blue's discs contain the first 75 Fibonacci numbers and Mr. Green's discs contain the first 100 triangle numbers. What then is the probability that when each person randomly draws a disc, each disc will be an odd number and Mr. Red's discs will end with a 7? Enter the number in the form 0.XXXX rounded to the nearest 10,000th where X is the digits of the answer. note : A triangle number is computed with the following formula: T(n) = n(n+1)/2 7. A hexagonal number is computed as follows using the formula: H(n) = n(2n-1) As shown, the first 5 hexagonal numbers are: 1 6 15 28 45 How many of the first 100,000,000 hexagonal numbers are evenly divisible by all the numbers from 1 through 20?

8. A triangle number is computed with the following formula: T(n) = n(n+1)/2 Using the above formula, the first 5 triangle numbers are: 1 3 6 10 15 ... What then is the sum of the digits of the 123,456,789th triangle number?

You might also like