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.
Files changed (645) hide show
  1. checksums.yaml +4 -4
  2. data/README.md +11 -1
  3. data/Rakefile +3 -0
  4. data/bin/euler +28 -9
  5. data/config/config.rb +1 -0
  6. data/data/answers.yml +430 -456
  7. data/data/images/blackdot.gif +0 -0
  8. data/data/images/bracket_left.gif +0 -0
  9. data/data/images/bracket_right.gif +0 -0
  10. data/data/images/p295_lenticular.gif +0 -0
  11. data/data/images/p296_bisector.gif +0 -0
  12. data/data/images/p303_formula100.gif +0 -0
  13. data/data/images/p303_formula10000.gif +0 -0
  14. data/data/images/p392_gridlines.png +0 -0
  15. data/data/images/p400_winning.png +0 -0
  16. data/data/images/p411_longpath.png +0 -0
  17. data/data/images/p412_table53.png +0 -0
  18. data/data/images/p412_tablenums.png +0 -0
  19. data/data/images/p422_hyperbola.gif +0 -0
  20. data/data/images/p428_necklace.png +0 -0
  21. data/data/images/p_015.gif +0 -0
  22. data/data/images/p_068_1.gif +0 -0
  23. data/data/images/p_068_2.gif +0 -0
  24. data/data/images/p_085.gif +0 -0
  25. data/data/images/p_086.gif +0 -0
  26. data/data/images/p_090.gif +0 -0
  27. data/data/images/p_091_1.gif +0 -0
  28. data/data/images/p_091_2.gif +0 -0
  29. data/data/images/p_107_1.gif +0 -0
  30. data/data/images/p_107_2.gif +0 -0
  31. data/data/images/p_109.gif +0 -0
  32. data/data/images/p_126.gif +0 -0
  33. data/data/images/p_128.gif +0 -0
  34. data/data/images/p_138.gif +0 -0
  35. data/data/images/p_139.gif +0 -0
  36. data/data/images/p_143_torricelli.gif +0 -0
  37. data/data/images/p_144_1.gif +0 -0
  38. data/data/images/p_144_2.gif +0 -0
  39. data/data/images/p_147.gif +0 -0
  40. data/data/images/p_150.gif +0 -0
  41. data/data/images/p_151.gif +0 -0
  42. data/data/images/p_152_sum.gif +0 -0
  43. data/data/images/p_153_formule1.gif +0 -0
  44. data/data/images/p_153_formule2.gif +0 -0
  45. data/data/images/p_153_formule5.gif +0 -0
  46. data/data/images/p_153_formule6.gif +0 -0
  47. data/data/images/p_154_pyramid.gif +0 -0
  48. data/data/images/p_155_capacitors1.gif +0 -0
  49. data/data/images/p_155_capsform.gif +0 -0
  50. data/data/images/p_155_capsmu.gif +0 -0
  51. data/data/images/p_161_k9.gif +0 -0
  52. data/data/images/p_161_trio1.gif +0 -0
  53. data/data/images/p_161_trio3.gif +0 -0
  54. data/data/images/p_163.gif +0 -0
  55. data/data/images/p_173_square_laminas.gif +0 -0
  56. data/data/images/p_177_quad.gif +0 -0
  57. data/data/images/p_184.gif +0 -0
  58. data/data/images/p_189_colours.gif +0 -0
  59. data/data/images/p_189_grid.gif +0 -0
  60. data/data/images/p_194_Fig.png +0 -0
  61. data/data/images/p_194_GraphA.png +0 -0
  62. data/data/images/p_194_GraphB.png +0 -0
  63. data/data/images/p_199_circles_in_circles.gif +0 -0
  64. data/data/images/p_201_laserbeam.gif +0 -0
  65. data/data/images/p_208_robotwalk.gif +0 -0
  66. data/data/images/p_215_crackfree.gif +0 -0
  67. data/data/images/p_220.gif +0 -0
  68. data/data/images/p_226_formula.gif +0 -0
  69. data/data/images/p_226_scoop2.gif +0 -0
  70. data/data/images/p_228.png +0 -0
  71. data/data/images/p_237.gif +0 -0
  72. data/data/images/p_244_example.gif +0 -0
  73. data/data/images/p_244_start.gif +0 -0
  74. data/data/images/p_244_target.gif +0 -0
  75. data/data/images/p_246_anim.gif +0 -0
  76. data/data/images/p_246_ellipse.gif +0 -0
  77. data/data/images/p_247_hypersquares.gif +0 -0
  78. data/data/images/p_251_cardano.gif +0 -0
  79. data/data/images/p_252_convexhole.gif +0 -0
  80. data/data/images/p_255_Example.gif +0 -0
  81. data/data/images/p_255_Heron.gif +0 -0
  82. data/data/images/p_256_tatami3.gif +0 -0
  83. data/data/images/p_257_bisector.gif +0 -0
  84. data/data/images/p_262_formula1.gif +0 -0
  85. data/data/images/p_264_TriangleCentres.gif +0 -0
  86. data/data/images/p_265_BinaryCircles.gif +0 -0
  87. data/data/images/p_270_CutSquare.gif +0 -0
  88. data/data/images/p_275_sculptures2.gif +0 -0
  89. data/data/images/p_281_pizza.gif +0 -0
  90. data/data/images/p_282_formula.gif +0 -0
  91. data/data/images/p_282formula3.gif +0 -0
  92. data/data/images/p_287_quadtree.gif +0 -0
  93. data/data/images/p_289_euler.gif +0 -0
  94. data/data/images/p_291_formula.gif +0 -0
  95. data/data/images/p_299_ThreeSimTri.gif +0 -0
  96. data/data/images/p_300_protein.gif +0 -0
  97. data/data/images/p_306_pstrip.gif +0 -0
  98. data/data/images/p_309_ladders.gif +0 -0
  99. data/data/images/p_311_biclinic.gif +0 -0
  100. data/data/images/p_312_sierpinsky8t.gif +0 -0
  101. data/data/images/p_312_sierpinskyAt.gif +0 -0
  102. data/data/images/p_313_sliding_game_1.gif +0 -0
  103. data/data/images/p_313_sliding_game_2.gif +0 -0
  104. data/data/images/p_314_landgrab.gif +0 -0
  105. data/data/images/p_315_clocks.gif +0 -0
  106. data/data/images/p_316_decexp1.gif +0 -0
  107. data/data/images/p_316_decexp2.gif +0 -0
  108. data/data/images/p_316_decexp3.gif +0 -0
  109. data/data/images/p_321_swapping_counters_1.gif +0 -0
  110. data/data/images/p_321_swapping_counters_2.gif +0 -0
  111. data/data/images/p_326_formula1.gif +0 -0
  112. data/data/images/p_326_formula2.gif +0 -0
  113. data/data/images/p_327_rooms_of_doom.gif +0 -0
  114. data/data/images/p_328_sum1.gif +0 -0
  115. data/data/images/p_328_sum2.gif +0 -0
  116. data/data/images/p_330_formula.gif +0 -0
  117. data/data/images/p_331_crossflips1.gif +0 -0
  118. data/data/images/p_331_crossflips2.gif +0 -0
  119. data/data/images/p_331_crossflips3.gif +0 -0
  120. data/data/images/p_332_spherical.jpg +0 -0
  121. data/data/images/p_332_sum.gif +0 -0
  122. data/data/images/p_334_beans.gif +0 -0
  123. data/data/images/p_334_cases.gif +0 -0
  124. data/data/images/p_334_lfloor.gif +0 -0
  125. data/data/images/p_334_oplus.gif +0 -0
  126. data/data/images/p_334_rfloor.gif +0 -0
  127. data/data/images/p_335_mancala.gif +0 -0
  128. data/data/images/p_335_sum.gif +0 -0
  129. data/data/images/p_336_maximix.gif +0 -0
  130. data/data/images/p_338_gridpaper.gif +0 -0
  131. data/data/images/p_340_formula.gif +0 -0
  132. data/data/images/p_344_silverdollar.gif +0 -0
  133. data/data/images/p_351_hexorchard.png +0 -0
  134. data/data/images/p_354_bee_honeycomb.png +0 -0
  135. data/data/images/p_356_cubicpoly1.gif +0 -0
  136. data/data/images/p_356_cubicpoly2.gif +0 -0
  137. data/data/images/p_361_Thue-Morse1.gif +0 -0
  138. data/data/images/p_364_comf_dist.gif +0 -0
  139. data/data/images/p_372_pencilray1.jpg +0 -0
  140. data/data/images/p_372_pencilray2.gif +0 -0
  141. data/data/images/p_380_mazes.gif +0 -0
  142. data/data/images/p_384_formula.gif +0 -0
  143. data/data/images/p_385_ellipsetriangle.png +0 -0
  144. data/data/images/p_394_eatpie.gif +0 -0
  145. data/data/images/p_395_pythagorean.gif +0 -0
  146. data/data/images/p_404_c_ellipse.gif +0 -0
  147. data/data/images/p_405_tile1.png +0 -0
  148. data/data/images/p_405_tile2.gif +0 -0
  149. data/data/images/p_420_matrix.gif +0 -0
  150. data/data/images/p_424_kakuro1.gif +0 -0
  151. data/data/images/p_426_baxball1.gif +0 -0
  152. data/data/images/p_426_baxball2.gif +0 -0
  153. data/data/images/p_430_flips.gif +0 -0
  154. data/data/images/sod_13.gif +115 -0
  155. data/data/images/spacer.gif +0 -0
  156. data/data/images/symbol_asymp.gif +0 -0
  157. data/data/images/symbol_cong.gif +0 -0
  158. data/data/images/symbol_ge.gif +0 -0
  159. data/data/images/symbol_gt.gif +0 -0
  160. data/data/images/symbol_implies.gif +0 -0
  161. data/data/images/symbol_lceil.gif +0 -0
  162. data/data/images/symbol_le.gif +0 -0
  163. data/data/images/symbol_lfloor.gif +0 -0
  164. data/data/images/symbol_lt.gif +0 -0
  165. data/data/images/symbol_maps.gif +0 -0
  166. data/data/images/symbol_minus.gif +0 -0
  167. data/data/images/symbol_ne.gif +0 -0
  168. data/data/images/symbol_plusmn.gif +0 -0
  169. data/data/images/symbol_radic.gif +0 -0
  170. data/data/images/symbol_rceil.gif +0 -0
  171. data/data/images/symbol_rfloor.gif +0 -0
  172. data/data/images/symbol_sum.gif +0 -0
  173. data/data/images/symbol_times.gif +0 -0
  174. data/data/problems/1.yml +5 -3
  175. data/data/problems/10.yml +3 -4
  176. data/data/problems/100.yml +7 -9
  177. data/data/problems/101.yml +32 -45
  178. data/data/problems/102.yml +11 -12
  179. data/data/problems/103.yml +18 -22
  180. data/data/problems/104.yml +9 -11
  181. data/data/problems/105.yml +12 -17
  182. data/data/problems/106.yml +14 -15
  183. data/data/problems/107.yml +16 -16
  184. data/data/problems/108.yml +17 -28
  185. data/data/problems/109.yml +27 -29
  186. data/data/problems/11.yml +24 -29
  187. data/data/problems/110.yml +11 -15
  188. data/data/problems/111.yml +27 -17
  189. data/data/problems/112.yml +13 -11
  190. data/data/problems/113.yml +11 -9
  191. data/data/problems/114.yml +46 -100
  192. data/data/problems/115.yml +15 -12
  193. data/data/problems/116.yml +33 -72
  194. data/data/problems/117.yml +36 -78
  195. data/data/problems/118.yml +5 -5
  196. data/data/problems/119.yml +9 -7
  197. data/data/problems/12.yml +8 -9
  198. data/data/problems/120.yml +7 -13
  199. data/data/problems/121.yml +9 -11
  200. data/data/problems/122.yml +21 -38
  201. data/data/problems/123.yml +9 -9
  202. data/data/problems/124.yml +24 -54
  203. data/data/problems/125.yml +7 -8
  204. data/data/problems/126.yml +12 -13
  205. data/data/problems/127.yml +21 -27
  206. data/data/problems/128.yml +19 -14
  207. data/data/problems/129.yml +9 -8
  208. data/data/problems/13.yml +52 -2
  209. data/data/problems/130.yml +12 -15
  210. data/data/problems/131.yml +9 -8
  211. data/data/problems/132.yml +7 -8
  212. data/data/problems/133.yml +9 -9
  213. data/data/problems/134.yml +7 -15
  214. data/data/problems/135.yml +9 -16
  215. data/data/problems/136.yml +9 -13
  216. data/data/problems/137.yml +22 -32
  217. data/data/problems/138.yml +11 -16
  218. data/data/problems/139.yml +11 -11
  219. data/data/problems/14.yml +14 -24
  220. data/data/problems/140.yml +18 -25
  221. data/data/problems/141.yml +10 -11
  222. data/data/problems/142.yml +3 -10
  223. data/data/problems/143.yml +13 -16
  224. data/data/problems/144.yml +23 -26
  225. data/data/problems/145.yml +7 -7
  226. data/data/problems/146.yml +6 -6
  227. data/data/problems/147.yml +7 -8
  228. data/data/problems/148.yml +15 -7
  229. data/data/problems/149.yml +26 -35
  230. data/data/problems/15.yml +7 -7
  231. data/data/problems/150.yml +18 -29
  232. data/data/problems/151.yml +17 -15
  233. data/data/problems/152.yml +11 -8
  234. data/data/problems/153.yml +38 -53
  235. data/data/problems/154.yml +10 -12
  236. data/data/problems/155.yml +12 -15
  237. data/data/problems/156.yml +20 -22
  238. data/data/problems/157.yml +26 -28
  239. data/data/problems/158.yml +13 -14
  240. data/data/problems/159.yml +15 -25
  241. data/data/problems/16.yml +5 -2
  242. data/data/problems/160.yml +3 -4
  243. data/data/problems/161.yml +6 -10
  244. data/data/problems/162.yml +10 -11
  245. data/data/problems/163.yml +13 -15
  246. data/data/problems/164.yml +3 -3
  247. data/data/problems/165.yml +25 -28
  248. data/data/problems/166.yml +7 -11
  249. data/data/problems/167.yml +10 -12
  250. data/data/problems/168.yml +7 -9
  251. data/data/problems/169.yml +4 -5
  252. data/data/problems/17.yml +7 -7
  253. data/data/problems/170.yml +7 -10
  254. data/data/problems/171.yml +7 -9
  255. data/data/problems/172.yml +3 -2
  256. data/data/problems/173.yml +9 -7
  257. data/data/problems/174.yml +13 -15
  258. data/data/problems/175.yml +13 -15
  259. data/data/problems/176.yml +5 -5
  260. data/data/problems/177.yml +13 -12
  261. data/data/problems/178.yml +5 -5
  262. data/data/problems/179.yml +3 -6
  263. data/data/problems/18.yml +13 -17
  264. data/data/problems/180.yml +20 -25
  265. data/data/problems/181.yml +7 -3
  266. data/data/problems/182.yml +22 -27
  267. data/data/problems/183.yml +17 -23
  268. data/data/problems/184.yml +11 -14
  269. data/data/problems/185.yml +17 -18
  270. data/data/problems/186.yml +16 -24
  271. data/data/problems/187.yml +9 -12
  272. data/data/problems/188.yml +5 -6
  273. data/data/problems/189.yml +5 -7
  274. data/data/problems/19.yml +7 -8
  275. data/data/problems/190.yml +7 -9
  276. data/data/problems/191.yml +9 -10
  277. data/data/problems/192.yml +14 -22
  278. data/data/problems/193.yml +5 -3
  279. data/data/problems/194.yml +11 -14
  280. data/data/problems/195.yml +7 -9
  281. data/data/problems/196.yml +13 -21
  282. data/data/problems/197.yml +7 -11
  283. data/data/problems/198.yml +13 -16
  284. data/data/problems/199.yml +10 -10
  285. data/data/problems/2.yml +6 -6
  286. data/data/problems/20.yml +10 -18
  287. data/data/problems/200.yml +8 -8
  288. data/data/problems/201.yml +14 -16
  289. data/data/problems/202.yml +11 -10
  290. data/data/problems/203.yml +11 -16
  291. data/data/problems/204.yml +7 -7
  292. data/data/problems/205.yml +6 -6
  293. data/data/problems/206.yml +2 -2
  294. data/data/problems/207.yml +13 -16
  295. data/data/problems/208.yml +8 -8
  296. data/data/problems/209.yml +11 -23
  297. data/data/problems/21.yml +8 -9
  298. data/data/problems/210.yml +6 -6
  299. data/data/problems/211.yml +7 -7
  300. data/data/problems/212.yml +26 -36
  301. data/data/problems/213.yml +6 -7
  302. data/data/problems/214.yml +10 -11
  303. data/data/problems/215.yml +11 -14
  304. data/data/problems/216.yml +7 -10
  305. data/data/problems/217.yml +14 -23
  306. data/data/problems/218.yml +9 -10
  307. data/data/problems/219.yml +10 -15
  308. data/data/problems/22.yml +7 -9
  309. data/data/problems/220.yml +15 -20
  310. data/data/problems/221.yml +10 -16
  311. data/data/problems/222.yml +5 -3
  312. data/data/problems/223.yml +6 -8
  313. data/data/problems/224.yml +6 -8
  314. data/data/problems/225.yml +6 -7
  315. data/data/problems/226.yml +9 -12
  316. data/data/problems/227.yml +9 -9
  317. data/data/problems/228.yml +14 -17
  318. data/data/problems/229.yml +17 -25
  319. data/data/problems/23.yml +11 -15
  320. data/data/problems/230.yml +15 -19
  321. data/data/problems/231.yml +8 -12
  322. data/data/problems/232.yml +9 -10
  323. data/data/problems/233.yml +7 -6
  324. data/data/problems/234.yml +14 -19
  325. data/data/problems/235.yml +4 -5
  326. data/data/problems/236.yml +20 -22
  327. data/data/problems/237.yml +14 -9
  328. data/data/problems/238.yml +21 -33
  329. data/data/problems/239.yml +5 -5
  330. data/data/problems/24.yml +7 -6
  331. data/data/problems/240.yml +7 -7
  332. data/data/problems/241.yml +9 -12
  333. data/data/problems/242.yml +7 -9
  334. data/data/problems/243.yml +14 -15
  335. data/data/problems/244.yml +19 -28
  336. data/data/problems/245.yml +22 -30
  337. data/data/problems/246.yml +10 -13
  338. data/data/problems/247.yml +14 -17
  339. data/data/problems/248.yml +5 -2
  340. data/data/problems/249.yml +3 -3
  341. data/data/problems/25.yml +12 -11
  342. data/data/problems/250.yml +3 -3
  343. data/data/problems/251.yml +11 -9
  344. data/data/problems/252.yml +24 -25
  345. data/data/problems/253.yml +19 -32
  346. data/data/problems/254.yml +13 -17
  347. data/data/problems/255.yml +40 -50
  348. data/data/problems/256.yml +31 -39
  349. data/data/problems/257.yml +10 -14
  350. data/data/problems/258.yml +7 -9
  351. data/data/problems/259.yml +14 -12
  352. data/data/problems/26.yml +17 -7
  353. data/data/problems/260.yml +21 -25
  354. data/data/problems/261.yml +13 -15
  355. data/data/problems/262.yml +15 -16
  356. data/data/problems/263.yml +13 -15
  357. data/data/problems/264.yml +15 -16
  358. data/data/problems/265.yml +10 -12
  359. data/data/problems/266.yml +6 -6
  360. data/data/problems/267.yml +13 -10
  361. data/data/problems/268.yml +5 -4
  362. data/data/problems/269.yml +10 -11
  363. data/data/problems/27.yml +15 -21
  364. data/data/problems/270.yml +13 -13
  365. data/data/problems/271.yml +7 -9
  366. data/data/problems/272.yml +8 -11
  367. data/data/problems/273.yml +13 -17
  368. data/data/problems/274.yml +16 -19
  369. data/data/problems/275.yml +13 -15
  370. data/data/problems/276.yml +5 -7
  371. data/data/problems/277.yml +17 -20
  372. data/data/problems/278.yml +20 -28
  373. data/data/problems/279.yml +4 -3
  374. data/data/problems/28.yml +6 -13
  375. data/data/problems/280.yml +9 -9
  376. data/data/problems/281.yml +10 -13
  377. data/data/problems/282.yml +9 -6
  378. data/data/problems/283.yml +8 -8
  379. data/data/problems/284.yml +15 -18
  380. data/data/problems/285.yml +11 -11
  381. data/data/problems/286.yml +7 -8
  382. data/data/problems/287.yml +22 -32
  383. data/data/problems/288.yml +10 -11
  384. data/data/problems/289.yml +14 -15
  385. data/data/problems/29.yml +13 -20
  386. data/data/problems/290.yml +3 -4
  387. data/data/problems/291.yml +3 -6
  388. data/data/problems/292.yml +8 -9
  389. data/data/problems/293.yml +9 -10
  390. data/data/problems/294.yml +6 -6
  391. data/data/problems/295.yml +16 -21
  392. data/data/problems/296.yml +9 -11
  393. data/data/problems/297.yml +12 -15
  394. data/data/problems/298.yml +29 -29
  395. data/data/problems/299.yml +15 -21
  396. data/data/problems/3.yml +3 -3
  397. data/data/problems/30.yml +7 -8
  398. data/data/problems/300.yml +15 -16
  399. data/data/problems/301.yml +15 -17
  400. data/data/problems/302.yml +13 -14
  401. data/data/problems/303.yml +9 -7
  402. data/data/problems/304.yml +10 -15
  403. data/data/problems/305.yml +6 -10
  404. data/data/problems/306.yml +20 -24
  405. data/data/problems/307.yml +7 -8
  406. data/data/problems/308.yml +19 -30
  407. data/data/problems/309.yml +11 -12
  408. data/data/problems/31.yml +11 -14
  409. data/data/problems/310.yml +10 -15
  410. data/data/problems/311.yml +11 -17
  411. data/data/problems/312.yml +10 -11
  412. data/data/problems/313.yml +13 -13
  413. data/data/problems/314.yml +23 -25
  414. data/data/problems/315.yml +39 -45
  415. data/data/problems/316.yml +13 -13
  416. data/data/problems/317.yml +6 -7
  417. data/data/problems/318.yml +35 -57
  418. data/data/problems/319.yml +15 -19
  419. data/data/problems/32.yml +9 -10
  420. data/data/problems/320.yml +9 -8
  421. data/data/problems/321.yml +8 -9
  422. data/data/problems/322.yml +6 -8
  423. data/data/problems/323.yml +12 -15
  424. data/data/problems/324.yml +10 -13
  425. data/data/problems/325.yml +15 -21
  426. data/data/problems/326.yml +15 -8
  427. data/data/problems/327.yml +19 -23
  428. data/data/problems/328.yml +28 -31
  429. data/data/problems/329.yml +12 -13
  430. data/data/problems/33.yml +9 -9
  431. data/data/problems/330.yml +17 -36
  432. data/data/problems/331.yml +16 -22
  433. data/data/problems/332.yml +9 -11
  434. data/data/problems/333.yml +17 -20
  435. data/data/problems/334.yml +22 -34
  436. data/data/problems/335.yml +11 -12
  437. data/data/problems/336.yml +18 -20
  438. data/data/problems/337.yml +9 -11
  439. data/data/problems/338.yml +27 -37
  440. data/data/problems/339.yml +9 -9
  441. data/data/problems/34.yml +7 -3
  442. data/data/problems/340.yml +8 -10
  443. data/data/problems/341.yml +12 -14
  444. data/data/problems/342.yml +9 -13
  445. data/data/problems/343.yml +18 -25
  446. data/data/problems/344.yml +16 -17
  447. data/data/problems/345.yml +17 -22
  448. data/data/problems/346.yml +7 -7
  449. data/data/problems/347.yml +9 -12
  450. data/data/problems/348.yml +7 -8
  451. data/data/problems/349.yml +8 -9
  452. data/data/problems/35.yml +7 -4
  453. data/data/problems/350.yml +12 -14
  454. data/data/problems/351.yml +8 -9
  455. data/data/problems/352.yml +38 -42
  456. data/data/problems/353.yml +17 -21
  457. data/data/problems/354.yml +11 -13
  458. data/data/problems/355.yml +4 -4
  459. data/data/problems/356.yml +6 -6
  460. data/data/problems/357.yml +5 -5
  461. data/data/problems/358.yml +16 -25
  462. data/data/problems/359.yml +19 -22
  463. data/data/problems/36.yml +7 -4
  464. data/data/problems/360.yml +8 -8
  465. data/data/problems/361.yml +14 -15
  466. data/data/problems/362.yml +16 -28
  467. data/data/problems/363.yml +22 -23
  468. data/data/problems/364.yml +9 -11
  469. data/data/problems/365.yml +7 -13
  470. data/data/problems/366.yml +19 -22
  471. data/data/problems/367.yml +14 -15
  472. data/data/problems/368.yml +18 -35
  473. data/data/problems/369.yml +7 -11
  474. data/data/problems/37.yml +7 -6
  475. data/data/problems/370.yml +10 -13
  476. data/data/problems/371.yml +8 -9
  477. data/data/problems/372.yml +9 -12
  478. data/data/problems/373.yml +5 -6
  479. data/data/problems/374.yml +17 -21
  480. data/data/problems/375.yml +13 -17
  481. data/data/problems/376.yml +19 -21
  482. data/data/problems/377.yml +6 -7
  483. data/data/problems/378.yml +8 -11
  484. data/data/problems/379.yml +9 -11
  485. data/data/problems/38.yml +9 -13
  486. data/data/problems/380.yml +14 -17
  487. data/data/problems/381.yml +12 -18
  488. data/data/problems/382.yml +16 -19
  489. data/data/problems/383.yml +7 -9
  490. data/data/problems/384.yml +20 -24
  491. data/data/problems/385.yml +12 -16
  492. data/data/problems/386.yml +9 -11
  493. data/data/problems/387.yml +14 -15
  494. data/data/problems/388.yml +6 -8
  495. data/data/problems/389.yml +8 -8
  496. data/data/problems/39.yml +7 -6
  497. data/data/problems/390.yml +9 -14
  498. data/data/problems/391.yml +21 -25
  499. data/data/problems/392.yml +16 -17
  500. data/data/problems/393.yml +5 -6
  501. data/data/problems/394.yml +15 -18
  502. data/data/problems/395.yml +12 -13
  503. data/data/problems/396.yml +17 -22
  504. data/data/problems/397.yml +13 -16
  505. data/data/problems/398.yml +8 -9
  506. data/data/problems/399.yml +18 -18
  507. data/data/problems/4.yml +5 -4
  508. data/data/problems/40.yml +11 -14
  509. data/data/problems/400.yml +10 -11
  510. data/data/problems/401.yml +6 -7
  511. data/data/problems/402.yml +16 -21
  512. data/data/problems/403.yml +12 -14
  513. data/data/problems/404.yml +14 -16
  514. data/data/problems/405.yml +10 -11
  515. data/data/problems/406.yml +35 -41
  516. data/data/problems/407.yml +9 -16
  517. data/data/problems/408.yml +9 -9
  518. data/data/problems/409.yml +5 -7
  519. data/data/problems/41.yml +5 -4
  520. data/data/problems/410.yml +10 -13
  521. data/data/problems/411.yml +15 -19
  522. data/data/problems/412.yml +11 -15
  523. data/data/problems/413.yml +8 -8
  524. data/data/problems/414.yml +29 -34
  525. data/data/problems/415.yml +12 -15
  526. data/data/problems/416.yml +7 -7
  527. data/data/problems/417.yml +16 -17
  528. data/data/problems/418.yml +9 -12
  529. data/data/problems/419.yml +13 -18
  530. data/data/problems/42.yml +9 -10
  531. data/data/problems/420.yml +5 -6
  532. data/data/problems/421.yml +14 -25
  533. data/data/problems/422.yml +16 -18
  534. data/data/problems/423.yml +16 -18
  535. data/data/problems/424.yml +18 -19
  536. data/data/problems/425.yml +11 -12
  537. data/data/problems/426.yml +20 -21
  538. data/data/problems/427.yml +11 -13
  539. data/data/problems/428.yml +21 -25
  540. data/data/problems/429.yml +6 -6
  541. data/data/problems/43.yml +15 -13
  542. data/data/problems/430.yml +14 -16
  543. data/data/problems/44.yml +9 -12
  544. data/data/problems/45.yml +11 -11
  545. data/data/problems/46.yml +9 -14
  546. data/data/problems/47.yml +11 -16
  547. data/data/problems/48.yml +5 -3
  548. data/data/problems/49.yml +7 -6
  549. data/data/problems/5.yml +5 -4
  550. data/data/problems/50.yml +11 -6
  551. data/data/problems/51.yml +9 -11
  552. data/data/problems/52.yml +5 -4
  553. data/data/problems/53.yml +15 -24
  554. data/data/problems/54.yml +29 -39
  555. data/data/problems/55.yml +16 -17
  556. data/data/problems/56.yml +5 -7
  557. data/data/problems/57.yml +10 -11
  558. data/data/problems/58.yml +11 -18
  559. data/data/problems/59.yml +11 -19
  560. data/data/problems/6.yml +13 -9
  561. data/data/problems/60.yml +5 -6
  562. data/data/problems/61.yml +18 -26
  563. data/data/problems/62.yml +5 -5
  564. data/data/problems/63.yml +5 -3
  565. data/data/problems/64.yml +52 -126
  566. data/data/problems/65.yml +21 -47
  567. data/data/problems/66.yml +13 -23
  568. data/data/problems/67.yml +10 -13
  569. data/data/problems/68.yml +15 -19
  570. data/data/problems/69.yml +18 -10
  571. data/data/problems/7.yml +5 -2
  572. data/data/problems/70.yml +10 -12
  573. data/data/problems/71.yml +11 -13
  574. data/data/problems/72.yml +11 -12
  575. data/data/problems/73.yml +11 -12
  576. data/data/problems/74.yml +25 -37
  577. data/data/problems/75.yml +10 -12
  578. data/data/problems/76.yml +4 -4
  579. data/data/problems/77.yml +4 -4
  580. data/data/problems/78.yml +13 -8
  581. data/data/problems/79.yml +7 -7
  582. data/data/problems/8.yml +14 -8
  583. data/data/problems/80.yml +7 -7
  584. data/data/problems/81.yml +9 -15
  585. data/data/problems/82.yml +10 -15
  586. data/data/problems/83.yml +10 -19
  587. data/data/problems/84.yml +36 -59
  588. data/data/problems/85.yml +7 -5
  589. data/data/problems/86.yml +11 -11
  590. data/data/problems/87.yml +7 -8
  591. data/data/problems/88.yml +30 -49
  592. data/data/problems/89.yml +13 -14
  593. data/data/problems/9.yml +6 -9
  594. data/data/problems/90.yml +16 -18
  595. data/data/problems/91.yml +10 -15
  596. data/data/problems/92.yml +14 -25
  597. data/data/problems/93.yml +13 -17
  598. data/data/problems/94.yml +7 -7
  599. data/data/problems/95.yml +13 -19
  600. data/data/problems/96.yml +24 -40
  601. data/data/problems/97.yml +7 -10
  602. data/data/problems/98.yml +9 -12
  603. data/data/problems/99.yml +9 -12
  604. data/euler-manager.gemspec +1 -0
  605. data/example/1/README.md +4 -4
  606. data/example/15/README.md +8 -0
  607. data/example/15/python/15.py +5 -0
  608. data/example/15/python/euler.py +0 -0
  609. data/example/2/README.md +7 -5
  610. data/example/Eulerfile.rb +1 -0
  611. data/lib/euler/problem.rb +6 -1
  612. data/lib/euler/solution.rb +4 -2
  613. data/lib/euler/version.rb +1 -1
  614. data/rake/clean.rake +16 -0
  615. data/rake/update.rake +88 -0
  616. data/spec/euler/solution_spec.rb +2 -1
  617. data/templates/Eulerfile.rb +12 -0
  618. metadata +189 -29
  619. data/data/problems/431.yml +0 -33
  620. data/data/problems/432.yml +0 -13
  621. data/data/problems/433.yml +0 -18
  622. data/data/problems/434.yml +0 -32
  623. data/data/problems/435.yml +0 -21
  624. data/data/problems/436.yml +0 -21
  625. data/data/problems/437.yml +0 -22
  626. data/data/problems/438.yml +0 -29
  627. data/data/problems/439.yml +0 -17
  628. data/data/problems/440.yml +0 -21
  629. data/data/problems/441.yml +0 -23
  630. data/data/problems/442.yml +0 -9
  631. data/data/problems/443.yml +0 -13
  632. data/data/problems/444.yml +0 -28
  633. data/data/problems/445.yml +0 -37
  634. data/data/problems/446.yml +0 -29
  635. data/data/problems/447.yml +0 -31
  636. data/data/problems/448.yml +0 -14
  637. data/data/problems/449.yml +0 -17
  638. data/data/problems/450.yml +0 -26
  639. data/data/problems/451.yml +0 -15
  640. data/data/problems/452.yml +0 -8
  641. data/data/problems/453.yml +0 -16
  642. data/data/problems/454.yml +0 -17
  643. data/data/problems/455.yml +0 -16
  644. data/data/problems/456.yml +0 -15
  645. data/scripts/update_problems +0 -68
data/data/problems/88.yml CHANGED
@@ -2,52 +2,33 @@
2
2
  :id: 88
3
3
  :name: Product-sum numbers
4
4
  :url: http://projecteuler.net/problem=88
5
- :content: "\r\n\n<p>A natural number, N, that can be written as the sum and product
6
- of a given set of at least two natural numbers, {<i>a</i><sub>1</sub>, <i>a</i><sub>2</sub>,
7
- ... , <i>a</i><sub><i>k</i></sub>} is called a product-sum number: N = <i>a</i><sub>1</sub>
8
- + <i>a</i><sub>2</sub> + ... + <i>a</i><sub><i>k</i></sub> = <i>a</i><sub>1</sub><img
9
- src=\"images/symbol_times.gif\" width=\"9\" height=\"9\" alt=\"×\" border=\"0\"
10
- style=\"vertical-align:middle;\"><i>a</i><sub>2</sub><img src=\"images/symbol_times.gif\"
11
- width=\"9\" height=\"9\" alt=\"×\" border=\"0\" style=\"vertical-align:middle;\">
12
- ... <img src=\"images/symbol_times.gif\" width=\"9\" height=\"9\" alt=\"×\" border=\"0\"
13
- style=\"vertical-align:middle;\"><i>a</i><sub><i>k</i></sub>.</p>\n<p>For example,
14
- 6 = 1 + 2 + 3 = 1 <img src=\"images/symbol_times.gif\" width=\"9\" height=\"9\"
15
- alt=\"×\" border=\"0\" style=\"vertical-align:middle;\"> 2 <img src=\"images/symbol_times.gif\"
16
- width=\"9\" height=\"9\" alt=\"×\" border=\"0\" style=\"vertical-align:middle;\">
17
- 3.</p>\n<p>For a given set of size, <i>k</i>, we shall call the smallest N with
18
- this property a minimal product-sum number. The minimal product-sum numbers for
19
- sets of size, <i>k</i> = 2, 3, 4, 5, and 6 are as follows.</p>\n<p style=\"margin-left:50px;\"><i>k</i>=2:
20
- 4 = 2 <img src=\"images/symbol_times.gif\" width=\"9\" height=\"9\" alt=\"×\" border=\"0\"
21
- style=\"vertical-align:middle;\"> 2 = 2 + 2<br><i>k</i>=3: 6 = 1 <img src=\"images/symbol_times.gif\"
22
- width=\"9\" height=\"9\" alt=\"×\" border=\"0\" style=\"vertical-align:middle;\">
23
- 2 <img src=\"images/symbol_times.gif\" width=\"9\" height=\"9\" alt=\"×\" border=\"0\"
24
- style=\"vertical-align:middle;\"> 3 = 1 + 2 + 3<br><i>k</i>=4: 8 = 1 <img src=\"images/symbol_times.gif\"
25
- width=\"9\" height=\"9\" alt=\"×\" border=\"0\" style=\"vertical-align:middle;\">
26
- 1 <img src=\"images/symbol_times.gif\" width=\"9\" height=\"9\" alt=\"×\" border=\"0\"
27
- style=\"vertical-align:middle;\"> 2 <img src=\"images/symbol_times.gif\" width=\"9\"
28
- height=\"9\" alt=\"×\" border=\"0\" style=\"vertical-align:middle;\"> 4 = 1 + 1
29
- + 2 + 4<br><i>k</i>=5: 8 = 1 <img src=\"images/symbol_times.gif\" width=\"9\" height=\"9\"
30
- alt=\"×\" border=\"0\" style=\"vertical-align:middle;\"> 1 <img src=\"images/symbol_times.gif\"
31
- width=\"9\" height=\"9\" alt=\"×\" border=\"0\" style=\"vertical-align:middle;\">
32
- 2 <img src=\"images/symbol_times.gif\" width=\"9\" height=\"9\" alt=\"×\" border=\"0\"
33
- style=\"vertical-align:middle;\"> 2 <img src=\"images/symbol_times.gif\" width=\"9\"
34
- height=\"9\" alt=\"×\" border=\"0\" style=\"vertical-align:middle;\"> 2 = 1 + 1
35
- + 2 + 2 + 2<br><i>k</i>=6: 12 = 1 <img src=\"images/symbol_times.gif\" width=\"9\"
36
- height=\"9\" alt=\"×\" border=\"0\" style=\"vertical-align:middle;\"> 1 <img src=\"images/symbol_times.gif\"
37
- width=\"9\" height=\"9\" alt=\"×\" border=\"0\" style=\"vertical-align:middle;\">
38
- 1 <img src=\"images/symbol_times.gif\" width=\"9\" height=\"9\" alt=\"×\" border=\"0\"
39
- style=\"vertical-align:middle;\"> 1 <img src=\"images/symbol_times.gif\" width=\"9\"
40
- height=\"9\" alt=\"×\" border=\"0\" style=\"vertical-align:middle;\"> 2 <img src=\"images/symbol_times.gif\"
41
- width=\"9\" height=\"9\" alt=\"×\" border=\"0\" style=\"vertical-align:middle;\">
42
- 6 = 1 + 1 + 1 + 1 + 2 + 6</p>\n<p>Hence for 2<img src=\"images/symbol_le.gif\" width=\"10\"
43
- height=\"12\" alt=\"≤\" border=\"0\" style=\"vertical-align:middle;\"><i>k</i><img
44
- src=\"images/symbol_le.gif\" width=\"10\" height=\"12\" alt=\"≤\" border=\"0\" style=\"vertical-align:middle;\">6,
45
- the sum of all the minimal product-sum numbers is 4+6+8+12 = 30; note that 8 is
46
- only counted once in the sum.</p>\n<p>In fact, as the complete set of minimal product-sum
47
- numbers for 2<img src=\"images/symbol_le.gif\" width=\"10\" height=\"12\" alt=\"≤\"
48
- border=\"0\" style=\"vertical-align:middle;\"><i>k</i><img src=\"images/symbol_le.gif\"
49
- width=\"10\" height=\"12\" alt=\"≤\" border=\"0\" style=\"vertical-align:middle;\">12
50
- is {4, 6, 8, 12, 15, 16}, the sum is 61.</p>\n<p>What is the sum of all the minimal
51
- product-sum numbers for 2<img src=\"images/symbol_le.gif\" width=\"10\" height=\"12\"
52
- alt=\"≤\" border=\"0\" style=\"vertical-align:middle;\"><i>k</i><img src=\"images/symbol_le.gif\"
53
- width=\"10\" height=\"12\" alt=\"≤\" border=\"0\" style=\"vertical-align:middle;\">12000?</p>\n\r\n"
5
+ :content: "A natural number, N, that can be written as the sum and product of a given
6
+ set of at least two natural numbers, {_a_<sub>1</sub>, _a_<sub>2</sub>, ... , _a_<sub><i>k</i></sub>}
7
+ is called a product-sum number: N = _a_<sub>1</sub> + _a_<sub>2</sub> + ... + _a_<sub><i>k</i></sub>
8
+ = _a_<sub>1</sub> ![×](/home/will/src/euler-manager/config/../data/images/symbol_times.gif)
9
+ _a_<sub>2</sub> ![×](/home/will/src/euler-manager/config/../data/images/symbol_times.gif)
10
+ ... ![×](/home/will/src/euler-manager/config/../data/images/symbol_times.gif) _a_<sub><i>k</i></sub>.\n\nFor
11
+ example, 6 = 1 + 2 + 3 = 1 ![×](/home/will/src/euler-manager/config/../data/images/symbol_times.gif)
12
+ 2 ![×](/home/will/src/euler-manager/config/../data/images/symbol_times.gif) 3.\n\nFor
13
+ a given set of size, _k_, we shall call the smallest N with this property a minimal
14
+ product-sum number. The minimal product-sum numbers for sets of size, _k_ = 2, 3,
15
+ 4, 5, and 6 are as follows.\n\n_k_=2: 4 = 2 ![×](/home/will/src/euler-manager/config/../data/images/symbol_times.gif)
16
+ 2 = 2 + 2 \n_k_=3: 6 = 1 ![×](/home/will/src/euler-manager/config/../data/images/symbol_times.gif)
17
+ 2 ![×](/home/will/src/euler-manager/config/../data/images/symbol_times.gif) 3 =
18
+ 1 + 2 + 3 \n_k_=4: 8 = 1 ![×](/home/will/src/euler-manager/config/../data/images/symbol_times.gif)
19
+ 1 ![×](/home/will/src/euler-manager/config/../data/images/symbol_times.gif) 2 ![×](/home/will/src/euler-manager/config/../data/images/symbol_times.gif)
20
+ 4 = 1 + 1 + 2 + 4 \n_k_=5: 8 = 1 ![×](/home/will/src/euler-manager/config/../data/images/symbol_times.gif)
21
+ 1 ![×](/home/will/src/euler-manager/config/../data/images/symbol_times.gif) 2 ![×](/home/will/src/euler-manager/config/../data/images/symbol_times.gif)
22
+ 2 ![×](/home/will/src/euler-manager/config/../data/images/symbol_times.gif) 2 =
23
+ 1 + 1 + 2 + 2 + 2 \n_k_=6: 12 = 1 ![×](/home/will/src/euler-manager/config/../data/images/symbol_times.gif)
24
+ 1 ![×](/home/will/src/euler-manager/config/../data/images/symbol_times.gif) 1 ![×](/home/will/src/euler-manager/config/../data/images/symbol_times.gif)
25
+ 1 ![×](/home/will/src/euler-manager/config/../data/images/symbol_times.gif) 2 ![×](/home/will/src/euler-manager/config/../data/images/symbol_times.gif)
26
+ 6 = 1 + 1 + 1 + 1 + 2 + 6\n\nHence for 2 ![≤](/home/will/src/euler-manager/config/../data/images/symbol_le.gif)_k_
27
+ ![≤](/home/will/src/euler-manager/config/../data/images/symbol_le.gif)6, the sum
28
+ of all the minimal product-sum numbers is 4+6+8+12 = 30; note that 8 is only counted
29
+ once in the sum.\n\nIn fact, as the complete set of minimal product-sum numbers
30
+ for 2 ![≤](/home/will/src/euler-manager/config/../data/images/symbol_le.gif)_k_
31
+ ![≤](/home/will/src/euler-manager/config/../data/images/symbol_le.gif)12 is {4,
32
+ 6, 8, 12, 15, 16}, the sum is 61.\n\nWhat is the sum of all the minimal product-sum
33
+ numbers for 2 ![≤](/home/will/src/euler-manager/config/../data/images/symbol_le.gif)_k_
34
+ ![≤](/home/will/src/euler-manager/config/../data/images/symbol_le.gif)12000?\n\n"
data/data/problems/89.yml CHANGED
@@ -2,17 +2,16 @@
2
2
  :id: 89
3
3
  :name: Roman numerals
4
4
  :url: http://projecteuler.net/problem=89
5
- :content: "\r\n<p>The rules for writing Roman numerals allow for many ways of writing
6
- each number (see <a href=\"about=roman_numerals\">About Roman Numerals...</a>).
7
- However, there is always a \"best\" way of writing a particular number.</p>\r\n<p>For
8
- example, the following represent all of the legitimate ways of writing the number
9
- sixteen:</p>\r\n<p style=\"margin-left:50px;font-family:courier new,monospace;\">IIIIIIIIIIIIIIII<br>\r\nVIIIIIIIIIII<br>\r\nVVIIIIII<br>\r\nXIIIIII<br>\r\nVVVI<br>\r\nXVI</p>\r\n<p>The
10
- last example being considered the most efficient, as it uses the least number of
11
- numerals.</p>\r\n<p>The 11K text file, <a href=\"project/roman.txt\">roman.txt</a>
12
- (right click and 'Save Link/Target As...'), contains one thousand numbers written
13
- in valid, but not necessarily minimal, Roman numerals; that is, they are arranged
14
- in descending units and obey the subtractive pair rule (see <a href=\"about=roman_numerals\">About
15
- Roman Numerals...</a> for the definitive rules for this problem).</p>\r\n<p>Find
16
- the number of characters saved by writing each of these in their minimal form.</p>\r\n<p
17
- class=\"note\">Note: You can assume that all the Roman numerals in the file contain
18
- no more than four consecutive identical units.</p>\r\n\r\n"
5
+ :content: "The rules for writing Roman numerals allow for many ways of writing each
6
+ number (see [About Roman Numerals...](about=roman_numerals)). However, there is
7
+ always a \"best\" way of writing a particular number.\n\nFor example, the following
8
+ represent all of the legitimate ways of writing the number sixteen:\n\nIIIIIIIIIIIIIIII
9
+ \ \n\rVIIIIIIIIIII \n\rVVIIIIII \n\rXIIIIII \n\rVVVI \n\rXVI\n\nThe last example
10
+ being considered the most efficient, as it uses the least number of numerals.\n\nThe
11
+ 11K text file, [roman.txt](project/roman.txt) (right click and 'Save Link/Target
12
+ As...'), contains one thousand numbers written in valid, but not necessarily minimal,
13
+ Roman numerals; that is, they are arranged in descending units and obey the subtractive
14
+ pair rule (see [About Roman Numerals...](about=roman_numerals) for the definitive
15
+ rules for this problem).\n\nFind the number of characters saved by writing each
16
+ of these in their minimal form.\n\nNote: You can assume that all the Roman numerals
17
+ in the file contain no more than four consecutive identical units.\n\n"
data/data/problems/9.yml CHANGED
@@ -2,12 +2,9 @@
2
2
  :id: 9
3
3
  :name: Special Pythagorean triplet
4
4
  :url: http://projecteuler.net/problem=9
5
- :content: "\r\n<p>A Pythagorean triplet is a set of three natural numbers, <var>a</var>
6
- <img src=\"images/symbol_lt.gif\" width=\"10\" height=\"10\" alt=\"&lt;\" border=\"0\"
7
- style=\"vertical-align:middle;\"><var>b</var> <img src=\"images/symbol_lt.gif\"
8
- width=\"10\" height=\"10\" alt=\"&lt;\" border=\"0\" style=\"vertical-align:middle;\"><var>c</var>,
9
- for which,</p>\r\n<div style=\"text-align:center;\"> <var>a</var><sup>2</sup> +
10
- <var>b</var><sup>2</sup> = <var>c</var><sup>2</sup>\n</div>\r\n<p>For example, 3<sup>2</sup>
11
- + 4<sup>2</sup> = 9 + 16 = 25 = 5<sup>2</sup>.</p>\r\n<p>There exists exactly one
12
- Pythagorean triplet for which <var>a</var> + <var>b</var> + <var>c</var> = 1000.<br>Find
13
- the product <var>abc</var>.</p>\r\n\r\n"
5
+ :content: "A Pythagorean triplet is a set of three natural numbers, <var>a</var> ![<](/home/will/src/euler-manager/config/../data/images/symbol_lt.gif)
6
+ <var>b</var> ![<](/home/will/src/euler-manager/config/../data/images/symbol_lt.gif)
7
+ <var>c</var>, for which,\n\n <var>a</var><sup>2</sup> + <var>b</var><sup>2</sup>
8
+ = <var>c</var><sup>2</sup>\n\nFor example, 3<sup>2</sup> + 4<sup>2</sup> = 9 + 16
9
+ = 25 = 5<sup>2</sup>.\n\nThere exists exactly one Pythagorean triplet for which
10
+ <var>a</var> + <var>b</var> + <var>c</var> = 1000. \nFind the product <var>abc</var>.\n\n"
data/data/problems/90.yml CHANGED
@@ -2,22 +2,20 @@
2
2
  :id: 90
3
3
  :name: Cube digit pairs
4
4
  :url: http://projecteuler.net/problem=90
5
- :content: "\r\n<p>Each of the six faces on a cube has a different digit (0 to 9) written
5
+ :content: "Each of the six faces on a cube has a different digit (0 to 9) written
6
6
  on it; the same is done to a second cube. By placing the two cubes side-by-side
7
- in different positions we can form a variety of 2-digit numbers.</p>\r\n\r\n<p>For
8
- example, the square number 64 could be formed:</p>\r\n\r\n<div style=\"text-align:center;\">\r\n<img
9
- src=\"project/images/p_090.gif\" alt=\"\"><br>\n</div>\r\n\r\n<p>In fact, by carefully
10
- choosing the digits on both cubes it is possible to display all of the square numbers
11
- below one-hundred: 01, 04, 09, 16, 25, 36, 49, 64, and 81.</p>\r\n\r\n<p>For example,
12
- one way this can be achieved is by placing {0, 5, 6, 7, 8, 9} on one cube and {1,
13
- 2, 3, 4, 8, 9} on the other cube.</p>\r\n\r\n<p>However, for this problem we shall
14
- allow the 6 or 9 to be turned upside-down so that an arrangement like {0, 5, 6,
15
- 7, 8, 9} and {1, 2, 3, 4, 6, 7} allows for all nine square numbers to be displayed;
16
- otherwise it would be impossible to obtain 09.</p>\r\n\r\n<p>In determining a distinct
17
- arrangement we are interested in the digits on each cube, not the order.</p>\r\n\r\n<p
18
- style=\"margin-left:50px;\">{1, 2, 3, 4, 5, 6} is equivalent to {3, 6, 4, 1, 2,
19
- 5}<br>\r\n{1, 2, 3, 4, 5, 6} is distinct from {1, 2, 3, 4, 5, 9}</p>\r\n\r\n<p>But
20
- because we are allowing 6 and 9 to be reversed, the two distinct sets in the last
21
- example both represent the extended set {1, 2, 3, 4, 5, 6, 9} for the purpose of
22
- forming 2-digit numbers.</p>\r\n\r\n<p>How many distinct arrangements of the two
23
- cubes allow for all of the square numbers to be displayed?</p>\r\n"
7
+ in different positions we can form a variety of 2-digit numbers.\n\nFor example,
8
+ the square number 64 could be formed:\n\n ![](/home/will/src/euler-manager/config/../data/images/p_090.gif)
9
+ \ \n\nIn fact, by carefully choosing the digits on both cubes it is possible to
10
+ display all of the square numbers below one-hundred: 01, 04, 09, 16, 25, 36, 49,
11
+ 64, and 81.\n\nFor example, one way this can be achieved is by placing {0, 5, 6,
12
+ 7, 8, 9} on one cube and {1, 2, 3, 4, 8, 9} on the other cube.\n\nHowever, for this
13
+ problem we shall allow the 6 or 9 to be turned upside-down so that an arrangement
14
+ like {0, 5, 6, 7, 8, 9} and {1, 2, 3, 4, 6, 7} allows for all nine square numbers
15
+ to be displayed; otherwise it would be impossible to obtain 09.\n\nIn determining
16
+ a distinct arrangement we are interested in the digits on each cube, not the order.\n\n{1,
17
+ 2, 3, 4, 5, 6} is equivalent to {3, 6, 4, 1, 2, 5} \n\r{1, 2, 3, 4, 5, 6} is distinct
18
+ from {1, 2, 3, 4, 5, 9}\n\nBut because we are allowing 6 and 9 to be reversed, the
19
+ two distinct sets in the last example both represent the extended set {1, 2, 3,
20
+ 4, 5, 6, 9} for the purpose of forming 2-digit numbers.\n\nHow many distinct arrangements
21
+ of the two cubes allow for all of the square numbers to be displayed?\n\n"
data/data/problems/91.yml CHANGED
@@ -2,18 +2,13 @@
2
2
  :id: 91
3
3
  :name: Right triangles with integer coordinates
4
4
  :url: http://projecteuler.net/problem=91
5
- :content: "\r\n<p>The points P (<i>x</i><sub>1</sub>, <i>y</i><sub>1</sub>) and Q
6
- (<i>x</i><sub>2</sub>, <i>y</i><sub>2</sub>) are plotted at integer co-ordinates
7
- and are joined to the origin, O(0,0), to form ΔOPQ.</p>\r\n\r\n<div style=\"text-align:center;\">\r\n<img
8
- src=\"project/images/p_091_1.gif\" alt=\"\"><br>\n</div>\r\n\r\n<p>There are exactly
9
- fourteen triangles containing a right angle that can be formed when each co-ordinate
10
- lies between 0 and 2 inclusive; that is,<br>0 <img src=\"images/symbol_le.gif\"
11
- width=\"10\" height=\"12\" alt=\"≤\" border=\"0\" style=\"vertical-align:middle;\"><i>x</i><sub>1</sub>,
12
- <i>y</i><sub>1</sub>, <i>x</i><sub>2</sub>, <i>y</i><sub>2</sub><img src=\"images/symbol_le.gif\"
13
- width=\"10\" height=\"12\" alt=\"≤\" border=\"0\" style=\"vertical-align:middle;\">
14
- 2.</p>\r\n\r\n<div style=\"text-align:center;\">\r\n<img src=\"project/images/p_091_2.gif\"
15
- alt=\"\"><br>\n</div>\r\n\r\n<p>Given that 0 <img src=\"images/symbol_le.gif\" width=\"10\"
16
- height=\"12\" alt=\"≤\" border=\"0\" style=\"vertical-align:middle;\"><i>x</i><sub>1</sub>,
17
- <i>y</i><sub>1</sub>, <i>x</i><sub>2</sub>, <i>y</i><sub>2</sub><img src=\"images/symbol_le.gif\"
18
- width=\"10\" height=\"12\" alt=\"≤\" border=\"0\" style=\"vertical-align:middle;\">
19
- 50, how many right triangles can be formed?</p>\r\n"
5
+ :content: "The points P (_x_<sub>1</sub>, _y_<sub>1</sub>) and Q (_x_<sub>2</sub>,
6
+ _y_<sub>2</sub>) are plotted at integer co-ordinates and are joined to the origin,
7
+ O(0,0), to form ΔOPQ.\n\n ![](/home/will/src/euler-manager/config/../data/images/p_091_1.gif)
8
+ \ \n\nThere are exactly fourteen triangles containing a right angle that can be
9
+ formed when each co-ordinate lies between 0 and 2 inclusive; that is, \n0 ![≤](/home/will/src/euler-manager/config/../data/images/symbol_le.gif)
10
+ _x_<sub>1</sub>, _y_<sub>1</sub>, _x_<sub>2</sub>, _y_<sub>2</sub> ![≤](/home/will/src/euler-manager/config/../data/images/symbol_le.gif)
11
+ 2.\n\n ![](/home/will/src/euler-manager/config/../data/images/p_091_2.gif) \n\nGiven
12
+ that 0 ![≤](/home/will/src/euler-manager/config/../data/images/symbol_le.gif) _x_<sub>1</sub>,
13
+ _y_<sub>1</sub>, _x_<sub>2</sub>, _y_<sub>2</sub> ![≤](/home/will/src/euler-manager/config/../data/images/symbol_le.gif)
14
+ 50, how many right triangles can be formed?\n\n"
data/data/problems/92.yml CHANGED
@@ -2,28 +2,17 @@
2
2
  :id: 92
3
3
  :name: Square digit chains
4
4
  :url: http://projecteuler.net/problem=92
5
- :content: "\r\n\n<p>A number chain is created by continuously adding the square of
6
- the digits in a number to form a new number until it has been seen before.</p>\n<p>For
7
- example,</p>\n<p style=\"margin-left:50px;\">44 <img src=\"images/symbol_maps.gif\"
8
- width=\"15\" height=\"7\" alt=\"→\" border=\"0\" style=\"vertical-align:middle;\">
9
- 32 <img src=\"images/symbol_maps.gif\" width=\"15\" height=\"7\" alt=\"→\" border=\"0\"
10
- style=\"vertical-align:middle;\"> 13 <img src=\"images/symbol_maps.gif\" width=\"15\"
11
- height=\"7\" alt=\"→\" border=\"0\" style=\"vertical-align:middle;\"> 10 <img src=\"images/symbol_maps.gif\"
12
- width=\"15\" height=\"7\" alt=\"→\" border=\"0\" style=\"vertical-align:middle;\"><b>1</b>
13
- <img src=\"images/symbol_maps.gif\" width=\"15\" height=\"7\" alt=\"→\" border=\"0\"
14
- style=\"vertical-align:middle;\"><b>1</b><br>\n85 <img src=\"images/symbol_maps.gif\"
15
- width=\"15\" height=\"7\" alt=\"→\" border=\"0\" style=\"vertical-align:middle;\"><b>89</b>
16
- <img src=\"images/symbol_maps.gif\" width=\"15\" height=\"7\" alt=\"→\" border=\"0\"
17
- style=\"vertical-align:middle;\"> 145 <img src=\"images/symbol_maps.gif\" width=\"15\"
18
- height=\"7\" alt=\"→\" border=\"0\" style=\"vertical-align:middle;\"> 42 <img src=\"images/symbol_maps.gif\"
19
- width=\"15\" height=\"7\" alt=\"→\" border=\"0\" style=\"vertical-align:middle;\">
20
- 20 <img src=\"images/symbol_maps.gif\" width=\"15\" height=\"7\" alt=\"→\" border=\"0\"
21
- style=\"vertical-align:middle;\"> 4 <img src=\"images/symbol_maps.gif\" width=\"15\"
22
- height=\"7\" alt=\"→\" border=\"0\" style=\"vertical-align:middle;\"> 16 <img src=\"images/symbol_maps.gif\"
23
- width=\"15\" height=\"7\" alt=\"→\" border=\"0\" style=\"vertical-align:middle;\">
24
- 37 <img src=\"images/symbol_maps.gif\" width=\"15\" height=\"7\" alt=\"→\" border=\"0\"
25
- style=\"vertical-align:middle;\"> 58 <img src=\"images/symbol_maps.gif\" width=\"15\"
26
- height=\"7\" alt=\"→\" border=\"0\" style=\"vertical-align:middle;\"><b>89</b></p>\n<p>Therefore
27
- any chain that arrives at 1 or 89 will become stuck in an endless loop. What is
28
- most amazing is that EVERY starting number will eventually arrive at 1 or 89.</p>\n<p>How
29
- many starting numbers below ten million will arrive at 89?</p>\n\r\n"
5
+ :content: "A number chain is created by continuously adding the square of the digits
6
+ in a number to form a new number until it has been seen before.\n\nFor example,\n\n44
7
+ ![→](/home/will/src/euler-manager/config/../data/images/symbol_maps.gif) 32 ![→](/home/will/src/euler-manager/config/../data/images/symbol_maps.gif)
8
+ 13 ![→](/home/will/src/euler-manager/config/../data/images/symbol_maps.gif) 10 ![→](/home/will/src/euler-manager/config/../data/images/symbol_maps.gif)
9
+ **1** ![→](/home/will/src/euler-manager/config/../data/images/symbol_maps.gif) **1**
10
+ \ \n85 ![→](/home/will/src/euler-manager/config/../data/images/symbol_maps.gif)
11
+ **89** ![→](/home/will/src/euler-manager/config/../data/images/symbol_maps.gif)
12
+ 145 ![→](/home/will/src/euler-manager/config/../data/images/symbol_maps.gif) 42
13
+ ![→](/home/will/src/euler-manager/config/../data/images/symbol_maps.gif) 20 ![→](/home/will/src/euler-manager/config/../data/images/symbol_maps.gif)
14
+ 4 ![→](/home/will/src/euler-manager/config/../data/images/symbol_maps.gif) 16 ![→](/home/will/src/euler-manager/config/../data/images/symbol_maps.gif)
15
+ 37 ![→](/home/will/src/euler-manager/config/../data/images/symbol_maps.gif) 58 ![→](/home/will/src/euler-manager/config/../data/images/symbol_maps.gif)
16
+ **89**\n\nTherefore any chain that arrives at 1 or 89 will become stuck in an endless
17
+ loop. What is most amazing is that EVERY starting number will eventually arrive
18
+ at 1 or 89.\n\nHow many starting numbers below ten million will arrive at 89?\n\n"
data/data/problems/93.yml CHANGED
@@ -2,20 +2,16 @@
2
2
  :id: 93
3
3
  :name: Arithmetic expressions
4
4
  :url: http://projecteuler.net/problem=93
5
- :content: "\r\n\n<p>By using each of the digits from the set, {1, 2, 3, 4}, exactly
6
- once, and making use of the four arithmetic operations (+, <img src=\"images/symbol_minus.gif\"
7
- width=\"9\" height=\"3\" alt=\"−\" border=\"0\" style=\"vertical-align:middle;\">,
8
- *, /) and brackets/parentheses, it is possible to form different positive integer
9
- targets.</p>\n<p>For example,</p>\n<p style=\"margin-left:50px;font-family:courier
10
- new;\">8 = (4 * (1 + 3)) / 2<br>\n14 = 4 * (3 + 1 / 2)<br>\n19 = 4 * (2 + 3) <img
11
- src=\"images/symbol_minus.gif\" width=\"9\" height=\"3\" alt=\"−\" border=\"0\"
12
- style=\"vertical-align:middle;\"> 1<br>\n36 = 3 * 4 * (2 + 1)</p>\n<p>Note that
13
- concatenations of the digits, like 12 + 34, are not allowed.</p>\n<p>Using the set,
14
- {1, 2, 3, 4}, it is possible to obtain thirty-one different target numbers of which
15
- 36 is the maximum, and each of the numbers 1 to 28 can be obtained before encountering
16
- the first non-expressible number.</p>\n<p>Find the set of four distinct digits,
17
- <i>a</i> <img src=\"images/symbol_lt.gif\" width=\"10\" height=\"10\" alt=\"&lt;\"
18
- border=\"0\" style=\"vertical-align:middle;\"><i>b</i> &amp;lt <i>c</i> <img src=\"images/symbol_lt.gif\"
19
- width=\"10\" height=\"10\" alt=\"&lt;\" border=\"0\" style=\"vertical-align:middle;\"><i>d</i>,
20
- for which the longest set of consecutive positive integers, 1 to <i>n</i>, can be
21
- obtained, giving your answer as a string: <i>abcd</i>.</p>\n\r\n"
5
+ :content: "By using each of the digits from the set, {1, 2, 3, 4}, exactly once, and
6
+ making use of the four arithmetic operations (+, ![−](/home/will/src/euler-manager/config/../data/images/symbol_minus.gif),
7
+ \\*, /) and brackets/parentheses, it is possible to form different positive integer
8
+ targets.\n\nFor example,\n\n8 = (4 \\* (1 + 3)) / 2 \n14 = 4 \\* (3 + 1 / 2) \n19
9
+ = 4 \\* (2 + 3) ![−](/home/will/src/euler-manager/config/../data/images/symbol_minus.gif)
10
+ 1 \n36 = 3 \\* 4 \\* (2 + 1)\n\nNote that concatenations of the digits, like 12
11
+ + 34, are not allowed.\n\nUsing the set, {1, 2, 3, 4}, it is possible to obtain
12
+ thirty-one different target numbers of which 36 is the maximum, and each of the
13
+ numbers 1 to 28 can be obtained before encountering the first non-expressible number.\n\nFind
14
+ the set of four distinct digits, _a_ ![<](/home/will/src/euler-manager/config/../data/images/symbol_lt.gif)
15
+ _b_ &lt _c_ ![<](/home/will/src/euler-manager/config/../data/images/symbol_lt.gif)
16
+ _d_, for which the longest set of consecutive positive integers, 1 to _n_, can be
17
+ obtained, giving your answer as a string: _abcd_.\n\n"
data/data/problems/94.yml CHANGED
@@ -2,10 +2,10 @@
2
2
  :id: 94
3
3
  :name: Almost equilateral triangles
4
4
  :url: http://projecteuler.net/problem=94
5
- :content: "\r\n<p>It is easily proved that no equilateral triangle exists with integral
6
- length sides and integral area. However, the <i>almost equilateral triangle</i>
7
- 5-5-6 has an area of 12 square units.</p>\r\n<p>We shall define an <i>almost equilateral
8
- triangle</i> to be a triangle for which two sides are equal and the third differs
9
- by no more than one unit.</p>\r\n<p>Find the sum of the perimeters of all <i>almost
10
- equilateral triangles</i> with integral side lengths and area and whose perimeters
11
- do not exceed one billion (1,000,000,000).</p>\r\n\r\n"
5
+ :content: |+
6
+ It is easily proved that no equilateral triangle exists with integral length sides and integral area. However, the _almost equilateral triangle_ 5-5-6 has an area of 12 square units.
7
+
8
+ We shall define an _almost equilateral triangle_ to be a triangle for which two sides are equal and the third differs by no more than one unit.
9
+
10
+ Find the sum of the perimeters of all _almost equilateral triangles_ with integral side lengths and area and whose perimeters do not exceed one billion (1,000,000,000).
11
+
data/data/problems/95.yml CHANGED
@@ -2,22 +2,16 @@
2
2
  :id: 95
3
3
  :name: Amicable chains
4
4
  :url: http://projecteuler.net/problem=95
5
- :content: "\r\n<p>The proper divisors of a number are all the divisors excluding the
6
- number itself. For example, the proper divisors of 28 are 1, 2, 4, 7, and 14. As
7
- the sum of these divisors is equal to 28, we call it a perfect number.</p>\r\n<p>Interestingly
8
- the sum of the proper divisors of 220 is 284 and the sum of the proper divisors
9
- of 284 is 220, forming a chain of two numbers. For this reason, 220 and 284 are
10
- called an amicable pair.</p>\r\n<p>Perhaps less well known are longer chains. For
11
- example, starting with 12496, we form a chain of five numbers:</p>\r\n<p style=\"text-align:center;\">12496
12
- <img src=\"images/symbol_maps.gif\" width=\"15\" height=\"7\" alt=\"→\" border=\"0\"
13
- style=\"vertical-align:middle;\"> 14288 <img src=\"images/symbol_maps.gif\" width=\"15\"
14
- height=\"7\" alt=\"→\" border=\"0\" style=\"vertical-align:middle;\"> 15472 <img
15
- src=\"images/symbol_maps.gif\" width=\"15\" height=\"7\" alt=\"→\" border=\"0\"
16
- style=\"vertical-align:middle;\"> 14536 <img src=\"images/symbol_maps.gif\" width=\"15\"
17
- height=\"7\" alt=\"→\" border=\"0\" style=\"vertical-align:middle;\"> 14264 (<img
18
- src=\"images/symbol_maps.gif\" width=\"15\" height=\"7\" alt=\"→\" border=\"0\"
19
- style=\"vertical-align:middle;\"> 12496 <img src=\"images/symbol_maps.gif\" width=\"15\"
20
- height=\"7\" alt=\"→\" border=\"0\" style=\"vertical-align:middle;\"> ...)</p>\r\n<p>Since
21
- this chain returns to its starting point, it is called an amicable chain.</p>\r\n<p>Find
22
- the smallest member of the longest amicable chain with no element exceeding one
23
- million.</p>\r\n\r\n"
5
+ :content: |+
6
+ The proper divisors of a number are all the divisors excluding the number itself. For example, the proper divisors of 28 are 1, 2, 4, 7, and 14. As the sum of these divisors is equal to 28, we call it a perfect number.
7
+
8
+ Interestingly the sum of the proper divisors of 220 is 284 and the sum of the proper divisors of 284 is 220, forming a chain of two numbers. For this reason, 220 and 284 are called an amicable pair.
9
+
10
+ Perhaps less well known are longer chains. For example, starting with 12496, we form a chain of five numbers:
11
+
12
+ 12496 ![→](/home/will/src/euler-manager/config/../data/images/symbol_maps.gif) 14288 ![→](/home/will/src/euler-manager/config/../data/images/symbol_maps.gif) 15472 ![→](/home/will/src/euler-manager/config/../data/images/symbol_maps.gif) 14536 ![→](/home/will/src/euler-manager/config/../data/images/symbol_maps.gif) 14264 ( ![→](/home/will/src/euler-manager/config/../data/images/symbol_maps.gif) 12496 ![→](/home/will/src/euler-manager/config/../data/images/symbol_maps.gif) ...)
13
+
14
+ Since this chain returns to its starting point, it is called an amicable chain.
15
+
16
+ Find the smallest member of the longest amicable chain with no element exceeding one million.
17
+
data/data/problems/96.yml CHANGED
@@ -2,45 +2,29 @@
2
2
  :id: 96
3
3
  :name: Su Doku
4
4
  :url: http://projecteuler.net/problem=96
5
- :content: "\r\n<p>Su Doku (Japanese meaning <i>number place</i>) is the name given
6
- to a popular puzzle concept. Its origin is unclear, but credit must be attributed
7
- to Leonhard Euler who invented a similar, and much more difficult, puzzle idea called
8
- Latin Squares. The objective of Su Doku puzzles, however, is to replace the blanks
9
- (or zeros) in a 9 by 9 grid in such that each row, column, and 3 by 3 box contains
10
- each of the digits 1 to 9. Below is an example of a typical starting puzzle grid
11
- and its solution grid.</p>\r\n<div style=\"text-align:center;\">\r\n<table border=\"0\"
12
- cellpadding=\"0\" cellspacing=\"0\" align=\"center\"><tr>\n<td>\r\n<table cellpadding=\"5\"
13
- cellspacing=\"0\" border=\"1\">\n<tr>\n<td style=\"font-family:courier new;font-size:14pt;\">0
14
- 0 3<br>9 0 0<br>0 0 1</td>\r\n<td style=\"font-family:courier new;font-size:14pt;\">0
15
- 2 0<br>3 0 5<br>8 0 6</td>\r\n<td style=\"font-family:courier new;font-size:14pt;\">6
16
- 0 0<br>0 0 1<br>4 0 0</td>\r\n</tr>\n<tr>\n<td style=\"font-family:courier new;font-size:14pt;\">0
17
- 0 8<br>7 0 0<br>0 0 6</td>\r\n<td style=\"font-family:courier new;font-size:14pt;\">1
18
- 0 2<br>0 0 0<br>7 0 8</td>\r\n<td style=\"font-family:courier new;font-size:14pt;\">9
19
- 0 0<br>0 0 8<br>2 0 0</td>\r\n</tr>\n<tr>\n<td style=\"font-family:courier new;font-size:14pt;\">0
20
- 0 2<br>8 0 0<br>0 0 5</td>\r\n<td style=\"font-family:courier new;font-size:14pt;\">6
21
- 0 9<br>2 0 3<br>0 1 0</td>\r\n<td style=\"font-family:courier new;font-size:14pt;\">5
22
- 0 0<br>0 0 9<br>3 0 0</td>\r\n</tr>\n</table>\n</td>\r\n<td width=\"50\">\n<img
23
- src=\"images/spacer.gif\" width=\"50\" height=\"1\" alt=\"\"><br>\n</td>\r\n<td>\r\n<table
24
- cellpadding=\"5\" cellspacing=\"0\" border=\"1\">\n<tr>\n<td style=\"font-family:courier
25
- new;font-size:14pt;\">4 8 3<br>9 6 7<br>2 5 1</td>\r\n<td style=\"font-family:courier
26
- new;font-size:14pt;\">9 2 1<br>3 4 5<br>8 7 6</td>\r\n<td style=\"font-family:courier
27
- new;font-size:14pt;\">6 5 7<br>8 2 1<br>4 9 3</td>\r\n</tr>\n<tr>\n<td style=\"font-family:courier
28
- new;font-size:14pt;\">5 4 8<br>7 2 9<br>1 3 6</td>\r\n<td style=\"font-family:courier
29
- new;font-size:14pt;\">1 3 2<br>5 6 4<br>7 9 8</td>\r\n<td style=\"font-family:courier
30
- new;font-size:14pt;\">9 7 6<br>1 3 8<br>2 4 5</td>\r\n</tr>\n<tr>\n<td style=\"font-family:courier
31
- new;font-size:14pt;\">3 7 2<br>8 1 4<br>6 9 5</td>\r\n<td style=\"font-family:courier
32
- new;font-size:14pt;\">6 8 9<br>2 5 3<br>4 1 7</td>\r\n<td style=\"font-family:courier
33
- new;font-size:14pt;\">5 1 4<br>7 6 9<br>3 8 2</td>\r\n</tr>\n</table>\n</td>\r\n</tr></table>\n</div>\r\n<p>A
34
- well constructed Su Doku puzzle has a unique solution and can be solved by logic,
35
- although it may be necessary to employ \"guess and test\" methods in order to eliminate
36
- options (there is much contested opinion over this). The complexity of the search
37
- determines the difficulty of the puzzle; the example above is considered <i>easy</i>
38
- because it can be solved by straight forward direct deduction.</p>\r\n<p>The 6K
39
- text file, <a href=\"project/sudoku.txt\">sudoku.txt</a> (right click and 'Save
40
- Link/Target As...'), contains fifty different Su Doku puzzles ranging in difficulty,
41
- but all with unique solutions (the first puzzle in the file is the example above).</p>\r\n<p>By
5
+ :content: "Su Doku (Japanese meaning _number place_) is the name given to a popular
6
+ puzzle concept. Its origin is unclear, but credit must be attributed to Leonhard
7
+ Euler who invented a similar, and much more difficult, puzzle idea called Latin
8
+ Squares. The objective of Su Doku puzzles, however, is to replace the blanks (or
9
+ zeros) in a 9 by 9 grid in such that each row, column, and 3 by 3 box contains each
10
+ of the digits 1 to 9. Below is an example of a typical starting puzzle grid and
11
+ its solution grid.\n\n| \n\n| 0 0 3 \n9 0 0 \n0 0 1 | 0 2 0 \n3 0 5 \n8 0 6
12
+ | 6 0 0 \n0 0 1 \n4 0 0 |\n| 0 0 8 \n7 0 0 \n0 0 6 | 1 0 2 \n0 0 0 \n7 0 8
13
+ | 9 0 0 \n0 0 8 \n2 0 0 |\n| 0 0 2 \n8 0 0 \n0 0 5 | 6 0 9 \n2 0 3 \n0 1 0
14
+ | 5 0 0 \n0 0 9 \n3 0 0 |\n\n | ![](/home/will/src/euler-manager/config/../data/images/spacer.gif)
15
+ \ \n | \n\n| 4 8 3 \n9 6 7 \n2 5 1 | 9 2 1 \n3 4 5 \n8 7 6 | 6 5 7 \n8 2 1
16
+ \ \n4 9 3 |\n| 5 4 8 \n7 2 9 \n1 3 6 | 1 3 2 \n5 6 4 \n7 9 8 | 9 7 6 \n1 3
17
+ 8 \n2 4 5 |\n| 3 7 2 \n8 1 4 \n6 9 5 | 6 8 9 \n2 5 3 \n4 1 7 | 5 1 4 \n7 6
18
+ 9 \n3 8 2 |\n\n |\n\nA well constructed Su Doku puzzle has a unique solution and
19
+ can be solved by logic, although it may be necessary to employ \"guess and test\"
20
+ methods in order to eliminate options (there is much contested opinion over this).
21
+ The complexity of the search determines the difficulty of the puzzle; the example
22
+ above is considered _easy_ because it can be solved by straight forward direct deduction.\n\nThe
23
+ 6K text file, [sudoku.txt](project/sudoku.txt) (right click and 'Save Link/Target
24
+ As...'), contains fifty different Su Doku puzzles ranging in difficulty, but all
25
+ with unique solutions (the first puzzle in the file is the example above).\n\nBy
42
26
  solving all fifty puzzles find the sum of the 3-digit numbers found in the top left
43
27
  corner of each solution grid; for example, 483 is the 3-digit number found in the
44
- top left corner of the solution grid above.</p>\r\n<!--<p class='info'>Note: If
45
- you're convinced that &quot;guess and test&quot; methods need not be employed please
46
- tell how you would solve #6 and #46. (c;</p>-->\r\n\r\n"
28
+ top left corner of the solution grid above.\n\n<!--<p class='info'>Note: If you're
29
+ convinced that &quot;guess and test&quot; methods need not be employed please tell
30
+ how you would solve #6 and #46. (c;</p>-->\n"
data/data/problems/97.yml CHANGED
@@ -2,13 +2,10 @@
2
2
  :id: 97
3
3
  :name: Large non-Mersenne prime
4
4
  :url: http://projecteuler.net/problem=97
5
- :content: "\r\n<p>The first known prime found to exceed one million digits was discovered
6
- in 1999, and is a Mersenne prime of the form 2<sup>6972593</sup><img src=\"images/symbol_minus.gif\"
7
- width=\"9\" height=\"3\" alt=\"−\" border=\"0\" style=\"vertical-align:middle;\">1;
8
- it contains exactly 2,098,960 digits. Subsequently other Mersenne primes, of the
9
- form 2<sup><i>p</i></sup><img src=\"images/symbol_minus.gif\" width=\"9\" height=\"3\"
10
- alt=\"−\" border=\"0\" style=\"vertical-align:middle;\">1, have been found which
11
- contain more digits.</p>\r\n<p>However, in 2004 there was found a massive non-Mersenne
12
- prime which contains 2,357,207 digits: 28433<img src=\"images/symbol_times.gif\"
13
- width=\"9\" height=\"9\" alt=\"×\" border=\"0\" style=\"vertical-align:middle;\">2<sup>7830457</sup>+1.</p>\r\n<p>Find
14
- the last ten digits of this prime number.</p>\r\n\r\n"
5
+ :content: |+
6
+ The first known prime found to exceed one million digits was discovered in 1999, and is a Mersenne prime of the form 2<sup>6972593</sup> ![−](/home/will/src/euler-manager/config/../data/images/symbol_minus.gif)1; it contains exactly 2,098,960 digits. Subsequently other Mersenne primes, of the form 2<sup><i>p</i></sup> ![−](/home/will/src/euler-manager/config/../data/images/symbol_minus.gif)1, have been found which contain more digits.
7
+
8
+ However, in 2004 there was found a massive non-Mersenne prime which contains 2,357,207 digits: 28433 ![×](/home/will/src/euler-manager/config/../data/images/symbol_times.gif)2<sup>7830457</sup>+1.
9
+
10
+ Find the last ten digits of this prime number.
11
+
data/data/problems/98.yml CHANGED
@@ -2,15 +2,12 @@
2
2
  :id: 98
3
3
  :name: Anagramic squares
4
4
  :url: http://projecteuler.net/problem=98
5
- :content: "\r\n<p>By replacing each of the letters in the word CARE with 1, 2, 9,
6
- and 6 respectively, we form a square number: 1296 = 36<sup>2</sup>. What is remarkable
7
- is that, by using the same digital substitutions, the anagram, RACE, also forms
8
- a square number: 9216 = 96<sup>2</sup>. We shall call CARE (and RACE) a square anagram
9
- word pair and specify further that leading zeroes are not permitted, neither may
10
- a different letter have the same digital value as another letter.</p>\r\n<p>Using
11
- <a href=\"project/words.txt\">words.txt</a> (right click and 'Save Link/Target As...'),
12
- a 16K text file containing nearly two-thousand common English words, find all the
13
- square anagram word pairs (a palindromic word is NOT considered to be an anagram
14
- of itself).</p>\r\n<p>What is the largest square number formed by any member of
15
- such a pair?</p>\r\n<p class=\"info\">NOTE: All anagrams formed must be contained
16
- in the given text file.</p>\r\n\r\n"
5
+ :content: |+
6
+ By replacing each of the letters in the word CARE with 1, 2, 9, and 6 respectively, we form a square number: 1296 = 36<sup>2</sup>. What is remarkable is that, by using the same digital substitutions, the anagram, RACE, also forms a square number: 9216 = 96<sup>2</sup>. 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.
7
+
8
+ Using [words.txt](project/words.txt) (right click and 'Save Link/Target As...'), 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).
9
+
10
+ What is the largest square number formed by any member of such a pair?
11
+
12
+ NOTE: All anagrams formed must be contained in the given text file.
13
+
data/data/problems/99.yml CHANGED
@@ -2,15 +2,12 @@
2
2
  :id: 99
3
3
  :name: Largest exponential
4
4
  :url: http://projecteuler.net/problem=99
5
- :content: "\r\n\n<p>Comparing two numbers written in index form like 2<sup>11</sup>
6
- and 3<sup>7</sup> is not difficult, as any calculator would confirm that 2<sup>11</sup>
7
- = 2048 <img src=\"images/symbol_lt.gif\" width=\"10\" height=\"10\" alt=\"&lt;\"
8
- border=\"0\" style=\"vertical-align:middle;\"> 3<sup>7</sup> = 2187.</p>\n<p>However,
9
- confirming that 632382<sup>518061</sup><img src=\"images/symbol_gt.gif\" width=\"10\"
10
- height=\"10\" alt=\"&gt;\" border=\"0\" style=\"vertical-align:middle;\"> 519432<sup>525806</sup>
11
- would be much more difficult, as both numbers contain over three million digits.</p>\n<p>Using
12
- <a href=\"project/base_exp.txt\">base_exp.txt</a> (right click and 'Save Link/Target
13
- As...'), a 22K text file containing one thousand lines with a base/exponent pair
14
- on each line, determine which line number has the greatest numerical value.</p>\n<p
15
- class=\"info\">NOTE: The first two lines in the file represent the numbers in the
16
- example given above.</p>\n\r\n"
5
+ :content: |+
6
+ Comparing two numbers written in index form like 2<sup>11</sup> and 3<sup>7</sup> is not difficult, as any calculator would confirm that 2<sup>11</sup> = 2048 ![<](/home/will/src/euler-manager/config/../data/images/symbol_lt.gif) 3<sup>7</sup> = 2187.
7
+
8
+ However, confirming that 632382<sup>518061</sup> ![>](/home/will/src/euler-manager/config/../data/images/symbol_gt.gif) 519432<sup>525806</sup> would be much more difficult, as both numbers contain over three million digits.
9
+
10
+ Using [base\_exp.txt](project/base_exp.txt) (right click and 'Save Link/Target As...'), 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.
11
+
12
+ NOTE: The first two lines in the file represent the numbers in the example given above.
13
+
@@ -31,4 +31,5 @@ Gem::Specification.new do |spec|
31
31
  spec.add_development_dependency 'fakefs', '~> 0.5.2'
32
32
 
33
33
  spec.add_development_dependency 'nokogiri'
34
+ spec.add_development_dependency 'reverse_markdown'
34
35
  end
data/example/1/README.md CHANGED
@@ -1,6 +1,6 @@
1
1
  # [Multiples of 3 and 5](http://projecteuler.net/problem=1)
2
2
 
3
-
4
- <p>If we list all the natural numbers below 10 that are multiples of 3 or 5, we get 3, 5, 6 and 9. The sum of these multiples is 23.</p>
5
- <p>Find the sum of all the multiples of 3 or 5 below 1000.</p>
6
-
3
+ If we list all the natural numbers below 10 that are multiples of 3 or 5, we get 3, 5, 6 and 9. The sum of these multiples is 23.
4
+
5
+ Find the sum of all the multiples of 3 or 5 below 1000.
6
+
@@ -0,0 +1,8 @@
1
+ # [Lattice paths](http://projecteuler.net/problem=15)
2
+
3
+ Starting in the top left corner of a 2 ![×](https://raw.githubusercontent.com/yaworsw/euler-manager/develop/.data/images/symbol_times.gif)2 grid, and only being able to move to the right and down, there are exactly 6 routes to the bottom right corner.
4
+
5
+ ![](https://raw.githubusercontent.com/yaworsw/euler-manager/develop/.data/images/p_015.gif)
6
+
7
+ How many such routes are there through a 20 ![×](https://raw.githubusercontent.com/yaworsw/euler-manager/develop/.data/images/symbol_times.gif)20 grid?
8
+
@@ -0,0 +1,5 @@
1
+ import euler
2
+
3
+ answer = 0
4
+
5
+ print(answer)
File without changes