Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
Wrap description text for readability
  • Loading branch information
Paul Cochrane committed May 9, 2015
1 parent 6fea02c commit f7704d1
Show file tree
Hide file tree
Showing 2 changed files with 22 additions and 8 deletions.
16 changes: 12 additions & 4 deletions categories/euler/prob098-andreoss.pl
Expand Up @@ -8,15 +8,23 @@
L<https://projecteuler.net/problem=98>
By replacing each of the letters in the word CARE with 1, 2, 9, and 6 respectively, we form a square number: 1296 = 36². What is remarkable is that, by using the same digital substitutions, the anagram, RACE, also forms a square number: 9216 = 96². We shall call CARE (and RACE) a square anagram word pair and specify further that leading zeroes are not permitted, neither may a different letter have the same digital value as another letter.
Using words.txt L<https://projecteuler.net/project/resources/p098_words.txt>, a 16K text file containing nearly two-thousand common English words, find all the square anagram word pairs (a palindromic word is NOT considered to be an anagram of itself).
By replacing each of the letters in the word CARE with 1, 2, 9, and 6
respectively, we form a square number: 1296 = 36². What is remarkable is
that, by using the same digital substitutions, the anagram, RACE, also forms
a square number: 9216 = 96². We shall call CARE (and RACE) a square anagram
word pair and specify further that leading zeroes are not permitted, neither
may a different letter have the same digital value as another letter.
Using words.txt
L<https://projecteuler.net/project/resources/p098_words.txt>, a 16K text
file containing nearly two-thousand common English words, find all the
square anagram word pairs (a palindromic word is NOT considered to be an
anagram of itself).
What is the largest square number formed by any member of such a pair?
NOTE: All anagrams formed must be contained in the given text file.
Expected result: 18769
=end pod
Expand Down
14 changes: 10 additions & 4 deletions categories/euler/prob099-andreoss.pl
Expand Up @@ -8,13 +8,19 @@
L<https://projecteuler.net/problem=99>
Comparing two numbers written in index form like 2^11 and 3^7 is not difficult, as any calculator would confirm that 2^11 = 2048 < 3^7 = 2187.
Comparing two numbers written in index form like 2^11 and 3^7 is not
difficult, as any calculator would confirm that 2^11 = 2048 < 3^7 = 2187.
However, confirming that 632382^518061 > 519432^525806 would be much more difficult, as both numbers contain over three million digits.
However, confirming that 632382^518061 > 519432^525806 would be much more
difficult, as both numbers contain over three million digits.
Using base_exp.txt L<https://projecteuler.net/project/resources/p099_base_exp.txt>, a 22K text file containing one thousand lines with a base/exponent pair on each line, determine which line number has the greatest numerical value.
Using base_exp.txt
L<https://projecteuler.net/project/resources/p099_base_exp.txt>, a 22K text
file containing one thousand lines with a base/exponent pair on each line,
determine which line number has the greatest numerical value.
NOTE: The first two lines in the file represent the numbers in the example given above.
NOTE: The first two lines in the file represent the numbers in the example
given above.
Expected result: 709
Expand Down

0 comments on commit f7704d1

Please sign in to comment.