euler-manager 0.0.5 → 0.0.6
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/README.md +11 -1
- data/Rakefile +3 -0
- data/bin/euler +28 -9
- data/config/config.rb +1 -0
- data/data/answers.yml +430 -456
- data/data/images/blackdot.gif +0 -0
- data/data/images/bracket_left.gif +0 -0
- data/data/images/bracket_right.gif +0 -0
- data/data/images/p295_lenticular.gif +0 -0
- data/data/images/p296_bisector.gif +0 -0
- data/data/images/p303_formula100.gif +0 -0
- data/data/images/p303_formula10000.gif +0 -0
- data/data/images/p392_gridlines.png +0 -0
- data/data/images/p400_winning.png +0 -0
- data/data/images/p411_longpath.png +0 -0
- data/data/images/p412_table53.png +0 -0
- data/data/images/p412_tablenums.png +0 -0
- data/data/images/p422_hyperbola.gif +0 -0
- data/data/images/p428_necklace.png +0 -0
- data/data/images/p_015.gif +0 -0
- data/data/images/p_068_1.gif +0 -0
- data/data/images/p_068_2.gif +0 -0
- data/data/images/p_085.gif +0 -0
- data/data/images/p_086.gif +0 -0
- data/data/images/p_090.gif +0 -0
- data/data/images/p_091_1.gif +0 -0
- data/data/images/p_091_2.gif +0 -0
- data/data/images/p_107_1.gif +0 -0
- data/data/images/p_107_2.gif +0 -0
- data/data/images/p_109.gif +0 -0
- data/data/images/p_126.gif +0 -0
- data/data/images/p_128.gif +0 -0
- data/data/images/p_138.gif +0 -0
- data/data/images/p_139.gif +0 -0
- data/data/images/p_143_torricelli.gif +0 -0
- data/data/images/p_144_1.gif +0 -0
- data/data/images/p_144_2.gif +0 -0
- data/data/images/p_147.gif +0 -0
- data/data/images/p_150.gif +0 -0
- data/data/images/p_151.gif +0 -0
- data/data/images/p_152_sum.gif +0 -0
- data/data/images/p_153_formule1.gif +0 -0
- data/data/images/p_153_formule2.gif +0 -0
- data/data/images/p_153_formule5.gif +0 -0
- data/data/images/p_153_formule6.gif +0 -0
- data/data/images/p_154_pyramid.gif +0 -0
- data/data/images/p_155_capacitors1.gif +0 -0
- data/data/images/p_155_capsform.gif +0 -0
- data/data/images/p_155_capsmu.gif +0 -0
- data/data/images/p_161_k9.gif +0 -0
- data/data/images/p_161_trio1.gif +0 -0
- data/data/images/p_161_trio3.gif +0 -0
- data/data/images/p_163.gif +0 -0
- data/data/images/p_173_square_laminas.gif +0 -0
- data/data/images/p_177_quad.gif +0 -0
- data/data/images/p_184.gif +0 -0
- data/data/images/p_189_colours.gif +0 -0
- data/data/images/p_189_grid.gif +0 -0
- data/data/images/p_194_Fig.png +0 -0
- data/data/images/p_194_GraphA.png +0 -0
- data/data/images/p_194_GraphB.png +0 -0
- data/data/images/p_199_circles_in_circles.gif +0 -0
- data/data/images/p_201_laserbeam.gif +0 -0
- data/data/images/p_208_robotwalk.gif +0 -0
- data/data/images/p_215_crackfree.gif +0 -0
- data/data/images/p_220.gif +0 -0
- data/data/images/p_226_formula.gif +0 -0
- data/data/images/p_226_scoop2.gif +0 -0
- data/data/images/p_228.png +0 -0
- data/data/images/p_237.gif +0 -0
- data/data/images/p_244_example.gif +0 -0
- data/data/images/p_244_start.gif +0 -0
- data/data/images/p_244_target.gif +0 -0
- data/data/images/p_246_anim.gif +0 -0
- data/data/images/p_246_ellipse.gif +0 -0
- data/data/images/p_247_hypersquares.gif +0 -0
- data/data/images/p_251_cardano.gif +0 -0
- data/data/images/p_252_convexhole.gif +0 -0
- data/data/images/p_255_Example.gif +0 -0
- data/data/images/p_255_Heron.gif +0 -0
- data/data/images/p_256_tatami3.gif +0 -0
- data/data/images/p_257_bisector.gif +0 -0
- data/data/images/p_262_formula1.gif +0 -0
- data/data/images/p_264_TriangleCentres.gif +0 -0
- data/data/images/p_265_BinaryCircles.gif +0 -0
- data/data/images/p_270_CutSquare.gif +0 -0
- data/data/images/p_275_sculptures2.gif +0 -0
- data/data/images/p_281_pizza.gif +0 -0
- data/data/images/p_282_formula.gif +0 -0
- data/data/images/p_282formula3.gif +0 -0
- data/data/images/p_287_quadtree.gif +0 -0
- data/data/images/p_289_euler.gif +0 -0
- data/data/images/p_291_formula.gif +0 -0
- data/data/images/p_299_ThreeSimTri.gif +0 -0
- data/data/images/p_300_protein.gif +0 -0
- data/data/images/p_306_pstrip.gif +0 -0
- data/data/images/p_309_ladders.gif +0 -0
- data/data/images/p_311_biclinic.gif +0 -0
- data/data/images/p_312_sierpinsky8t.gif +0 -0
- data/data/images/p_312_sierpinskyAt.gif +0 -0
- data/data/images/p_313_sliding_game_1.gif +0 -0
- data/data/images/p_313_sliding_game_2.gif +0 -0
- data/data/images/p_314_landgrab.gif +0 -0
- data/data/images/p_315_clocks.gif +0 -0
- data/data/images/p_316_decexp1.gif +0 -0
- data/data/images/p_316_decexp2.gif +0 -0
- data/data/images/p_316_decexp3.gif +0 -0
- data/data/images/p_321_swapping_counters_1.gif +0 -0
- data/data/images/p_321_swapping_counters_2.gif +0 -0
- data/data/images/p_326_formula1.gif +0 -0
- data/data/images/p_326_formula2.gif +0 -0
- data/data/images/p_327_rooms_of_doom.gif +0 -0
- data/data/images/p_328_sum1.gif +0 -0
- data/data/images/p_328_sum2.gif +0 -0
- data/data/images/p_330_formula.gif +0 -0
- data/data/images/p_331_crossflips1.gif +0 -0
- data/data/images/p_331_crossflips2.gif +0 -0
- data/data/images/p_331_crossflips3.gif +0 -0
- data/data/images/p_332_spherical.jpg +0 -0
- data/data/images/p_332_sum.gif +0 -0
- data/data/images/p_334_beans.gif +0 -0
- data/data/images/p_334_cases.gif +0 -0
- data/data/images/p_334_lfloor.gif +0 -0
- data/data/images/p_334_oplus.gif +0 -0
- data/data/images/p_334_rfloor.gif +0 -0
- data/data/images/p_335_mancala.gif +0 -0
- data/data/images/p_335_sum.gif +0 -0
- data/data/images/p_336_maximix.gif +0 -0
- data/data/images/p_338_gridpaper.gif +0 -0
- data/data/images/p_340_formula.gif +0 -0
- data/data/images/p_344_silverdollar.gif +0 -0
- data/data/images/p_351_hexorchard.png +0 -0
- data/data/images/p_354_bee_honeycomb.png +0 -0
- data/data/images/p_356_cubicpoly1.gif +0 -0
- data/data/images/p_356_cubicpoly2.gif +0 -0
- data/data/images/p_361_Thue-Morse1.gif +0 -0
- data/data/images/p_364_comf_dist.gif +0 -0
- data/data/images/p_372_pencilray1.jpg +0 -0
- data/data/images/p_372_pencilray2.gif +0 -0
- data/data/images/p_380_mazes.gif +0 -0
- data/data/images/p_384_formula.gif +0 -0
- data/data/images/p_385_ellipsetriangle.png +0 -0
- data/data/images/p_394_eatpie.gif +0 -0
- data/data/images/p_395_pythagorean.gif +0 -0
- data/data/images/p_404_c_ellipse.gif +0 -0
- data/data/images/p_405_tile1.png +0 -0
- data/data/images/p_405_tile2.gif +0 -0
- data/data/images/p_420_matrix.gif +0 -0
- data/data/images/p_424_kakuro1.gif +0 -0
- data/data/images/p_426_baxball1.gif +0 -0
- data/data/images/p_426_baxball2.gif +0 -0
- data/data/images/p_430_flips.gif +0 -0
- data/data/images/sod_13.gif +115 -0
- data/data/images/spacer.gif +0 -0
- data/data/images/symbol_asymp.gif +0 -0
- data/data/images/symbol_cong.gif +0 -0
- data/data/images/symbol_ge.gif +0 -0
- data/data/images/symbol_gt.gif +0 -0
- data/data/images/symbol_implies.gif +0 -0
- data/data/images/symbol_lceil.gif +0 -0
- data/data/images/symbol_le.gif +0 -0
- data/data/images/symbol_lfloor.gif +0 -0
- data/data/images/symbol_lt.gif +0 -0
- data/data/images/symbol_maps.gif +0 -0
- data/data/images/symbol_minus.gif +0 -0
- data/data/images/symbol_ne.gif +0 -0
- data/data/images/symbol_plusmn.gif +0 -0
- data/data/images/symbol_radic.gif +0 -0
- data/data/images/symbol_rceil.gif +0 -0
- data/data/images/symbol_rfloor.gif +0 -0
- data/data/images/symbol_sum.gif +0 -0
- data/data/images/symbol_times.gif +0 -0
- data/data/problems/1.yml +5 -3
- data/data/problems/10.yml +3 -4
- data/data/problems/100.yml +7 -9
- data/data/problems/101.yml +32 -45
- data/data/problems/102.yml +11 -12
- data/data/problems/103.yml +18 -22
- data/data/problems/104.yml +9 -11
- data/data/problems/105.yml +12 -17
- data/data/problems/106.yml +14 -15
- data/data/problems/107.yml +16 -16
- data/data/problems/108.yml +17 -28
- data/data/problems/109.yml +27 -29
- data/data/problems/11.yml +24 -29
- data/data/problems/110.yml +11 -15
- data/data/problems/111.yml +27 -17
- data/data/problems/112.yml +13 -11
- data/data/problems/113.yml +11 -9
- data/data/problems/114.yml +46 -100
- data/data/problems/115.yml +15 -12
- data/data/problems/116.yml +33 -72
- data/data/problems/117.yml +36 -78
- data/data/problems/118.yml +5 -5
- data/data/problems/119.yml +9 -7
- data/data/problems/12.yml +8 -9
- data/data/problems/120.yml +7 -13
- data/data/problems/121.yml +9 -11
- data/data/problems/122.yml +21 -38
- data/data/problems/123.yml +9 -9
- data/data/problems/124.yml +24 -54
- data/data/problems/125.yml +7 -8
- data/data/problems/126.yml +12 -13
- data/data/problems/127.yml +21 -27
- data/data/problems/128.yml +19 -14
- data/data/problems/129.yml +9 -8
- data/data/problems/13.yml +52 -2
- data/data/problems/130.yml +12 -15
- data/data/problems/131.yml +9 -8
- data/data/problems/132.yml +7 -8
- data/data/problems/133.yml +9 -9
- data/data/problems/134.yml +7 -15
- data/data/problems/135.yml +9 -16
- data/data/problems/136.yml +9 -13
- data/data/problems/137.yml +22 -32
- data/data/problems/138.yml +11 -16
- data/data/problems/139.yml +11 -11
- data/data/problems/14.yml +14 -24
- data/data/problems/140.yml +18 -25
- data/data/problems/141.yml +10 -11
- data/data/problems/142.yml +3 -10
- data/data/problems/143.yml +13 -16
- data/data/problems/144.yml +23 -26
- data/data/problems/145.yml +7 -7
- data/data/problems/146.yml +6 -6
- data/data/problems/147.yml +7 -8
- data/data/problems/148.yml +15 -7
- data/data/problems/149.yml +26 -35
- data/data/problems/15.yml +7 -7
- data/data/problems/150.yml +18 -29
- data/data/problems/151.yml +17 -15
- data/data/problems/152.yml +11 -8
- data/data/problems/153.yml +38 -53
- data/data/problems/154.yml +10 -12
- data/data/problems/155.yml +12 -15
- data/data/problems/156.yml +20 -22
- data/data/problems/157.yml +26 -28
- data/data/problems/158.yml +13 -14
- data/data/problems/159.yml +15 -25
- data/data/problems/16.yml +5 -2
- data/data/problems/160.yml +3 -4
- data/data/problems/161.yml +6 -10
- data/data/problems/162.yml +10 -11
- data/data/problems/163.yml +13 -15
- data/data/problems/164.yml +3 -3
- data/data/problems/165.yml +25 -28
- data/data/problems/166.yml +7 -11
- data/data/problems/167.yml +10 -12
- data/data/problems/168.yml +7 -9
- data/data/problems/169.yml +4 -5
- data/data/problems/17.yml +7 -7
- data/data/problems/170.yml +7 -10
- data/data/problems/171.yml +7 -9
- data/data/problems/172.yml +3 -2
- data/data/problems/173.yml +9 -7
- data/data/problems/174.yml +13 -15
- data/data/problems/175.yml +13 -15
- data/data/problems/176.yml +5 -5
- data/data/problems/177.yml +13 -12
- data/data/problems/178.yml +5 -5
- data/data/problems/179.yml +3 -6
- data/data/problems/18.yml +13 -17
- data/data/problems/180.yml +20 -25
- data/data/problems/181.yml +7 -3
- data/data/problems/182.yml +22 -27
- data/data/problems/183.yml +17 -23
- data/data/problems/184.yml +11 -14
- data/data/problems/185.yml +17 -18
- data/data/problems/186.yml +16 -24
- data/data/problems/187.yml +9 -12
- data/data/problems/188.yml +5 -6
- data/data/problems/189.yml +5 -7
- data/data/problems/19.yml +7 -8
- data/data/problems/190.yml +7 -9
- data/data/problems/191.yml +9 -10
- data/data/problems/192.yml +14 -22
- data/data/problems/193.yml +5 -3
- data/data/problems/194.yml +11 -14
- data/data/problems/195.yml +7 -9
- data/data/problems/196.yml +13 -21
- data/data/problems/197.yml +7 -11
- data/data/problems/198.yml +13 -16
- data/data/problems/199.yml +10 -10
- data/data/problems/2.yml +6 -6
- data/data/problems/20.yml +10 -18
- data/data/problems/200.yml +8 -8
- data/data/problems/201.yml +14 -16
- data/data/problems/202.yml +11 -10
- data/data/problems/203.yml +11 -16
- data/data/problems/204.yml +7 -7
- data/data/problems/205.yml +6 -6
- data/data/problems/206.yml +2 -2
- data/data/problems/207.yml +13 -16
- data/data/problems/208.yml +8 -8
- data/data/problems/209.yml +11 -23
- data/data/problems/21.yml +8 -9
- data/data/problems/210.yml +6 -6
- data/data/problems/211.yml +7 -7
- data/data/problems/212.yml +26 -36
- data/data/problems/213.yml +6 -7
- data/data/problems/214.yml +10 -11
- data/data/problems/215.yml +11 -14
- data/data/problems/216.yml +7 -10
- data/data/problems/217.yml +14 -23
- data/data/problems/218.yml +9 -10
- data/data/problems/219.yml +10 -15
- data/data/problems/22.yml +7 -9
- data/data/problems/220.yml +15 -20
- data/data/problems/221.yml +10 -16
- data/data/problems/222.yml +5 -3
- data/data/problems/223.yml +6 -8
- data/data/problems/224.yml +6 -8
- data/data/problems/225.yml +6 -7
- data/data/problems/226.yml +9 -12
- data/data/problems/227.yml +9 -9
- data/data/problems/228.yml +14 -17
- data/data/problems/229.yml +17 -25
- data/data/problems/23.yml +11 -15
- data/data/problems/230.yml +15 -19
- data/data/problems/231.yml +8 -12
- data/data/problems/232.yml +9 -10
- data/data/problems/233.yml +7 -6
- data/data/problems/234.yml +14 -19
- data/data/problems/235.yml +4 -5
- data/data/problems/236.yml +20 -22
- data/data/problems/237.yml +14 -9
- data/data/problems/238.yml +21 -33
- data/data/problems/239.yml +5 -5
- data/data/problems/24.yml +7 -6
- data/data/problems/240.yml +7 -7
- data/data/problems/241.yml +9 -12
- data/data/problems/242.yml +7 -9
- data/data/problems/243.yml +14 -15
- data/data/problems/244.yml +19 -28
- data/data/problems/245.yml +22 -30
- data/data/problems/246.yml +10 -13
- data/data/problems/247.yml +14 -17
- data/data/problems/248.yml +5 -2
- data/data/problems/249.yml +3 -3
- data/data/problems/25.yml +12 -11
- data/data/problems/250.yml +3 -3
- data/data/problems/251.yml +11 -9
- data/data/problems/252.yml +24 -25
- data/data/problems/253.yml +19 -32
- data/data/problems/254.yml +13 -17
- data/data/problems/255.yml +40 -50
- data/data/problems/256.yml +31 -39
- data/data/problems/257.yml +10 -14
- data/data/problems/258.yml +7 -9
- data/data/problems/259.yml +14 -12
- data/data/problems/26.yml +17 -7
- data/data/problems/260.yml +21 -25
- data/data/problems/261.yml +13 -15
- data/data/problems/262.yml +15 -16
- data/data/problems/263.yml +13 -15
- data/data/problems/264.yml +15 -16
- data/data/problems/265.yml +10 -12
- data/data/problems/266.yml +6 -6
- data/data/problems/267.yml +13 -10
- data/data/problems/268.yml +5 -4
- data/data/problems/269.yml +10 -11
- data/data/problems/27.yml +15 -21
- data/data/problems/270.yml +13 -13
- data/data/problems/271.yml +7 -9
- data/data/problems/272.yml +8 -11
- data/data/problems/273.yml +13 -17
- data/data/problems/274.yml +16 -19
- data/data/problems/275.yml +13 -15
- data/data/problems/276.yml +5 -7
- data/data/problems/277.yml +17 -20
- data/data/problems/278.yml +20 -28
- data/data/problems/279.yml +4 -3
- data/data/problems/28.yml +6 -13
- data/data/problems/280.yml +9 -9
- data/data/problems/281.yml +10 -13
- data/data/problems/282.yml +9 -6
- data/data/problems/283.yml +8 -8
- data/data/problems/284.yml +15 -18
- data/data/problems/285.yml +11 -11
- data/data/problems/286.yml +7 -8
- data/data/problems/287.yml +22 -32
- data/data/problems/288.yml +10 -11
- data/data/problems/289.yml +14 -15
- data/data/problems/29.yml +13 -20
- data/data/problems/290.yml +3 -4
- data/data/problems/291.yml +3 -6
- data/data/problems/292.yml +8 -9
- data/data/problems/293.yml +9 -10
- data/data/problems/294.yml +6 -6
- data/data/problems/295.yml +16 -21
- data/data/problems/296.yml +9 -11
- data/data/problems/297.yml +12 -15
- data/data/problems/298.yml +29 -29
- data/data/problems/299.yml +15 -21
- data/data/problems/3.yml +3 -3
- data/data/problems/30.yml +7 -8
- data/data/problems/300.yml +15 -16
- data/data/problems/301.yml +15 -17
- data/data/problems/302.yml +13 -14
- data/data/problems/303.yml +9 -7
- data/data/problems/304.yml +10 -15
- data/data/problems/305.yml +6 -10
- data/data/problems/306.yml +20 -24
- data/data/problems/307.yml +7 -8
- data/data/problems/308.yml +19 -30
- data/data/problems/309.yml +11 -12
- data/data/problems/31.yml +11 -14
- data/data/problems/310.yml +10 -15
- data/data/problems/311.yml +11 -17
- data/data/problems/312.yml +10 -11
- data/data/problems/313.yml +13 -13
- data/data/problems/314.yml +23 -25
- data/data/problems/315.yml +39 -45
- data/data/problems/316.yml +13 -13
- data/data/problems/317.yml +6 -7
- data/data/problems/318.yml +35 -57
- data/data/problems/319.yml +15 -19
- data/data/problems/32.yml +9 -10
- data/data/problems/320.yml +9 -8
- data/data/problems/321.yml +8 -9
- data/data/problems/322.yml +6 -8
- data/data/problems/323.yml +12 -15
- data/data/problems/324.yml +10 -13
- data/data/problems/325.yml +15 -21
- data/data/problems/326.yml +15 -8
- data/data/problems/327.yml +19 -23
- data/data/problems/328.yml +28 -31
- data/data/problems/329.yml +12 -13
- data/data/problems/33.yml +9 -9
- data/data/problems/330.yml +17 -36
- data/data/problems/331.yml +16 -22
- data/data/problems/332.yml +9 -11
- data/data/problems/333.yml +17 -20
- data/data/problems/334.yml +22 -34
- data/data/problems/335.yml +11 -12
- data/data/problems/336.yml +18 -20
- data/data/problems/337.yml +9 -11
- data/data/problems/338.yml +27 -37
- data/data/problems/339.yml +9 -9
- data/data/problems/34.yml +7 -3
- data/data/problems/340.yml +8 -10
- data/data/problems/341.yml +12 -14
- data/data/problems/342.yml +9 -13
- data/data/problems/343.yml +18 -25
- data/data/problems/344.yml +16 -17
- data/data/problems/345.yml +17 -22
- data/data/problems/346.yml +7 -7
- data/data/problems/347.yml +9 -12
- data/data/problems/348.yml +7 -8
- data/data/problems/349.yml +8 -9
- data/data/problems/35.yml +7 -4
- data/data/problems/350.yml +12 -14
- data/data/problems/351.yml +8 -9
- data/data/problems/352.yml +38 -42
- data/data/problems/353.yml +17 -21
- data/data/problems/354.yml +11 -13
- data/data/problems/355.yml +4 -4
- data/data/problems/356.yml +6 -6
- data/data/problems/357.yml +5 -5
- data/data/problems/358.yml +16 -25
- data/data/problems/359.yml +19 -22
- data/data/problems/36.yml +7 -4
- data/data/problems/360.yml +8 -8
- data/data/problems/361.yml +14 -15
- data/data/problems/362.yml +16 -28
- data/data/problems/363.yml +22 -23
- data/data/problems/364.yml +9 -11
- data/data/problems/365.yml +7 -13
- data/data/problems/366.yml +19 -22
- data/data/problems/367.yml +14 -15
- data/data/problems/368.yml +18 -35
- data/data/problems/369.yml +7 -11
- data/data/problems/37.yml +7 -6
- data/data/problems/370.yml +10 -13
- data/data/problems/371.yml +8 -9
- data/data/problems/372.yml +9 -12
- data/data/problems/373.yml +5 -6
- data/data/problems/374.yml +17 -21
- data/data/problems/375.yml +13 -17
- data/data/problems/376.yml +19 -21
- data/data/problems/377.yml +6 -7
- data/data/problems/378.yml +8 -11
- data/data/problems/379.yml +9 -11
- data/data/problems/38.yml +9 -13
- data/data/problems/380.yml +14 -17
- data/data/problems/381.yml +12 -18
- data/data/problems/382.yml +16 -19
- data/data/problems/383.yml +7 -9
- data/data/problems/384.yml +20 -24
- data/data/problems/385.yml +12 -16
- data/data/problems/386.yml +9 -11
- data/data/problems/387.yml +14 -15
- data/data/problems/388.yml +6 -8
- data/data/problems/389.yml +8 -8
- data/data/problems/39.yml +7 -6
- data/data/problems/390.yml +9 -14
- data/data/problems/391.yml +21 -25
- data/data/problems/392.yml +16 -17
- data/data/problems/393.yml +5 -6
- data/data/problems/394.yml +15 -18
- data/data/problems/395.yml +12 -13
- data/data/problems/396.yml +17 -22
- data/data/problems/397.yml +13 -16
- data/data/problems/398.yml +8 -9
- data/data/problems/399.yml +18 -18
- data/data/problems/4.yml +5 -4
- data/data/problems/40.yml +11 -14
- data/data/problems/400.yml +10 -11
- data/data/problems/401.yml +6 -7
- data/data/problems/402.yml +16 -21
- data/data/problems/403.yml +12 -14
- data/data/problems/404.yml +14 -16
- data/data/problems/405.yml +10 -11
- data/data/problems/406.yml +35 -41
- data/data/problems/407.yml +9 -16
- data/data/problems/408.yml +9 -9
- data/data/problems/409.yml +5 -7
- data/data/problems/41.yml +5 -4
- data/data/problems/410.yml +10 -13
- data/data/problems/411.yml +15 -19
- data/data/problems/412.yml +11 -15
- data/data/problems/413.yml +8 -8
- data/data/problems/414.yml +29 -34
- data/data/problems/415.yml +12 -15
- data/data/problems/416.yml +7 -7
- data/data/problems/417.yml +16 -17
- data/data/problems/418.yml +9 -12
- data/data/problems/419.yml +13 -18
- data/data/problems/42.yml +9 -10
- data/data/problems/420.yml +5 -6
- data/data/problems/421.yml +14 -25
- data/data/problems/422.yml +16 -18
- data/data/problems/423.yml +16 -18
- data/data/problems/424.yml +18 -19
- data/data/problems/425.yml +11 -12
- data/data/problems/426.yml +20 -21
- data/data/problems/427.yml +11 -13
- data/data/problems/428.yml +21 -25
- data/data/problems/429.yml +6 -6
- data/data/problems/43.yml +15 -13
- data/data/problems/430.yml +14 -16
- data/data/problems/44.yml +9 -12
- data/data/problems/45.yml +11 -11
- data/data/problems/46.yml +9 -14
- data/data/problems/47.yml +11 -16
- data/data/problems/48.yml +5 -3
- data/data/problems/49.yml +7 -6
- data/data/problems/5.yml +5 -4
- data/data/problems/50.yml +11 -6
- data/data/problems/51.yml +9 -11
- data/data/problems/52.yml +5 -4
- data/data/problems/53.yml +15 -24
- data/data/problems/54.yml +29 -39
- data/data/problems/55.yml +16 -17
- data/data/problems/56.yml +5 -7
- data/data/problems/57.yml +10 -11
- data/data/problems/58.yml +11 -18
- data/data/problems/59.yml +11 -19
- data/data/problems/6.yml +13 -9
- data/data/problems/60.yml +5 -6
- data/data/problems/61.yml +18 -26
- data/data/problems/62.yml +5 -5
- data/data/problems/63.yml +5 -3
- data/data/problems/64.yml +52 -126
- data/data/problems/65.yml +21 -47
- data/data/problems/66.yml +13 -23
- data/data/problems/67.yml +10 -13
- data/data/problems/68.yml +15 -19
- data/data/problems/69.yml +18 -10
- data/data/problems/7.yml +5 -2
- data/data/problems/70.yml +10 -12
- data/data/problems/71.yml +11 -13
- data/data/problems/72.yml +11 -12
- data/data/problems/73.yml +11 -12
- data/data/problems/74.yml +25 -37
- data/data/problems/75.yml +10 -12
- data/data/problems/76.yml +4 -4
- data/data/problems/77.yml +4 -4
- data/data/problems/78.yml +13 -8
- data/data/problems/79.yml +7 -7
- data/data/problems/8.yml +14 -8
- data/data/problems/80.yml +7 -7
- data/data/problems/81.yml +9 -15
- data/data/problems/82.yml +10 -15
- data/data/problems/83.yml +10 -19
- data/data/problems/84.yml +36 -59
- data/data/problems/85.yml +7 -5
- data/data/problems/86.yml +11 -11
- data/data/problems/87.yml +7 -8
- data/data/problems/88.yml +30 -49
- data/data/problems/89.yml +13 -14
- data/data/problems/9.yml +6 -9
- data/data/problems/90.yml +16 -18
- data/data/problems/91.yml +10 -15
- data/data/problems/92.yml +14 -25
- data/data/problems/93.yml +13 -17
- data/data/problems/94.yml +7 -7
- data/data/problems/95.yml +13 -19
- data/data/problems/96.yml +24 -40
- data/data/problems/97.yml +7 -10
- data/data/problems/98.yml +9 -12
- data/data/problems/99.yml +9 -12
- data/euler-manager.gemspec +1 -0
- data/example/1/README.md +4 -4
- data/example/15/README.md +8 -0
- data/example/15/python/15.py +5 -0
- data/example/15/python/euler.py +0 -0
- data/example/2/README.md +7 -5
- data/example/Eulerfile.rb +1 -0
- data/lib/euler/problem.rb +6 -1
- data/lib/euler/solution.rb +4 -2
- data/lib/euler/version.rb +1 -1
- data/rake/clean.rake +16 -0
- data/rake/update.rake +88 -0
- data/spec/euler/solution_spec.rb +2 -1
- data/templates/Eulerfile.rb +12 -0
- metadata +189 -29
- data/data/problems/431.yml +0 -33
- data/data/problems/432.yml +0 -13
- data/data/problems/433.yml +0 -18
- data/data/problems/434.yml +0 -32
- data/data/problems/435.yml +0 -21
- data/data/problems/436.yml +0 -21
- data/data/problems/437.yml +0 -22
- data/data/problems/438.yml +0 -29
- data/data/problems/439.yml +0 -17
- data/data/problems/440.yml +0 -21
- data/data/problems/441.yml +0 -23
- data/data/problems/442.yml +0 -9
- data/data/problems/443.yml +0 -13
- data/data/problems/444.yml +0 -28
- data/data/problems/445.yml +0 -37
- data/data/problems/446.yml +0 -29
- data/data/problems/447.yml +0 -31
- data/data/problems/448.yml +0 -14
- data/data/problems/449.yml +0 -17
- data/data/problems/450.yml +0 -26
- data/data/problems/451.yml +0 -15
- data/data/problems/452.yml +0 -8
- data/data/problems/453.yml +0 -16
- data/data/problems/454.yml +0 -17
- data/data/problems/455.yml +0 -16
- data/data/problems/456.yml +0 -15
- data/scripts/update_problems +0 -68
data/data/problems/47.yml
CHANGED
@@ -2,20 +2,15 @@
|
|
2
2
|
:id: 47
|
3
3
|
:name: Distinct primes factors
|
4
4
|
:url: http://projecteuler.net/problem=47
|
5
|
-
:content: "
|
6
|
-
|
7
|
-
|
8
|
-
|
9
|
-
|
10
|
-
|
11
|
-
=
|
12
|
-
|
13
|
-
|
14
|
-
|
15
|
-
style=\"vertical-align:middle;\"> 5 <img src=\"images/symbol_times.gif\" width=\"9\"
|
16
|
-
height=\"9\" alt=\"×\" border=\"0\" style=\"vertical-align:middle;\"> 43<br>646
|
17
|
-
= 2 <img src=\"images/symbol_times.gif\" width=\"9\" height=\"9\" alt=\"×\" border=\"0\"
|
18
|
-
style=\"vertical-align:middle;\"> 17 <img src=\"images/symbol_times.gif\" width=\"9\"
|
19
|
-
height=\"9\" alt=\"×\" border=\"0\" style=\"vertical-align:middle;\"> 19.</p>\r\n<p>Find
|
5
|
+
:content: "The first two consecutive numbers to have two distinct prime factors are:\n\n14
|
6
|
+
= 2 ![×](/home/will/src/euler-manager/config/../data/images/symbol_times.gif) 7
|
7
|
+
\ \n15 = 3 ![×](/home/will/src/euler-manager/config/../data/images/symbol_times.gif)
|
8
|
+
5\n\nThe first three consecutive numbers to have three distinct prime factors are:\n\n644
|
9
|
+
= 2² ![×](/home/will/src/euler-manager/config/../data/images/symbol_times.gif) 7
|
10
|
+
![×](/home/will/src/euler-manager/config/../data/images/symbol_times.gif) 23 \n645
|
11
|
+
= 3 ![×](/home/will/src/euler-manager/config/../data/images/symbol_times.gif) 5
|
12
|
+
![×](/home/will/src/euler-manager/config/../data/images/symbol_times.gif) 43 \n646
|
13
|
+
= 2 ![×](/home/will/src/euler-manager/config/../data/images/symbol_times.gif) 17
|
14
|
+
![×](/home/will/src/euler-manager/config/../data/images/symbol_times.gif) 19.\n\nFind
|
20
15
|
the first four consecutive integers to have four distinct prime factors. What is
|
21
|
-
the first of these numbers
|
16
|
+
the first of these numbers?\n\n"
|
data/data/problems/48.yml
CHANGED
@@ -2,6 +2,8 @@
|
|
2
2
|
:id: 48
|
3
3
|
:name: Self powers
|
4
4
|
:url: http://projecteuler.net/problem=48
|
5
|
-
:content:
|
6
|
-
+
|
7
|
-
|
5
|
+
:content: |+
|
6
|
+
The series, 1<sup>1</sup> + 2<sup>2</sup> + 3<sup>3</sup> + ... + 10<sup>10</sup> = 10405071317.
|
7
|
+
|
8
|
+
Find the last ten digits of the series, 1<sup>1</sup> + 2<sup>2</sup> + 3<sup>3</sup> + ... + 1000<sup>1000</sup>.
|
9
|
+
|
data/data/problems/49.yml
CHANGED
@@ -2,9 +2,10 @@
|
|
2
2
|
:id: 49
|
3
3
|
:name: Prime permutations
|
4
4
|
:url: http://projecteuler.net/problem=49
|
5
|
-
:content:
|
6
|
-
terms increases by 3330, is unusual in two ways: (i) each of the three terms are
|
7
|
-
|
8
|
-
are no arithmetic sequences made up of three 1-, 2-, or 3-digit primes, exhibiting
|
9
|
-
|
10
|
-
12-digit number do you form by concatenating the three terms in this sequence
|
5
|
+
:content: |+
|
6
|
+
The arithmetic sequence, 1487, 4817, 8147, in which each of the terms increases by 3330, is unusual in two ways: (i) each of the three terms are prime, and, (ii) each of the 4-digit numbers are permutations of one another.
|
7
|
+
|
8
|
+
There are no arithmetic sequences made up of three 1-, 2-, or 3-digit primes, exhibiting this property, but there is one other 4-digit increasing sequence.
|
9
|
+
|
10
|
+
What 12-digit number do you form by concatenating the three terms in this sequence?
|
11
|
+
|
data/data/problems/5.yml
CHANGED
@@ -2,7 +2,8 @@
|
|
2
2
|
:id: 5
|
3
3
|
:name: Smallest multiple
|
4
4
|
:url: http://projecteuler.net/problem=5
|
5
|
-
:content:
|
6
|
-
from 1 to 10 without any remainder
|
7
|
-
|
8
|
-
of the numbers from 1 to 20
|
5
|
+
:content: |+
|
6
|
+
2520 is the smallest number that can be divided by each of the numbers from 1 to 10 without any remainder.
|
7
|
+
|
8
|
+
What is the smallest positive number that is <dfn title="divisible with no remainder">evenly divisible</dfn> by all of the numbers from 1 to 20?
|
9
|
+
|
data/data/problems/50.yml
CHANGED
@@ -2,9 +2,14 @@
|
|
2
2
|
:id: 50
|
3
3
|
:name: Consecutive prime sum
|
4
4
|
:url: http://projecteuler.net/problem=50
|
5
|
-
:content:
|
6
|
-
|
7
|
-
|
8
|
-
|
9
|
-
|
10
|
-
|
5
|
+
:content: |+
|
6
|
+
The prime 41, can be written as the sum of six consecutive primes:
|
7
|
+
|
8
|
+
41 = 2 + 3 + 5 + 7 + 11 + 13
|
9
|
+
|
10
|
+
This is the longest sum of consecutive primes that adds to a prime below one-hundred.
|
11
|
+
|
12
|
+
The longest sum of consecutive primes below one-thousand that adds to a prime, contains 21 terms, and is equal to 953.
|
13
|
+
|
14
|
+
Which prime, below one-million, can be written as the sum of the most consecutive primes?
|
15
|
+
|
data/data/problems/51.yml
CHANGED
@@ -2,14 +2,12 @@
|
|
2
2
|
:id: 51
|
3
3
|
:name: Prime digit replacements
|
4
4
|
:url: http://projecteuler.net/problem=51
|
5
|
-
:content:
|
6
|
-
six of the possible values: 157, 257, 457, 557, 757, and 857, are all prime.</p>
|
7
|
-
|
8
|
-
out that six of the nine possible values: 13, 23, 43, 53, 73, and 83, are all prime
|
9
|
-
|
10
|
-
this 5-digit number is the first example having seven primes among the ten generated
|
11
|
-
|
12
|
-
|
13
|
-
|
14
|
-
the number (not necessarily adjacent digits) with the same digit, is part of an
|
15
|
-
eight prime value family.</p>\r\n\r\n"
|
5
|
+
:content: |+
|
6
|
+
<!--<p>By replacing the 1<sup>st</sup> digit of *57, it turns out that six of the possible values: 157, 257, 457, 557, 757, and 857, are all prime.</p> -->
|
7
|
+
|
8
|
+
By replacing the 1<sup>st</sup> digit of the 2-digit number \*3, it turns out that six of the nine possible values: 13, 23, 43, 53, 73, and 83, are all prime.
|
9
|
+
|
10
|
+
By replacing the 3<sup>rd</sup> and 4<sup>th</sup> digits of 56\*\*3 with the same digit, this 5-digit number is the first example having seven primes among the ten generated numbers, yielding the family: 56003, 56113, 56333, 56443, 56663, 56773, and 56993. Consequently 56003, being the first member of this family, is the smallest prime with this property.
|
11
|
+
|
12
|
+
Find the smallest prime which, by replacing part of the number (not necessarily adjacent digits) with the same digit, is part of an eight prime value family.
|
13
|
+
|
data/data/problems/52.yml
CHANGED
@@ -2,7 +2,8 @@
|
|
2
2
|
:id: 52
|
3
3
|
:name: Permuted multiples
|
4
4
|
:url: http://projecteuler.net/problem=52
|
5
|
-
:content:
|
6
|
-
contain exactly the same digits, but in a different order
|
7
|
-
|
8
|
-
and
|
5
|
+
:content: |+
|
6
|
+
It can be seen that the number, 125874, and its double, 251748, contain exactly the same digits, but in a different order.
|
7
|
+
|
8
|
+
Find the smallest positive integer, _x_, such that 2_x_, 3_x_, 4_x_, 5_x_, and 6_x_, contain the same digits.
|
9
|
+
|
data/data/problems/53.yml
CHANGED
@@ -2,27 +2,18 @@
|
|
2
2
|
:id: 53
|
3
3
|
:name: Combinatoric selections
|
4
4
|
:url: http://projecteuler.net/problem=53
|
5
|
-
:content: "
|
6
|
-
|
7
|
-
|
8
|
-
|
9
|
-
|
10
|
-
|
11
|
-
|
12
|
-
|
13
|
-
|
14
|
-
src
|
15
|
-
|
16
|
-
|
17
|
-
src
|
18
|
-
|
19
|
-
|
20
|
-
width=\"9\" height=\"9\" alt=\"×\" border=\"0\" style=\"vertical-align:middle;\">2<img
|
21
|
-
src=\"images/symbol_times.gif\" width=\"9\" height=\"9\" alt=\"×\" border=\"0\"
|
22
|
-
style=\"vertical-align:middle;\">1, and 0! = 1.</td>\r\n</tr></table>\n</div>\r\n<p>It
|
23
|
-
is not until <var>n</var> = 23, that a value exceeds one-million: <sup>23</sup>C<sub>10</sub>
|
24
|
-
= 1144066.</p>\r\n<p>How many, not necessarily distinct, values of <sup><var>n</var></sup>C<sub><var>r</var></sub>,
|
25
|
-
for 1 <img src=\"images/symbol_le.gif\" width=\"10\" height=\"12\" alt=\"≤\" border=\"0\"
|
26
|
-
style=\"vertical-align:middle;\"><var>n</var> <img src=\"images/symbol_le.gif\"
|
27
|
-
width=\"10\" height=\"12\" alt=\"≤\" border=\"0\" style=\"vertical-align:middle;\">
|
28
|
-
100, are greater than one-million?</p>\r\n\r\n"
|
5
|
+
:content: "There are exactly ten ways of selecting three from five, 12345:\n\n123,
|
6
|
+
124, 125, 134, 135, 145, 234, 235, 245, and 345\n\nIn combinatorics, we use the
|
7
|
+
notation, <sup>5</sup>C<sub>3</sub> = 10.\n\nIn general,\n\n| <sup><var>n</var></sup>C<sub><var>r</var></sub>
|
8
|
+
= | \n<var>n</var>! \n<var>r</var>!(<var>n<img src=\"%7B%7B%20images_dir%20%7D%7D/symbol_minus.gif\"
|
9
|
+
width=\"9\" height=\"3\" alt=\"−\" border=\"0\" style=\"vertical-align:middle;\">r</var>)!\n
|
10
|
+
| ,where <var>r</var> ![≤](/home/will/src/euler-manager/config/../data/images/symbol_le.gif)
|
11
|
+
<var>n</var>, <var>n</var>! = <var>n</var> ![×](/home/will/src/euler-manager/config/../data/images/symbol_times.gif)(<var>n</var>
|
12
|
+
![−](/home/will/src/euler-manager/config/../data/images/symbol_minus.gif)1) ![×](/home/will/src/euler-manager/config/../data/images/symbol_times.gif)...
|
13
|
+
![×](/home/will/src/euler-manager/config/../data/images/symbol_times.gif)3 ![×](/home/will/src/euler-manager/config/../data/images/symbol_times.gif)2
|
14
|
+
![×](/home/will/src/euler-manager/config/../data/images/symbol_times.gif)1, and
|
15
|
+
0! = 1. |\n\nIt is not until <var>n</var> = 23, that a value exceeds one-million:
|
16
|
+
<sup>23</sup>C<sub>10</sub> = 1144066.\n\nHow many, not necessarily distinct, values
|
17
|
+
of <sup><var>n</var></sup>C<sub><var>r</var></sub>, for 1 ![≤](/home/will/src/euler-manager/config/../data/images/symbol_le.gif)
|
18
|
+
<var>n</var> ![≤](/home/will/src/euler-manager/config/../data/images/symbol_le.gif)
|
19
|
+
100, are greater than one-million?\n\n"
|
data/data/problems/54.yml
CHANGED
@@ -2,42 +2,32 @@
|
|
2
2
|
:id: 54
|
3
3
|
:name: Poker hands
|
4
4
|
:url: http://projecteuler.net/problem=54
|
5
|
-
:content: "
|
6
|
-
|
7
|
-
|
8
|
-
|
9
|
-
|
10
|
-
|
11
|
-
|
12
|
-
|
13
|
-
|
14
|
-
|
15
|
-
|
16
|
-
|
17
|
-
|
18
|
-
cards
|
19
|
-
|
20
|
-
|
21
|
-
|
22
|
-
|
23
|
-
|
24
|
-
|
25
|
-
|
26
|
-
|
27
|
-
|
28
|
-
|
29
|
-
|
30
|
-
|
31
|
-
|
32
|
-
|
33
|
-
|
34
|
-
style=\"vertical-align:top;\">Player 1</td>\r\n</tr>\n<tr>\n<td style=\"vertical-align:top;\"><b>5</b></td>\n<td> </td>\n<td>2H
|
35
|
-
2D 4C 4D 4S<br><div class=\"note\">Full House<br>With Three Fours</div>\n</td>\n<td> </td>\n<td>3C
|
36
|
-
3D 3S 9S 9D<br><div class=\"note\">Full House<br>with Three Threes</div>\n</td>\n<td> </td>\n<td
|
37
|
-
style=\"vertical-align:top;\">Player 1</td>\r\n</tr>\n</table>\n</div>\r\n<p>The
|
38
|
-
file, <a href=\"project/poker.txt\">poker.txt</a>, contains one-thousand random
|
39
|
-
hands dealt to two players. Each line of the file contains ten cards (separated
|
40
|
-
by a single space): the first five are Player 1's cards and the last five are Player
|
41
|
-
2's cards. You can assume that all hands are valid (no invalid characters or repeated
|
42
|
-
cards), each player's hand is in no specific order, and in each hand there is a
|
43
|
-
clear winner.</p>\r\n<p>How many hands does Player 1 win?</p>\r\n"
|
5
|
+
:content: "In the card game poker, a hand consists of five cards and are ranked, from
|
6
|
+
lowest to highest, in the following way:\n\n- **High Card** : Highest value card.\n-
|
7
|
+
**One Pair** : Two cards of the same value.\n- **Two Pairs** : Two different pairs.\n-
|
8
|
+
**Three of a Kind** : Three cards of the same value.\n- **Straight** : All cards
|
9
|
+
are consecutive values.\n- **Flush** : All cards of the same suit.\n- **Full House**
|
10
|
+
: Three of a kind and a pair.\n- **Four of a Kind** : Four cards of the same value.\n-
|
11
|
+
**Straight Flush** : All cards are consecutive values of same suit.\n- **Royal Flush**
|
12
|
+
: Ten, Jack, Queen, King, Ace, in same suit.\n\nThe cards are valued in the order:
|
13
|
+
\ \n2, 3, 4, 5, 6, 7, 8, 9, 10, Jack, Queen, King, Ace.\n\nIf two players have the
|
14
|
+
same ranked hands then the rank made up of the highest value wins; for example,
|
15
|
+
a pair of eights beats a pair of fives (see example 1 below). But if two ranks tie,
|
16
|
+
for example, both players have a pair of queens, then highest cards in each hand
|
17
|
+
are compared (see example 4 below); if the highest cards tie then the next highest
|
18
|
+
cards are compared, and so on.\n\nConsider the following five hands dealt to two
|
19
|
+
players:\n\n| **Hand** | | **Player 1** | | **Player 2** | | **Winner** |\n|
|
20
|
+
**1** | | 5H 5C 6S 7S KD \n\nPair of Fives\n | | 2C 3S 8S 8D TD \n\nPair of
|
21
|
+
Eights\n | | Player 2 |\n| **2** | | 5D 8C 9S JS AC \n\nHighest card Ace\n
|
22
|
+
| | 2C 5C 7D 8S QH \n\nHighest card Queen\n | | Player 1 |\n| **3** | | 2D
|
23
|
+
9C AS AH AC \n\nThree Aces\n | | 3D 6D 7D TD QD \n\nFlush with Diamonds\n |
|
24
|
+
| Player 2 |\n| **4** | | 4D 6S 9H QH QC \n\nPair of Queens \nHighest card
|
25
|
+
Nine\n | | 3D 6D 7H QD QS \n\nPair of Queens \nHighest card Seven\n | | Player
|
26
|
+
1 |\n| **5** | | 2H 2D 4C 4D 4S \n\nFull House \nWith Three Fours\n | | 3C
|
27
|
+
3D 3S 9S 9D \n\nFull House \nwith Three Threes\n | | Player 1 |\n\nThe file,
|
28
|
+
[poker.txt](project/poker.txt), contains one-thousand random hands dealt to two
|
29
|
+
players. Each line of the file contains ten cards (separated by a single space):
|
30
|
+
the first five are Player 1's cards and the last five are Player 2's cards. You
|
31
|
+
can assume that all hands are valid (no invalid characters or repeated cards), each
|
32
|
+
player's hand is in no specific order, and in each hand there is a clear winner.\n\nHow
|
33
|
+
many hands does Player 1 win?\n\n"
|
data/data/problems/55.yml
CHANGED
@@ -2,20 +2,19 @@
|
|
2
2
|
:id: 55
|
3
3
|
:name: Lychrel numbers
|
4
4
|
:url: http://projecteuler.net/problem=55
|
5
|
-
:content: "
|
6
|
-
all numbers produce palindromes so quickly. For example
|
7
|
-
+
|
8
|
-
|
9
|
-
|
10
|
-
|
11
|
-
|
12
|
-
|
13
|
-
|
14
|
-
(
|
15
|
-
|
16
|
-
|
17
|
-
|
18
|
-
|
19
|
-
|
20
|
-
|
21
|
-
the theoretical nature of Lychrel numbers.</p>\r\n"
|
5
|
+
:content: "If we take 47, reverse and add, 47 + 74 = 121, which is palindromic.\n\nNot
|
6
|
+
all numbers produce palindromes so quickly. For example,\n\n349 + 943 = 1292, \n\r1292
|
7
|
+
+ 2921 = 4213 \n\r4213 + 3124 = 7337\n\nThat is, 349 took three iterations to arrive
|
8
|
+
at a palindrome.\n\nAlthough no one has proved it yet, it is thought that some numbers,
|
9
|
+
like 196, never produce a palindrome. A number that never forms a palindrome through
|
10
|
+
the reverse and add process is called a Lychrel number. Due to the theoretical nature
|
11
|
+
of these numbers, and for the purpose of this problem, we shall assume that a number
|
12
|
+
is Lychrel until proven otherwise. In addition you are given that for every number
|
13
|
+
below ten-thousand, it will either (i) become a palindrome in less than fifty iterations,
|
14
|
+
or, (ii) no one, with all the computing power that exists, has managed so far to
|
15
|
+
map it to a palindrome. In fact, 10677 is the first number to be shown to require
|
16
|
+
over fifty iterations before producing a palindrome: 4668731596684224866951378664
|
17
|
+
(53 iterations, 28-digits).\n\nSurprisingly, there are palindromic numbers that
|
18
|
+
are themselves Lychrel numbers; the first example is 4994.\n\nHow many Lychrel numbers
|
19
|
+
are there below ten-thousand?\n\nNOTE: Wording was modified slightly on 24 April
|
20
|
+
2007 to emphasise the theoretical nature of Lychrel numbers.\n\n"
|
data/data/problems/56.yml
CHANGED
@@ -2,10 +2,8 @@
|
|
2
2
|
:id: 56
|
3
3
|
:name: Powerful digit sum
|
4
4
|
:url: http://projecteuler.net/problem=56
|
5
|
-
:content:
|
6
|
-
by one-hundred zeros; 100<sup>100</sup> is almost unimaginably large: one followed
|
7
|
-
|
8
|
-
|
9
|
-
|
10
|
-
border=\"0\" style=\"vertical-align:middle;\"> 100, what is the maximum digital
|
11
|
-
sum?</p>\n\r\n"
|
5
|
+
:content: |+
|
6
|
+
A googol (10<sup>100</sup>) is a massive number: one followed by one-hundred zeros; 100<sup>100</sup> is almost unimaginably large: one followed by two-hundred zeros. Despite their size, the sum of the digits in each number is only 1.
|
7
|
+
|
8
|
+
Considering natural numbers of the form, _a<sup>b</sup>_, where _a, b_ ![<](/home/will/src/euler-manager/config/../data/images/symbol_lt.gif) 100, what is the maximum digital sum?
|
9
|
+
|
data/data/problems/57.yml
CHANGED
@@ -2,14 +2,13 @@
|
|
2
2
|
:id: 57
|
3
3
|
:name: Square root convergents
|
4
4
|
:url: http://projecteuler.net/problem=57
|
5
|
-
:content: "
|
6
|
-
|
7
|
-
|
8
|
-
|
9
|
-
|
10
|
-
+ 1/2) =
|
11
|
-
|
12
|
-
|
13
|
-
|
14
|
-
|
15
|
-
many fractions contain a numerator with more digits than denominator?</p>\r\n\r\n"
|
5
|
+
:content: "It is possible to show that the square root of two can be expressed as
|
6
|
+
an infinite continued fraction.\n\n![√](/home/will/src/euler-manager/config/../data/images/symbol_radic.gif)
|
7
|
+
2 = 1 + 1/(2 + 1/(2 + 1/(2 + ... ))) = 1.414213...\n\nBy expanding this for the
|
8
|
+
first four iterations, we get:\n\n1 + 1/2 = 3/2 = 1.5 \n\r1 + 1/(2 + 1/2) = 7/5
|
9
|
+
= 1.4 \n\r1 + 1/(2 + 1/(2 + 1/2)) = 17/12 = 1.41666... \n\r1 + 1/(2 + 1/(2 + 1/(2
|
10
|
+
+ 1/2))) = 41/29 = 1.41379...\n\nThe next three expansions are 99/70, 239/169, and
|
11
|
+
577/408, but the eighth expansion, 1393/985, is the first example where the number
|
12
|
+
of digits in the numerator exceeds the number of digits in the denominator.\n\nIn
|
13
|
+
the first one-thousand expansions, how many fractions contain a numerator with more
|
14
|
+
digits than denominator?\n\n"
|
data/data/problems/58.yml
CHANGED
@@ -2,21 +2,14 @@
|
|
2
2
|
:id: 58
|
3
3
|
:name: Spiral primes
|
4
4
|
:url: http://projecteuler.net/problem=58
|
5
|
-
:content: "
|
6
|
-
|
7
|
-
|
8
|
-
|
9
|
-
|
10
|
-
|
11
|
-
|
12
|
-
|
13
|
-
|
14
|
-
|
15
|
-
|
16
|
-
the odd squares lie along the bottom right diagonal, but what is more interesting
|
17
|
-
is that 8 out of the 13 numbers lying along both diagonals are prime; that is, a
|
18
|
-
ratio of 8/13 <img src=\"images/symbol_asymp.gif\" width=\"11\" height=\"9\" alt=\"≈\"
|
19
|
-
border=\"0\" style=\"vertical-align:middle;\"> 62%.</p>\r\n<p>If one complete new
|
20
|
-
layer is wrapped around the spiral above, a square spiral with side length 9 will
|
21
|
-
be formed. If this process is continued, what is the side length of the square spiral
|
22
|
-
for which the ratio of primes along both diagonals first falls below 10%?</p>\r\n\r\n"
|
5
|
+
:content: "Starting with 1 and spiralling anticlockwise in the following way, a square
|
6
|
+
spiral with side length 7 is formed.\n\n**37** 36 35 34 33 32 **31** \n\r38 **17**
|
7
|
+
16 15 14 **13** 30 \n\r39 18 **5** 4 **3** 12 29 \n\r40 19 6 1 2 11 28
|
8
|
+
\ \n\r41 20 **7** 8 9 10 27 \n\r42 21 22 23 24 25 26 \n**43** 44 45 46 47
|
9
|
+
48 49\n\nIt is interesting to note that the odd squares lie along the bottom right
|
10
|
+
diagonal, but what is more interesting is that 8 out of the 13 numbers lying along
|
11
|
+
both diagonals are prime; that is, a ratio of 8/13 ![≈](/home/will/src/euler-manager/config/../data/images/symbol_asymp.gif)
|
12
|
+
62%.\n\nIf one complete new layer is wrapped around the spiral above, a square spiral
|
13
|
+
with side length 9 will be formed. If this process is continued, what is the side
|
14
|
+
length of the square spiral for which the ratio of primes along both diagonals first
|
15
|
+
falls below 10%?\n\n"
|
data/data/problems/59.yml
CHANGED
@@ -2,22 +2,14 @@
|
|
2
2
|
:id: 59
|
3
3
|
:name: XOR decryption
|
4
4
|
:url: http://projecteuler.net/problem=59
|
5
|
-
:content:
|
6
|
-
preferred standard is ASCII (American Standard Code for Information Interchange).
|
7
|
-
|
8
|
-
modern encryption method is to take a text file, convert the bytes to ASCII, then
|
9
|
-
|
10
|
-
|
11
|
-
|
12
|
-
|
13
|
-
|
14
|
-
the encryption key
|
15
|
-
|
16
|
-
users, so the modified method is to use a password as a key. If the password is
|
17
|
-
shorter than the message, which is likely, the key is repeated cyclically throughout
|
18
|
-
the message. The balance for this method is using a sufficiently long password key
|
19
|
-
for security, but short enough to be memorable.</p>\n<p>Your task has been made
|
20
|
-
easy, as the encryption key consists of three lower case characters. Using <a href=\"project/cipher1.txt\">cipher1.txt</a>
|
21
|
-
(right click and 'Save Link/Target As...'), a file containing the encrypted ASCII
|
22
|
-
codes, and the knowledge that the plain text must contain common English words,
|
23
|
-
decrypt the message and find the sum of the ASCII values in the original text.</p>\n\r\n"
|
5
|
+
:content: |+
|
6
|
+
Each character on a computer is assigned a unique code and the preferred standard is ASCII (American Standard Code for Information Interchange). For example, uppercase A = 65, asterisk (\*) = 42, and lowercase k = 107.
|
7
|
+
|
8
|
+
A modern encryption method is to take a text file, convert the bytes to ASCII, then XOR each byte with a given value, taken from a secret key. The advantage with the XOR function is that using the same encryption key on the cipher text, restores the plain text; for example, 65 XOR 42 = 107, then 107 XOR 42 = 65.
|
9
|
+
|
10
|
+
For unbreakable encryption, the key is the same length as the plain text message, and the key is made up of random bytes. The user would keep the encrypted message and the encryption key in different locations, and without both "halves", it is impossible to decrypt the message.
|
11
|
+
|
12
|
+
Unfortunately, this method is impractical for most users, so the modified method is to use a password as a key. If the password is shorter than the message, which is likely, the key is repeated cyclically throughout the message. The balance for this method is using a sufficiently long password key for security, but short enough to be memorable.
|
13
|
+
|
14
|
+
Your task has been made easy, as the encryption key consists of three lower case characters. Using [cipher1.txt](project/cipher1.txt) (right click and 'Save Link/Target As...'), a file containing the encrypted ASCII codes, and the knowledge that the plain text must contain common English words, decrypt the message and find the sum of the ASCII values in the original text.
|
15
|
+
|
data/data/problems/6.yml
CHANGED
@@ -2,12 +2,16 @@
|
|
2
2
|
:id: 6
|
3
3
|
:name: Sum square difference
|
4
4
|
:url: http://projecteuler.net/problem=6
|
5
|
-
:content:
|
6
|
-
|
7
|
-
|
8
|
-
|
9
|
-
|
10
|
-
|
11
|
-
|
12
|
-
|
13
|
-
|
5
|
+
:content: |+
|
6
|
+
The sum of the squares of the first ten natural numbers is,
|
7
|
+
|
8
|
+
1<sup>2</sup> + 2<sup>2</sup> + ... + 10<sup>2</sup> = 385
|
9
|
+
|
10
|
+
The square of the sum of the first ten natural numbers is,
|
11
|
+
|
12
|
+
(1 + 2 + ... + 10)<sup>2</sup> = 55<sup>2</sup> = 3025
|
13
|
+
|
14
|
+
Hence the difference between the sum of the squares of the first ten natural numbers and the square of the sum is 3025 ![−](/home/will/src/euler-manager/config/../data/images/symbol_minus.gif) 385 = 2640.
|
15
|
+
|
16
|
+
Find the difference between the sum of the squares of the first one hundred natural numbers and the square of the sum.
|
17
|
+
|
data/data/problems/60.yml
CHANGED
@@ -2,9 +2,8 @@
|
|
2
2
|
:id: 60
|
3
3
|
:name: Prime pair sets
|
4
4
|
:url: http://projecteuler.net/problem=60
|
5
|
-
:content:
|
6
|
-
any two primes and concatenating them in any order the result will always be prime.
|
7
|
-
|
8
|
-
|
9
|
-
|
10
|
-
produce another prime.</p>\n\r\n"
|
5
|
+
:content: |+
|
6
|
+
The primes 3, 7, 109, and 673, are quite remarkable. By taking any two primes and concatenating them in any order the result will always be prime. For example, taking 7 and 109, both 7109 and 1097 are prime. The sum of these four primes, 792, represents the lowest sum for a set of four primes with this property.
|
7
|
+
|
8
|
+
Find the lowest sum for a set of five primes for which any two primes concatenate to produce another prime.
|
9
|
+
|
data/data/problems/61.yml
CHANGED
@@ -2,29 +2,21 @@
|
|
2
2
|
:id: 61
|
3
3
|
:name: Cyclical figurate numbers
|
4
4
|
:url: http://projecteuler.net/problem=61
|
5
|
-
:content:
|
6
|
-
numbers are all figurate (polygonal) numbers and are generated by the following
|
7
|
-
|
8
|
-
|
9
|
-
|
10
|
-
src
|
11
|
-
|
12
|
-
|
13
|
-
src
|
14
|
-
|
15
|
-
|
16
|
-
|
17
|
-
|
18
|
-
|
19
|
-
|
20
|
-
|
21
|
-
|
22
|
-
|
23
|
-
in that the last two digits of each number is the first two digits of the next number
|
24
|
-
(including the last number with the first).</li>\r\n<li>Each polygonal type: triangle
|
25
|
-
(P<sub>3,127</sub>=8128), square (P<sub>4,91</sub>=8281), and pentagonal (P<sub>5,44</sub>=2882),
|
26
|
-
is represented by a different number in the set.</li>\r\n<li>This is the only set
|
27
|
-
of 4-digit numbers with this property.</li>\r\n</ol>\n<p>Find the sum of the only
|
28
|
-
ordered set of six cyclic 4-digit numbers for which each polygonal type: triangle,
|
29
|
-
square, pentagonal, hexagonal, heptagonal, and octagonal, is represented by a different
|
30
|
-
number in the set.</p>\r\n\r\n"
|
5
|
+
:content: |+
|
6
|
+
Triangle, square, pentagonal, hexagonal, heptagonal, and octagonal numbers are all figurate (polygonal) numbers and are generated by the following formulae:
|
7
|
+
|
8
|
+
| Triangle | | P<sub>3,<i>n</i></sub>=_n_(_n_+1)/2 | | 1, 3, 6, 10, 15, ... |
|
9
|
+
| Square | | P<sub>4,<i>n</i></sub>=_n_<sup>2</sup> | | 1, 4, 9, 16, 25, ... |
|
10
|
+
| Pentagonal | | P<sub>5,<i>n</i></sub>=_n_(3_n_ ![−](/home/will/src/euler-manager/config/../data/images/symbol_minus.gif)1)/2 | | 1, 5, 12, 22, 35, ... |
|
11
|
+
| Hexagonal | | P<sub>6,<i>n</i></sub>=_n_(2_n_ ![−](/home/will/src/euler-manager/config/../data/images/symbol_minus.gif)1) | | 1, 6, 15, 28, 45, ... |
|
12
|
+
| Heptagonal | | P<sub>7,<i>n</i></sub>=_n_(5_n_ ![−](/home/will/src/euler-manager/config/../data/images/symbol_minus.gif)3)/2 | | 1, 7, 18, 34, 55, ... |
|
13
|
+
| Octagonal | | P<sub>8,<i>n</i></sub>=_n_(3_n_ ![−](/home/will/src/euler-manager/config/../data/images/symbol_minus.gif)2) | | 1, 8, 21, 40, 65, ... |
|
14
|
+
|
15
|
+
The ordered set of three 4-digit numbers: 8128, 2882, 8281, has three interesting properties.
|
16
|
+
|
17
|
+
1. The set is cyclic, in that the last two digits of each number is the first two digits of the next number (including the last number with the first).
|
18
|
+
2. Each polygonal type: triangle (P<sub>3,127</sub>=8128), square (P<sub>4,91</sub>=8281), and pentagonal (P<sub>5,44</sub>=2882), is represented by a different number in the set.
|
19
|
+
3. This is the only set of 4-digit numbers with this property.
|
20
|
+
|
21
|
+
Find the sum of the only ordered set of six cyclic 4-digit numbers for which each polygonal type: triangle, square, pentagonal, hexagonal, heptagonal, and octagonal, is represented by a different number in the set.
|
22
|
+
|
data/data/problems/62.yml
CHANGED
@@ -2,8 +2,8 @@
|
|
2
2
|
:id: 62
|
3
3
|
:name: Cubic permutations
|
4
4
|
:url: http://projecteuler.net/problem=62
|
5
|
-
:content:
|
6
|
-
two other cubes: 56623104 (384<sup>3</sup>) and 66430125 (405<sup>3</sup>). In fact,
|
7
|
-
|
8
|
-
|
9
|
-
|
5
|
+
:content: |+
|
6
|
+
The cube, 41063625 (345<sup>3</sup>), can be permuted to produce two other cubes: 56623104 (384<sup>3</sup>) and 66430125 (405<sup>3</sup>). In fact, 41063625 is the smallest cube which has exactly three permutations of its digits which are also cube.
|
7
|
+
|
8
|
+
Find the smallest cube for which exactly five permutations of its digits are cube.
|
9
|
+
|
data/data/problems/63.yml
CHANGED
@@ -2,6 +2,8 @@
|
|
2
2
|
:id: 63
|
3
3
|
:name: Powerful digit counts
|
4
4
|
:url: http://projecteuler.net/problem=63
|
5
|
-
:content:
|
6
|
-
Similarly, the 9-digit number, 134217728=8<sup>9</sup>, is a ninth power
|
7
|
-
|
5
|
+
:content: |+
|
6
|
+
The 5-digit number, 16807=7<sup>5</sup>, is also a fifth power. Similarly, the 9-digit number, 134217728=8<sup>9</sup>, is a ninth power.
|
7
|
+
|
8
|
+
How many _n_-digit positive integers exist which are also an _n_th power?
|
9
|
+
|