Clan x86

General Forums => Academic / School => Math and Other Problems => Topic started by: Ender on June 21, 2007, 12:47:31 am

Title: Last Two Digits Problem
Post by: Ender on June 21, 2007, 12:47:31 am
Find the last two digits of

(http://latex.sidoh.org/?render=9%5E%7B9%5E%7B9%5E%7B9%7D%7D%7D)

Note: The solution is on my blog, so no posting if you look at my blog :P
Title: Re: Last Two Digits Problem
Post by: iago on June 21, 2007, 09:32:22 am
Let me start the ball rolling by saying that the first four digits are 4393.

We're half way there!
Title: Re: Last Two Digits Problem
Post by: Ender on June 21, 2007, 09:41:33 am
hehe
Title: Re: Last Two Digits Problem
Post by: iago on June 21, 2007, 10:08:36 am
Is the answer 5689?

Ender: Sorry, I modified this post instead of replying lol.
Title: Re: Last Two Digits Problem
Post by: Ender on June 21, 2007, 10:26:24 am
Last two digits. But yeah, 89 is correct :P

Did you do that programmatically? If so... how the hell?
Title: Re: Last Two Digits Problem
Post by: iago on June 21, 2007, 10:30:26 am
Yes, I did. And sorry for not being able to count. :)

Footnote: Java owns

<edit>
Quote
ron@facevision:~$ cat Test.java
import java.math.BigInteger;

public class Test
{
        public static void main(String []args)
        {
                System.out.println(new BigInteger("9").pow(9).pow(9).pow(9));
        }
}

ron@facevision:~$ javac Test.java
ron@facevision:~$ java Test
439328503696464329829774782657072712058010308177126710621676697750466344744764029773301412612482563729435064854354299095570379503452515853238520182740967398746503532324400000659505126023955913142968176998364877699089666171297275956245407453033190168644894850576346492691458695174281789557994923607783461486426448617667076393901104477324982631297641034277093818692823488603426279473674368943609268871793467206677285688478458498235002859256706389043030847945506577080623430066283504397583789044245429585982964571774605868466160379567432725704121260940939343217905975847365096315872153240969882363435363449775254393010368267343970426230801390250903399147001650831878665172798468587509747439118815689
Title: Re: Last Two Digits Problem
Post by: Ender on June 21, 2007, 10:57:35 am
lol!

JAVA FIGHTING@@!!!~~~

Note: the mathematical solution is still up-for-grabs :P
Title: Re: Last Two Digits Problem
Post by: iago on June 21, 2007, 11:04:58 am
Don't worry, my friend's working on that. And he's elite. I'll report back later. :)
Title: Re: Last Two Digits Problem
Post by: iago on June 21, 2007, 11:13:22 am
Well, my friend here figured it out mathematically and showed me, and totally lost me in number theory. It involved mod100 at the start, which made sense. Then he talked about phi and prime factors and recursion and I got confused. So yeah, it's up for grabs. :)
Title: Re: Last Two Digits Problem
Post by: Ender on June 21, 2007, 11:16:04 am
Hehe. Modular arithmetic is one way to do it. There's also an algebraic way that doesn't require knowledge of number theory. Look on my blog.
Title: Re: Last Two Digits Problem
Post by: Ender on June 21, 2007, 08:23:14 pm
Yes, I did. And sorry for not being able to count. :)

Footnote: Java owns

<edit>
Quote
ron@facevision:~$ cat Test.java
import java.math.BigInteger;

public class Test
{
        public static void main(String []args)
        {
                System.out.println(new BigInteger("9").pow(9).pow(9).pow(9));
        }
}

ron@facevision:~$ javac Test.java
ron@facevision:~$ java Test
439328503696464329829774782657072712058010308177126710621676697750466344744764029773301412612482563729435064854354299095570379503452515853238520182740967398746503532324400000659505126023955913142968176998364877699089666171297275956245407453033190168644894850576346492691458695174281789557994923607783461486426448617667076393901104477324982631297641034277093818692823488603426279473674368943609268871793467206677285688478458498235002859256706389043030847945506577080623430066283504397583789044245429585982964571774605868466160379567432725704121260940939343217905975847365096315872153240969882363435363449775254393010368267343970426230801390250903399147001650831878665172798468587509747439118815689


The 89 is right, but that's gotta be wrong, because the number is x-drillions of digits long. Just consider 10^10^10, which is obviously less than 9^9^9^9. 10^10 is ten billion. Raise ten to that power and you will have ten billion and one digits.
Title: Re: Last Two Digits Problem
Post by: Ender on June 21, 2007, 08:36:39 pm
Okay, as to why your answer matched with mine...If you look at my blog answer, it really doesn't matter what n is.
Title: Re: Last Two Digits Problem
Post by: iago on June 21, 2007, 08:46:17 pm
Pfft, you and all the other math geeks in the world do exponents wrong. Left to right! Comp sci for life! :P
Title: Re: Last Two Digits Problem
Post by: rabbit on June 21, 2007, 10:04:11 pm
Well the last digit is easy.  9^n always has a last digit of 1 or 9, so there's that.  I'm not quite sure about the second, but I'll get around to it.