Problem: The problem 75 of Project Euler is as follows: It turns out that 12 cm is the smallest length of wire that can be bent to form an integer sided right angle triangle in exactly one way, but there are many more examples. 12 cm: (3,4,5) 24 cm: (6,8,10) 30 cm: (5,12,13) 36 cm: [...]
Problem: The problem 75 of Project Euler is as follows: It turns out that 12 cm is the smallest length of wire that can be bent to form an integer sided right angle triangle in exactly one way, but there are many more examples. 12 cm: (3,4,5) 24 cm: (6,8,10) 30 cm: (5,12,13) 36 cm: [...]
Problem: The problem 104 of Project Euler is as follows. The Fibonacci sequence is defined by the recurrence relation: , where and . It turns out that , which contains 113 digits, is the first Fibonacci number for which the last nine digits are 1-9 pandigital (contain all the digits 1 to 9, but not [...]
There was a need to find the first 9 digits of a fibonacci number and check for a special property. Getting the last few digits is easy, but first few proved difficult. My approach was to get the number of digits in the number and then divide the number by . But the pow method in [...]
A n-digit number is also n-Pandigital if it contains all the digits from 1-n, not necessarily in order. For example, 5 digit pandigital numbers are 12345, 32154, 34512, etc. A lot of problems in Project Euler requires one to check is a number is pandigital. I had implemented it using an array, and it was [...]
The Problem 100 of Project Euler requires one to find a collection of blue and red discs such that the probability of picking two blue discs is 50%. The sum of blue and red discs should be greater than . For example, if there are 15 blue discs and 6 red discs then the probability [...]
The blog is about nothing and everything. It tries to capture what falls through the cracks in the pensive, memories that I would like to capture.
Recent Comments