euler-manager 0.1.1 → 0.2.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (618) hide show
  1. checksums.yaml +4 -4
  2. data/.gitignore +3 -0
  3. data/.travis.yml +2 -1
  4. data/README.md +27 -21
  5. data/Rakefile +3 -2
  6. data/config/config.rb +6 -2
  7. data/data/answers.yml +431 -430
  8. data/data/images/{p_015.gif → p015.gif} +0 -0
  9. data/data/images/{p_068_1.gif → p068_1.gif} +0 -0
  10. data/data/images/{p_068_2.gif → p068_2.gif} +0 -0
  11. data/data/images/{p_085.gif → p085.gif} +0 -0
  12. data/data/images/{p_086.gif → p086.gif} +0 -0
  13. data/data/images/{p_090.gif → p090.gif} +0 -0
  14. data/data/images/{p_091_1.gif → p091_1.gif} +0 -0
  15. data/data/images/{p_091_2.gif → p091_2.gif} +0 -0
  16. data/data/images/{p_107_1.gif → p107_1.gif} +0 -0
  17. data/data/images/{p_107_2.gif → p107_2.gif} +0 -0
  18. data/data/images/{p_109.gif → p109.gif} +0 -0
  19. data/data/images/{p_126.gif → p126.gif} +0 -0
  20. data/data/images/{p_128.gif → p128.gif} +0 -0
  21. data/data/images/{p_138.gif → p138.gif} +0 -0
  22. data/data/images/{p_139.gif → p139.gif} +0 -0
  23. data/data/images/{p_143_torricelli.gif → p143_torricelli.gif} +0 -0
  24. data/data/images/{p_144_1.gif → p144_1.gif} +0 -0
  25. data/data/images/{p_144_2.gif → p144_2.gif} +0 -0
  26. data/data/images/{p_147.gif → p147.gif} +0 -0
  27. data/data/images/{p_150.gif → p150.gif} +0 -0
  28. data/data/images/{p_151.gif → p151.gif} +0 -0
  29. data/data/images/{p_152_sum.gif → p152_sum.gif} +0 -0
  30. data/data/images/{p_153_formule1.gif → p153_formule1.gif} +0 -0
  31. data/data/images/{p_153_formule2.gif → p153_formule2.gif} +0 -0
  32. data/data/images/{p_153_formule5.gif → p153_formule5.gif} +0 -0
  33. data/data/images/{p_153_formule6.gif → p153_formule6.gif} +0 -0
  34. data/data/images/{p_154_pyramid.gif → p154_pyramid.gif} +0 -0
  35. data/data/images/{p_155_capacitors1.gif → p155_capacitors1.gif} +0 -0
  36. data/data/images/{p_155_capsform.gif → p155_capsform.gif} +0 -0
  37. data/data/images/{p_155_capsmu.gif → p155_capsmu.gif} +0 -0
  38. data/data/images/{p_161_k9.gif → p161_k9.gif} +0 -0
  39. data/data/images/{p_161_trio1.gif → p161_trio1.gif} +0 -0
  40. data/data/images/{p_161_trio3.gif → p161_trio3.gif} +0 -0
  41. data/data/images/{p_163.gif → p163.gif} +0 -0
  42. data/data/images/{p_173_square_laminas.gif → p173_square_laminas.gif} +0 -0
  43. data/data/images/{p_177_quad.gif → p177_quad.gif} +0 -0
  44. data/data/images/{p_184.gif → p184.gif} +0 -0
  45. data/data/images/{p_189_colours.gif → p189_colours.gif} +0 -0
  46. data/data/images/{p_189_grid.gif → p189_grid.gif} +0 -0
  47. data/data/images/{p_194_Fig.png → p194_Fig.png} +0 -0
  48. data/data/images/{p_194_GraphA.png → p194_GraphA.png} +0 -0
  49. data/data/images/{p_194_GraphB.png → p194_GraphB.png} +0 -0
  50. data/data/images/{p_199_circles_in_circles.gif → p199_circles_in_circles.gif} +0 -0
  51. data/data/images/{p_201_laserbeam.gif → p201_laserbeam.gif} +0 -0
  52. data/data/images/{p_208_robotwalk.gif → p208_robotwalk.gif} +0 -0
  53. data/data/images/{p_215_crackfree.gif → p215_crackfree.gif} +0 -0
  54. data/data/images/{p_220.gif → p220.gif} +0 -0
  55. data/data/images/{p_226_formula.gif → p226_formula.gif} +0 -0
  56. data/data/images/{p_226_scoop2.gif → p226_scoop2.gif} +0 -0
  57. data/data/images/{p_228.png → p228.png} +0 -0
  58. data/data/images/{p_237.gif → p237.gif} +0 -0
  59. data/data/images/{p_244_example.gif → p244_example.gif} +0 -0
  60. data/data/images/{p_244_start.gif → p244_start.gif} +0 -0
  61. data/data/images/{p_244_target.gif → p244_target.gif} +0 -0
  62. data/data/images/{p_246_anim.gif → p246_anim.gif} +0 -0
  63. data/data/images/{p_246_ellipse.gif → p246_ellipse.gif} +0 -0
  64. data/data/images/{p_247_hypersquares.gif → p247_hypersquares.gif} +0 -0
  65. data/data/images/{p_251_cardano.gif → p251_cardano.gif} +0 -0
  66. data/data/images/{p_252_convexhole.gif → p252_convexhole.gif} +0 -0
  67. data/data/images/{p_255_Example.gif → p255_Example.gif} +0 -0
  68. data/data/images/{p_255_Heron.gif → p255_Heron.gif} +0 -0
  69. data/data/images/{p_256_tatami3.gif → p256_tatami3.gif} +0 -0
  70. data/data/images/{p_257_bisector.gif → p257_bisector.gif} +0 -0
  71. data/data/images/{p_262_formula1.gif → p262_formula1.gif} +0 -0
  72. data/data/images/{p_264_TriangleCentres.gif → p264_TriangleCentres.gif} +0 -0
  73. data/data/images/{p_265_BinaryCircles.gif → p265_BinaryCircles.gif} +0 -0
  74. data/data/images/{p_270_CutSquare.gif → p270_CutSquare.gif} +0 -0
  75. data/data/images/{p_275_sculptures2.gif → p275_sculptures2.gif} +0 -0
  76. data/data/images/{p_281_pizza.gif → p281_pizza.gif} +0 -0
  77. data/data/images/{p_282_formula.gif → p282_formula.gif} +0 -0
  78. data/data/images/{p_282formula3.gif → p282formula3.gif} +0 -0
  79. data/data/images/{p_287_quadtree.gif → p287_quadtree.gif} +0 -0
  80. data/data/images/{p_289_euler.gif → p289_euler.gif} +0 -0
  81. data/data/images/{p_291_formula.gif → p291_formula.gif} +0 -0
  82. data/data/images/{p_299_ThreeSimTri.gif → p299_ThreeSimTri.gif} +0 -0
  83. data/data/images/{p_300_protein.gif → p300_protein.gif} +0 -0
  84. data/data/images/{p_306_pstrip.gif → p306_pstrip.gif} +0 -0
  85. data/data/images/{p_309_ladders.gif → p309_ladders.gif} +0 -0
  86. data/data/images/{p_311_biclinic.gif → p311_biclinic.gif} +0 -0
  87. data/data/images/{p_312_sierpinsky8t.gif → p312_sierpinsky8t.gif} +0 -0
  88. data/data/images/{p_312_sierpinskyAt.gif → p312_sierpinskyAt.gif} +0 -0
  89. data/data/images/{p_313_sliding_game_1.gif → p313_sliding_game_1.gif} +0 -0
  90. data/data/images/{p_313_sliding_game_2.gif → p313_sliding_game_2.gif} +0 -0
  91. data/data/images/{p_314_landgrab.gif → p314_landgrab.gif} +0 -0
  92. data/data/images/{p_315_clocks.gif → p315_clocks.gif} +0 -0
  93. data/data/images/{p_316_decexp1.gif → p316_decexp1.gif} +0 -0
  94. data/data/images/{p_316_decexp2.gif → p316_decexp2.gif} +0 -0
  95. data/data/images/{p_316_decexp3.gif → p316_decexp3.gif} +0 -0
  96. data/data/images/{p_321_swapping_counters_1.gif → p321_swapping_counters_1.gif} +0 -0
  97. data/data/images/{p_321_swapping_counters_2.gif → p321_swapping_counters_2.gif} +0 -0
  98. data/data/images/{p_326_formula1.gif → p326_formula1.gif} +0 -0
  99. data/data/images/{p_326_formula2.gif → p326_formula2.gif} +0 -0
  100. data/data/images/{p_327_rooms_of_doom.gif → p327_rooms_of_doom.gif} +0 -0
  101. data/data/images/{p_328_sum1.gif → p328_sum1.gif} +0 -0
  102. data/data/images/{p_328_sum2.gif → p328_sum2.gif} +0 -0
  103. data/data/images/{p_330_formula.gif → p330_formula.gif} +0 -0
  104. data/data/images/{p_331_crossflips1.gif → p331_crossflips1.gif} +0 -0
  105. data/data/images/{p_331_crossflips2.gif → p331_crossflips2.gif} +0 -0
  106. data/data/images/{p_331_crossflips3.gif → p331_crossflips3.gif} +0 -0
  107. data/data/images/{p_332_spherical.jpg → p332_spherical.jpg} +0 -0
  108. data/data/images/{p_332_sum.gif → p332_sum.gif} +0 -0
  109. data/data/images/{p_334_beans.gif → p334_beans.gif} +0 -0
  110. data/data/images/{p_334_cases.gif → p334_cases.gif} +0 -0
  111. data/data/images/{p_334_lfloor.gif → p334_lfloor.gif} +0 -0
  112. data/data/images/{p_334_oplus.gif → p334_oplus.gif} +0 -0
  113. data/data/images/{p_334_rfloor.gif → p334_rfloor.gif} +0 -0
  114. data/data/images/{p_335_mancala.gif → p335_mancala.gif} +0 -0
  115. data/data/images/{p_335_sum.gif → p335_sum.gif} +0 -0
  116. data/data/images/{p_336_maximix.gif → p336_maximix.gif} +0 -0
  117. data/data/images/{p_338_gridpaper.gif → p338_gridpaper.gif} +0 -0
  118. data/data/images/{p_340_formula.gif → p340_formula.gif} +0 -0
  119. data/data/images/{p_344_silverdollar.gif → p344_silverdollar.gif} +0 -0
  120. data/data/images/{p_351_hexorchard.png → p351_hexorchard.png} +0 -0
  121. data/data/images/{p_354_bee_honeycomb.png → p354_bee_honeycomb.png} +0 -0
  122. data/data/images/{p_356_cubicpoly1.gif → p356_cubicpoly1.gif} +0 -0
  123. data/data/images/{p_356_cubicpoly2.gif → p356_cubicpoly2.gif} +0 -0
  124. data/data/images/{p_361_Thue-Morse1.gif → p361_Thue-Morse1.gif} +0 -0
  125. data/data/images/p363_bezier.png +0 -0
  126. data/data/images/{p_364_comf_dist.gif → p364_comf_dist.gif} +0 -0
  127. data/data/images/{p_372_pencilray1.jpg → p372_pencilray1.jpg} +0 -0
  128. data/data/images/{p_372_pencilray2.gif → p372_pencilray2.gif} +0 -0
  129. data/data/images/{p_380_mazes.gif → p380_mazes.gif} +0 -0
  130. data/data/images/{p_384_formula.gif → p384_formula.gif} +0 -0
  131. data/data/images/{p_385_ellipsetriangle.png → p385_ellipsetriangle.png} +0 -0
  132. data/data/images/{p_394_eatpie.gif → p394_eatpie.gif} +0 -0
  133. data/data/images/{p_395_pythagorean.gif → p395_pythagorean.gif} +0 -0
  134. data/data/images/{p_404_c_ellipse.gif → p404_c_ellipse.gif} +0 -0
  135. data/data/images/{p_405_tile1.png → p405_tile1.png} +0 -0
  136. data/data/images/{p_405_tile2.gif → p405_tile2.gif} +0 -0
  137. data/data/images/{p_420_matrix.gif → p420_matrix.gif} +0 -0
  138. data/data/images/{p_424_kakuro1.gif → p424_kakuro1.gif} +0 -0
  139. data/data/images/{p_426_baxball1.gif → p426_baxball1.gif} +0 -0
  140. data/data/images/{p_426_baxball2.gif → p426_baxball2.gif} +0 -0
  141. data/data/images/{p_430_flips.gif → p430_flips.gif} +0 -0
  142. data/data/problems/1.yml +1 -1
  143. data/data/problems/10.yml +6 -4
  144. data/data/problems/100.yml +2 -2
  145. data/data/problems/101.yml +15 -19
  146. data/data/problems/102.yml +9 -10
  147. data/data/problems/103.yml +7 -8
  148. data/data/problems/104.yml +2 -2
  149. data/data/problems/105.yml +4 -4
  150. data/data/problems/106.yml +3 -3
  151. data/data/problems/107.yml +12 -12
  152. data/data/problems/108.yml +8 -14
  153. data/data/problems/109.yml +12 -11
  154. data/data/problems/11.yml +21 -24
  155. data/data/problems/110.yml +9 -10
  156. data/data/problems/111.yml +1 -1
  157. data/data/problems/112.yml +1 -1
  158. data/data/problems/113.yml +1 -1
  159. data/data/problems/114.yml +2 -2
  160. data/data/problems/115.yml +1 -1
  161. data/data/problems/116.yml +11 -11
  162. data/data/problems/117.yml +3 -3
  163. data/data/problems/118.yml +1 -1
  164. data/data/problems/119.yml +1 -1
  165. data/data/problems/12.yml +6 -6
  166. data/data/problems/120.yml +4 -4
  167. data/data/problems/121.yml +1 -1
  168. data/data/problems/122.yml +10 -18
  169. data/data/problems/123.yml +3 -3
  170. data/data/problems/124.yml +17 -19
  171. data/data/problems/125.yml +1 -1
  172. data/data/problems/126.yml +12 -11
  173. data/data/problems/127.yml +8 -8
  174. data/data/problems/128.yml +3 -3
  175. data/data/problems/129.yml +1 -1
  176. data/data/problems/13.yml +1 -1
  177. data/data/problems/130.yml +6 -7
  178. data/data/problems/131.yml +2 -2
  179. data/data/problems/132.yml +2 -2
  180. data/data/problems/133.yml +2 -2
  181. data/data/problems/134.yml +3 -3
  182. data/data/problems/135.yml +3 -3
  183. data/data/problems/136.yml +3 -3
  184. data/data/problems/137.yml +9 -9
  185. data/data/problems/138.yml +5 -5
  186. data/data/problems/139.yml +2 -2
  187. data/data/problems/14.yml +8 -13
  188. data/data/problems/140.yml +5 -5
  189. data/data/problems/141.yml +2 -2
  190. data/data/problems/142.yml +3 -4
  191. data/data/problems/143.yml +3 -3
  192. data/data/problems/144.yml +4 -4
  193. data/data/problems/145.yml +1 -1
  194. data/data/problems/146.yml +1 -1
  195. data/data/problems/147.yml +6 -6
  196. data/data/problems/148.yml +8 -8
  197. data/data/problems/149.yml +12 -25
  198. data/data/problems/15.yml +4 -4
  199. data/data/problems/150.yml +16 -17
  200. data/data/problems/151.yml +3 -3
  201. data/data/problems/152.yml +2 -2
  202. data/data/problems/153.yml +30 -35
  203. data/data/problems/154.yml +16 -12
  204. data/data/problems/155.yml +7 -6
  205. data/data/problems/156.yml +8 -9
  206. data/data/problems/157.yml +4 -6
  207. data/data/problems/158.yml +12 -12
  208. data/data/problems/159.yml +14 -16
  209. data/data/problems/16.yml +1 -1
  210. data/data/problems/160.yml +3 -3
  211. data/data/problems/161.yml +6 -6
  212. data/data/problems/162.yml +3 -3
  213. data/data/problems/163.yml +3 -3
  214. data/data/problems/164.yml +3 -4
  215. data/data/problems/165.yml +12 -12
  216. data/data/problems/166.yml +6 -8
  217. data/data/problems/167.yml +6 -7
  218. data/data/problems/168.yml +5 -7
  219. data/data/problems/169.yml +2 -2
  220. data/data/problems/17.yml +5 -5
  221. data/data/problems/170.yml +9 -10
  222. data/data/problems/171.yml +4 -5
  223. data/data/problems/172.yml +3 -4
  224. data/data/problems/173.yml +2 -2
  225. data/data/problems/174.yml +4 -4
  226. data/data/problems/175.yml +12 -13
  227. data/data/problems/176.yml +1 -1
  228. data/data/problems/177.yml +2 -2
  229. data/data/problems/178.yml +6 -6
  230. data/data/problems/179.yml +4 -4
  231. data/data/problems/18.yml +11 -12
  232. data/data/problems/180.yml +9 -12
  233. data/data/problems/181.yml +1 -1
  234. data/data/problems/182.yml +14 -16
  235. data/data/problems/183.yml +12 -15
  236. data/data/problems/184.yml +3 -3
  237. data/data/problems/185.yml +11 -11
  238. data/data/problems/186.yml +10 -11
  239. data/data/problems/187.yml +8 -8
  240. data/data/problems/188.yml +4 -4
  241. data/data/problems/189.yml +4 -4
  242. data/data/problems/19.yml +1 -1
  243. data/data/problems/190.yml +2 -2
  244. data/data/problems/191.yml +5 -5
  245. data/data/problems/192.yml +10 -14
  246. data/data/problems/193.yml +1 -1
  247. data/data/problems/194.yml +10 -10
  248. data/data/problems/195.yml +5 -6
  249. data/data/problems/196.yml +15 -14
  250. data/data/problems/197.yml +7 -8
  251. data/data/problems/198.yml +8 -14
  252. data/data/problems/199.yml +3 -3
  253. data/data/problems/2.yml +8 -7
  254. data/data/problems/20.yml +4 -9
  255. data/data/problems/200.yml +7 -8
  256. data/data/problems/201.yml +14 -14
  257. data/data/problems/202.yml +2 -2
  258. data/data/problems/203.yml +21 -13
  259. data/data/problems/204.yml +7 -7
  260. data/data/problems/205.yml +6 -6
  261. data/data/problems/206.yml +1 -1
  262. data/data/problems/207.yml +10 -10
  263. data/data/problems/208.yml +4 -5
  264. data/data/problems/209.yml +6 -6
  265. data/data/problems/21.yml +7 -7
  266. data/data/problems/210.yml +6 -6
  267. data/data/problems/211.yml +2 -2
  268. data/data/problems/212.yml +16 -20
  269. data/data/problems/213.yml +6 -6
  270. data/data/problems/214.yml +9 -10
  271. data/data/problems/215.yml +5 -5
  272. data/data/problems/216.yml +5 -6
  273. data/data/problems/217.yml +7 -12
  274. data/data/problems/218.yml +9 -10
  275. data/data/problems/219.yml +5 -5
  276. data/data/problems/22.yml +3 -3
  277. data/data/problems/220.yml +15 -16
  278. data/data/problems/221.yml +8 -8
  279. data/data/problems/222.yml +1 -1
  280. data/data/problems/223.yml +5 -6
  281. data/data/problems/224.yml +5 -6
  282. data/data/problems/225.yml +2 -2
  283. data/data/problems/226.yml +8 -9
  284. data/data/problems/227.yml +3 -3
  285. data/data/problems/228.yml +17 -16
  286. data/data/problems/229.yml +16 -19
  287. data/data/problems/23.yml +1 -3
  288. data/data/problems/230.yml +9 -11
  289. data/data/problems/231.yml +5 -8
  290. data/data/problems/232.yml +1 -1
  291. data/data/problems/233.yml +2 -2
  292. data/data/problems/234.yml +11 -13
  293. data/data/problems/235.yml +2 -2
  294. data/data/problems/236.yml +13 -19
  295. data/data/problems/237.yml +4 -4
  296. data/data/problems/238.yml +16 -19
  297. data/data/problems/239.yml +2 -2
  298. data/data/problems/24.yml +2 -2
  299. data/data/problems/240.yml +7 -7
  300. data/data/problems/241.yml +4 -7
  301. data/data/problems/242.yml +5 -6
  302. data/data/problems/243.yml +13 -13
  303. data/data/problems/244.yml +15 -15
  304. data/data/problems/245.yml +8 -20
  305. data/data/problems/246.yml +11 -12
  306. data/data/problems/247.yml +11 -12
  307. data/data/problems/248.yml +1 -1
  308. data/data/problems/249.yml +2 -2
  309. data/data/problems/25.yml +8 -12
  310. data/data/problems/250.yml +4 -4
  311. data/data/problems/251.yml +4 -4
  312. data/data/problems/252.yml +13 -20
  313. data/data/problems/253.yml +9 -8
  314. data/data/problems/254.yml +3 -3
  315. data/data/problems/255.yml +15 -37
  316. data/data/problems/256.yml +19 -24
  317. data/data/problems/257.yml +8 -10
  318. data/data/problems/258.yml +9 -7
  319. data/data/problems/259.yml +1 -1
  320. data/data/problems/26.yml +11 -11
  321. data/data/problems/260.yml +15 -18
  322. data/data/problems/261.yml +15 -13
  323. data/data/problems/262.yml +15 -14
  324. data/data/problems/263.yml +13 -13
  325. data/data/problems/264.yml +10 -11
  326. data/data/problems/265.yml +2 -2
  327. data/data/problems/266.yml +7 -7
  328. data/data/problems/267.yml +1 -1
  329. data/data/problems/268.yml +1 -1
  330. data/data/problems/269.yml +3 -3
  331. data/data/problems/27.yml +12 -15
  332. data/data/problems/270.yml +4 -4
  333. data/data/problems/271.yml +5 -6
  334. data/data/problems/272.yml +5 -7
  335. data/data/problems/273.yml +4 -4
  336. data/data/problems/274.yml +4 -5
  337. data/data/problems/275.yml +4 -4
  338. data/data/problems/276.yml +5 -6
  339. data/data/problems/277.yml +7 -8
  340. data/data/problems/278.yml +16 -19
  341. data/data/problems/279.yml +3 -4
  342. data/data/problems/28.yml +6 -6
  343. data/data/problems/280.yml +2 -2
  344. data/data/problems/281.yml +4 -6
  345. data/data/problems/282.yml +3 -3
  346. data/data/problems/283.yml +6 -7
  347. data/data/problems/284.yml +7 -8
  348. data/data/problems/285.yml +4 -4
  349. data/data/problems/286.yml +2 -2
  350. data/data/problems/287.yml +19 -24
  351. data/data/problems/288.yml +7 -8
  352. data/data/problems/289.yml +11 -11
  353. data/data/problems/29.yml +10 -13
  354. data/data/problems/290.yml +3 -4
  355. data/data/problems/291.yml +4 -4
  356. data/data/problems/292.yml +5 -6
  357. data/data/problems/293.yml +9 -10
  358. data/data/problems/294.yml +12 -7
  359. data/data/problems/295.yml +11 -13
  360. data/data/problems/296.yml +9 -9
  361. data/data/problems/297.yml +7 -9
  362. data/data/problems/298.yml +32 -40
  363. data/data/problems/299.yml +17 -19
  364. data/data/problems/3.yml +6 -4
  365. data/data/problems/30.yml +1 -1
  366. data/data/problems/300.yml +14 -14
  367. data/data/problems/301.yml +9 -10
  368. data/data/problems/302.yml +5 -5
  369. data/data/problems/303.yml +4 -4
  370. data/data/problems/304.yml +7 -9
  371. data/data/problems/305.yml +4 -5
  372. data/data/problems/306.yml +10 -12
  373. data/data/problems/307.yml +4 -4
  374. data/data/problems/308.yml +4 -4
  375. data/data/problems/309.yml +11 -9
  376. data/data/problems/31.yml +2 -2
  377. data/data/problems/310.yml +6 -9
  378. data/data/problems/311.yml +10 -12
  379. data/data/problems/312.yml +10 -9
  380. data/data/problems/313.yml +5 -5
  381. data/data/problems/314.yml +8 -9
  382. data/data/problems/315.yml +35 -38
  383. data/data/problems/316.yml +17 -16
  384. data/data/problems/317.yml +8 -7
  385. data/data/problems/318.yml +14 -29
  386. data/data/problems/319.yml +10 -12
  387. data/data/problems/32.yml +2 -2
  388. data/data/problems/320.yml +2 -2
  389. data/data/problems/321.yml +12 -11
  390. data/data/problems/322.yml +4 -5
  391. data/data/problems/323.yml +7 -9
  392. data/data/problems/324.yml +7 -9
  393. data/data/problems/325.yml +2 -2
  394. data/data/problems/326.yml +3 -3
  395. data/data/problems/327.yml +19 -22
  396. data/data/problems/328.yml +23 -23
  397. data/data/problems/329.yml +6 -6
  398. data/data/problems/33.yml +2 -2
  399. data/data/problems/330.yml +12 -16
  400. data/data/problems/331.yml +16 -18
  401. data/data/problems/332.yml +10 -10
  402. data/data/problems/333.yml +15 -16
  403. data/data/problems/334.yml +17 -19
  404. data/data/problems/335.yml +3 -3
  405. data/data/problems/336.yml +5 -5
  406. data/data/problems/337.yml +7 -8
  407. data/data/problems/338.yml +18 -24
  408. data/data/problems/339.yml +3 -3
  409. data/data/problems/34.yml +1 -1
  410. data/data/problems/340.yml +7 -7
  411. data/data/problems/341.yml +4 -5
  412. data/data/problems/342.yml +6 -9
  413. data/data/problems/343.yml +8 -13
  414. data/data/problems/344.yml +8 -8
  415. data/data/problems/345.yml +17 -16
  416. data/data/problems/346.yml +6 -6
  417. data/data/problems/347.yml +8 -10
  418. data/data/problems/348.yml +5 -5
  419. data/data/problems/349.yml +4 -4
  420. data/data/problems/35.yml +1 -1
  421. data/data/problems/350.yml +5 -6
  422. data/data/problems/351.yml +7 -7
  423. data/data/problems/352.yml +13 -14
  424. data/data/problems/353.yml +2 -2
  425. data/data/problems/354.yml +6 -8
  426. data/data/problems/355.yml +4 -4
  427. data/data/problems/356.yml +5 -4
  428. data/data/problems/357.yml +3 -3
  429. data/data/problems/358.yml +11 -16
  430. data/data/problems/359.yml +12 -12
  431. data/data/problems/36.yml +1 -1
  432. data/data/problems/360.yml +4 -4
  433. data/data/problems/361.yml +9 -9
  434. data/data/problems/362.yml +8 -15
  435. data/data/problems/363.yml +29 -29
  436. data/data/problems/364.yml +4 -4
  437. data/data/problems/365.yml +3 -3
  438. data/data/problems/366.yml +16 -19
  439. data/data/problems/367.yml +11 -11
  440. data/data/problems/368.yml +14 -18
  441. data/data/problems/369.yml +2 -2
  442. data/data/problems/37.yml +1 -1
  443. data/data/problems/370.yml +4 -4
  444. data/data/problems/371.yml +5 -5
  445. data/data/problems/372.yml +6 -7
  446. data/data/problems/373.yml +10 -6
  447. data/data/problems/374.yml +11 -13
  448. data/data/problems/375.yml +11 -14
  449. data/data/problems/376.yml +19 -19
  450. data/data/problems/377.yml +5 -5
  451. data/data/problems/378.yml +8 -9
  452. data/data/problems/379.yml +10 -9
  453. data/data/problems/38.yml +9 -11
  454. data/data/problems/380.yml +8 -10
  455. data/data/problems/381.yml +6 -10
  456. data/data/problems/382.yml +12 -13
  457. data/data/problems/383.yml +5 -6
  458. data/data/problems/384.yml +14 -18
  459. data/data/problems/385.yml +12 -14
  460. data/data/problems/386.yml +4 -5
  461. data/data/problems/387.yml +13 -14
  462. data/data/problems/388.yml +6 -6
  463. data/data/problems/389.yml +3 -3
  464. data/data/problems/39.yml +2 -2
  465. data/data/problems/390.yml +12 -8
  466. data/data/problems/391.yml +18 -20
  467. data/data/problems/392.yml +9 -9
  468. data/data/problems/393.yml +8 -8
  469. data/data/problems/394.yml +14 -15
  470. data/data/problems/395.yml +16 -15
  471. data/data/problems/396.yml +13 -16
  472. data/data/problems/397.yml +4 -6
  473. data/data/problems/398.yml +8 -9
  474. data/data/problems/399.yml +18 -19
  475. data/data/problems/4.yml +2 -2
  476. data/data/problems/40.yml +2 -2
  477. data/data/problems/400.yml +10 -9
  478. data/data/problems/401.yml +6 -7
  479. data/data/problems/402.yml +7 -9
  480. data/data/problems/403.yml +9 -10
  481. data/data/problems/404.yml +8 -10
  482. data/data/problems/405.yml +10 -10
  483. data/data/problems/406.yml +24 -30
  484. data/data/problems/407.yml +6 -10
  485. data/data/problems/408.yml +10 -10
  486. data/data/problems/409.yml +12 -7
  487. data/data/problems/41.yml +1 -1
  488. data/data/problems/410.yml +5 -6
  489. data/data/problems/411.yml +10 -13
  490. data/data/problems/412.yml +10 -10
  491. data/data/problems/413.yml +6 -7
  492. data/data/problems/414.yml +26 -28
  493. data/data/problems/415.yml +12 -13
  494. data/data/problems/416.yml +4 -4
  495. data/data/problems/417.yml +12 -14
  496. data/data/problems/418.yml +13 -10
  497. data/data/problems/419.yml +11 -13
  498. data/data/problems/42.yml +2 -2
  499. data/data/problems/420.yml +8 -8
  500. data/data/problems/421.yml +8 -13
  501. data/data/problems/422.yml +8 -8
  502. data/data/problems/423.yml +11 -12
  503. data/data/problems/424.yml +10 -10
  504. data/data/problems/425.yml +7 -7
  505. data/data/problems/426.yml +9 -9
  506. data/data/problems/427.yml +12 -13
  507. data/data/problems/428.yml +17 -20
  508. data/data/problems/429.yml +5 -5
  509. data/data/problems/43.yml +1 -1
  510. data/data/problems/430.yml +6 -7
  511. data/data/problems/44.yml +4 -4
  512. data/data/problems/45.yml +4 -4
  513. data/data/problems/46.yml +6 -9
  514. data/data/problems/47.yml +5 -8
  515. data/data/problems/48.yml +1 -1
  516. data/data/problems/49.yml +1 -1
  517. data/data/problems/5.yml +1 -1
  518. data/data/problems/50.yml +1 -1
  519. data/data/problems/51.yml +1 -3
  520. data/data/problems/52.yml +1 -1
  521. data/data/problems/53.yml +6 -12
  522. data/data/problems/54.yml +17 -16
  523. data/data/problems/55.yml +3 -3
  524. data/data/problems/56.yml +2 -2
  525. data/data/problems/57.yml +9 -10
  526. data/data/problems/58.yml +11 -11
  527. data/data/problems/59.yml +2 -2
  528. data/data/problems/6.yml +2 -2
  529. data/data/problems/60.yml +1 -1
  530. data/data/problems/61.yml +7 -7
  531. data/data/problems/62.yml +1 -1
  532. data/data/problems/63.yml +1 -1
  533. data/data/problems/64.yml +30 -44
  534. data/data/problems/65.yml +19 -19
  535. data/data/problems/66.yml +9 -12
  536. data/data/problems/67.yml +9 -9
  537. data/data/problems/68.yml +3 -3
  538. data/data/problems/69.yml +3 -3
  539. data/data/problems/7.yml +1 -1
  540. data/data/problems/70.yml +4 -4
  541. data/data/problems/71.yml +4 -4
  542. data/data/problems/72.yml +4 -4
  543. data/data/problems/73.yml +4 -4
  544. data/data/problems/74.yml +9 -16
  545. data/data/problems/75.yml +3 -3
  546. data/data/problems/76.yml +1 -1
  547. data/data/problems/77.yml +1 -1
  548. data/data/problems/78.yml +8 -8
  549. data/data/problems/79.yml +2 -2
  550. data/data/problems/8.yml +12 -13
  551. data/data/problems/80.yml +1 -1
  552. data/data/problems/81.yml +8 -10
  553. data/data/problems/82.yml +10 -11
  554. data/data/problems/83.yml +10 -11
  555. data/data/problems/84.yml +45 -37
  556. data/data/problems/85.yml +2 -2
  557. data/data/problems/86.yml +8 -8
  558. data/data/problems/87.yml +1 -1
  559. data/data/problems/88.yml +11 -22
  560. data/data/problems/89.yml +14 -14
  561. data/data/problems/9.yml +6 -7
  562. data/data/problems/90.yml +7 -7
  563. data/data/problems/91.yml +6 -8
  564. data/data/problems/92.yml +6 -11
  565. data/data/problems/93.yml +11 -12
  566. data/data/problems/94.yml +1 -1
  567. data/data/problems/95.yml +2 -2
  568. data/data/problems/96.yml +7 -9
  569. data/data/problems/97.yml +3 -3
  570. data/data/problems/98.yml +2 -2
  571. data/data/problems/99.yml +4 -4
  572. data/euler-manager.gemspec +2 -2
  573. data/example/1/README.md +1 -1
  574. data/example/1/ruby/1.rb +7 -1
  575. data/example/1/scala/1.scala +1 -1
  576. data/example/15/README.md +4 -4
  577. data/example/2/README.md +1 -4
  578. data/languages/c.rb +22 -0
  579. data/languages/elixir.rb +25 -0
  580. data/languages/java.rb +3 -2
  581. data/languages/perl.rb +25 -0
  582. data/languages/php.rb +25 -0
  583. data/lib/euler/version.rb +1 -1
  584. data/rake/clean.rake +0 -2
  585. data/rake/sha_answers.rake +20 -0
  586. data/rake/update.rake +5 -2
  587. data/spec/euler_spec.rb +5 -0
  588. data/templates/c.c +11 -0
  589. data/templates/elixir.ex +1 -0
  590. data/templates/perl.pl +3 -0
  591. data/templates/php.php +5 -0
  592. metadata +148 -164
  593. data/data/images/blackdot.gif +0 -0
  594. data/data/images/bracket_left.gif +0 -0
  595. data/data/images/bracket_right.gif +0 -0
  596. data/data/images/sod_13.gif +0 -119
  597. data/data/images/symbol_asymp.gif +0 -0
  598. data/data/images/symbol_cong.gif +0 -0
  599. data/data/images/symbol_ge.gif +0 -0
  600. data/data/images/symbol_gt.gif +0 -0
  601. data/data/images/symbol_implies.gif +0 -0
  602. data/data/images/symbol_lceil.gif +0 -0
  603. data/data/images/symbol_le.gif +0 -0
  604. data/data/images/symbol_lfloor.gif +0 -0
  605. data/data/images/symbol_lt.gif +0 -0
  606. data/data/images/symbol_maps.gif +0 -0
  607. data/data/images/symbol_minus.gif +0 -0
  608. data/data/images/symbol_ne.gif +0 -0
  609. data/data/images/symbol_plusmn.gif +0 -0
  610. data/data/images/symbol_radic.gif +0 -0
  611. data/data/images/symbol_rceil.gif +0 -0
  612. data/data/images/symbol_rfloor.gif +0 -0
  613. data/data/images/symbol_sum.gif +0 -0
  614. data/data/images/symbol_times.gif +0 -0
  615. data/example/1/haskell/1.hs +0 -3
  616. data/example/12/README.md +0 -20
  617. data/example/12/haskell/12.hs +0 -3
  618. data/example/lib/Euler.hs +0 -1
@@ -1,32 +1,32 @@
1
1
  ---
2
2
  :id: 363
3
3
  :name: Bézier Curves
4
- :url: http://projecteuler.net/problem=363
5
- :content: "\rA cubic Bézier curve is defined by four points: P<sub>0</sub>, P<sub>1</sub>,
6
- P<sub>2</sub> and P<sub>3</sub>.\r\n\nThe curve is constructed as follows: \n\rOn
7
- the segments P<sub>0</sub>P<sub>1</sub>, P<sub>1</sub>P<sub>2</sub> and P<sub>2</sub>P<sub>3</sub>
8
- the points Q<sub>0</sub>,Q<sub>1</sub> and Q<sub>2</sub> are drawn such that P<sub>0</sub>Q<sub>0</sub>/P<sub>0</sub>P<sub>1</sub>=P<sub>1</sub>Q<sub>1</sub>/P<sub>1</sub>P<sub>2</sub>=P<sub>2</sub>Q<sub>2</sub>/P<sub>2</sub>P<sub>3</sub>=t
9
- (t in [0,1]). \n\rOn the segments Q<sub>0</sub>Q<sub>1</sub> and Q<sub>1</sub>Q<sub>2</sub>
10
- the points R<sub>0</sub> and R<sub>1</sub> are drawn such that\rQ<sub>0</sub>R<sub>0</sub>/Q<sub>0</sub>Q<sub>1</sub>=Q<sub>1</sub>R<sub>1</sub>/Q<sub>1</sub>Q<sub>2</sub>=t
11
- for the same value of t. \n\rOn the segment R<sub>0</sub>R<sub>1</sub> the point
12
- B is drawn such that R<sub>0</sub>B/R<sub>0</sub>R<sub>1</sub>=t for the same value
13
- of t.\rThe Bézier curve defined by the points P<sub>0</sub>, P<sub>1</sub>, P<sub>2</sub>,
14
- P<sub>3</sub> is the locus of B as Q<sub>0</sub> takes all possible positions on
15
- the segment P<sub>0</sub>P<sub>1</sub>. (Please note that for all points the value
16
- of t is the same.)\n\n<applet code=\"CabriJava.class\" width=\"390\" height=\"300\"
17
- align=\"right\" hspace=\"20\" archive=\"project/images/bezier/CabriJava.jar\">\r\n
18
- \ <param name=\"lang\" value=\"en\">\r\n <param name=\"file\" value=\"project/images/bezier/bezier.fig\">\r\n
19
- \ <param name=\"loop\" value=\"true\">\r\n</applet>\n\nIn the applet to the right
20
- you can drag the points P<sub>0</sub>, P<sub>1</sub>, P<sub>2</sub> and P<sub>3</sub>
21
- to see what the Bézier curve (green curve) defined by those points looks like. You
22
- can also drag the point Q<sub>0</sub> along the segment P<sub>0</sub>P<sub>1</sub>.\n\nFrom
23
- the construction it is clear that the Bézier curve will be tangent to the segments
24
- P<sub>0</sub>P<sub>1</sub> in P<sub>0</sub> and P<sub>2</sub>P<sub>3</sub> in P<sub>3</sub>.\n\nA
25
- cubic Bézier curve with P<sub>0</sub>=(1,0), P<sub>1</sub>=(1,<var>v</var>), P<sub>2</sub>=(<var>v</var>,1)
26
- and P<sub>3</sub>=(0,1) is used to approximate a quarter circle. \n\rThe value
27
- <var>v</var> ![>]({{ images_dir }}/symbol_gt.gif)0 is chosen such that the area
28
- enclosed by the lines OP<sub>0</sub>, OP<sub>3</sub> and the curve is equal to <sup>π</sup>/<sub>4</sub>
29
- (the area of the quarter circle).\n\nBy how many percent does the length of the
30
- curve differ from the length of the quarter circle? \n\rThat is, if L is the length
31
- of the curve, calculate 100\\*<sup>(L-π/2)</sup>/<sub>(π/2)</sub>. \n\rGive your
32
- answer rounded to 10 digits behind the decimal point.\n\n"
4
+ :url: https://projecteuler.net/problem=363
5
+ :content: "A cubic Bézier curve is defined by four points: P<sub>0</sub>, P<sub>1</sub>,
6
+ P<sub>2</sub> and P<sub>3</sub>.\n\n ![p363_bezier.png]({{ images_dir }}/p363_bezier.png)\n\nThe
7
+ curve is constructed as follows: \nOn the segments P<sub>0</sub>P<sub>1</sub>,
8
+ P<sub>1</sub>P<sub>2</sub> and P<sub>2</sub>P<sub>3</sub> the points Q<sub>0</sub>,Q<sub>1</sub>
9
+ and Q<sub>2</sub> are drawn such that \nP<sub>0</sub>Q<sub>0</sub> / P<sub>0</sub>P<sub>1</sub>
10
+ = P<sub>1</sub>Q<sub>1</sub> / P<sub>1</sub>P<sub>2</sub> = P<sub>2</sub>Q<sub>2</sub>
11
+ / P<sub>2</sub>P<sub>3</sub> = t (t in [0,1]). \nOn the segments Q<sub>0</sub>Q<sub>1</sub>
12
+ and Q<sub>1</sub>Q<sub>2</sub> the points R<sub>0</sub> and R<sub>1</sub> are drawn
13
+ such that \nQ<sub>0</sub>R<sub>0</sub> / Q<sub>0</sub>Q<sub>1</sub> = Q<sub>1</sub>R<sub>1</sub>
14
+ / Q<sub>1</sub>Q<sub>2</sub> = t for the same value of t. \nOn the segment R<sub>0</sub>R<sub>1</sub>
15
+ the point B is drawn such that R<sub>0</sub>B / R<sub>0</sub>R<sub>1</sub> = t for
16
+ the same value of t. \nThe Bézier curve defined by the points P<sub>0</sub>, P<sub>1</sub>,
17
+ P<sub>2</sub>, P<sub>3</sub> is the locus of B as Q<sub>0</sub> takes all possible
18
+ positions on the segment P<sub>0</sub>P<sub>1</sub>. \n(Please note that for all
19
+ points the value of t is the same.)\n\nAt [this (external) web address](http://home.kpn.nl/hklein/bezier/bezier.html)
20
+ you will find an applet that allows you to drag the points P<sub>0</sub>, P<sub>1</sub>,
21
+ P<sub>2</sub> and P<sub>3</sub> to see what the Bézier curve (green curve) defined
22
+ by those points looks like. You can also drag the point Q<sub>0</sub> along the
23
+ segment P<sub>0</sub>P<sub>1</sub>.\n\nFrom the construction it is clear that the
24
+ Bézier curve will be tangent to the segments P<sub>0</sub>P<sub>1</sub> in P<sub>0</sub>
25
+ and P<sub>2</sub>P<sub>3</sub> in P<sub>3</sub>.\n\nA cubic Bézier curve with P<sub>0</sub>=(1,0),
26
+ P<sub>1</sub>=(1,<var>v</var>), P<sub>2</sub>=(<var>v</var>,1) and P<sub>3</sub>=(0,1)
27
+ is used to approximate a quarter circle. \nThe value <var>v</var> \\> 0 is chosen
28
+ such that the area enclosed by the lines OP<sub>0</sub>, OP<sub>3</sub> and the
29
+ curve is equal to <sup>π</sup>/<sub>4</sub> (the area of the quarter circle).\n\nBy
30
+ how many percent does the length of the curve differ from the length of the quarter
31
+ circle?\n\n| That is, if L is the length of the curve, calculate 100 × | \n\nL
32
+ π/2\nπ/2\n |\n\nGive your answer rounded to 10 digits behind the decimal point.\n\n"
@@ -1,13 +1,13 @@
1
1
  ---
2
2
  :id: 364
3
3
  :name: Comfortable distance
4
- :url: http://projecteuler.net/problem=364
4
+ :url: https://projecteuler.net/problem=364
5
5
  :content: "There are <var>N</var> seats in a row. <var>N</var> people come after each
6
6
  other to fill the seats according to the following rules:\n\n1. If there is any
7
7
  seat whose adjacent seat(s) are not occupied take such a seat.\n2. If there is no
8
8
  such seat and there is any seat for which only one adjacent seat is occupied take
9
- such a seat.\n3. Otherwise take one of the remaining available seats. \n\rLet T(<var>N</var>)
9
+ such a seat.\n3. Otherwise take one of the remaining available seats. \nLet T(<var>N</var>)
10
10
  be the number of possibilities that <var>N</var> seats are occupied by <var>N</var>
11
- people with the given rules. \n The following figure shows T(4)=8.\r\r\r\n ![]({{
12
- images_dir }}/p_364_comf_dist.gif)\n\nWe can verify that T(10) = 61632 and T(1 000)
11
+ people with the given rules. \n The following figure shows T(4)=8.\n ![p364_comf_dist.gif]({{
12
+ images_dir }}/p364_comf_dist.gif)\n\nWe can verify that T(10) = 61632 and T(1 000)
13
13
  mod 100 000 007 = 47255094.\n\nFind T(1 000 000) mod 100 000 007.\n\n"
@@ -1,11 +1,11 @@
1
1
  ---
2
2
  :id: 365
3
3
  :name: A huge binomial coefficient
4
- :url: http://projecteuler.net/problem=365
4
+ :url: https://projecteuler.net/problem=365
5
5
  :content: |+
6
- The binomial coeffient C(10<sup>18</sup>,10<sup>9</sup>) is a number with more than 9 billion (9 ![×]({{ images_dir }}/symbol_times.gif)10<sup>9</sup>) digits.
6
+ The binomial coefficient C(10<sup>18</sup>,10<sup>9</sup>) is a number with more than 9 billion (9×10<sup>9</sup>) digits.
7
7
 
8
8
  Let M(n,k,m) denote the binomial coefficient C(n,k) modulo m.
9
9
 
10
- Calculate ![]({{ images_dir }}/symbol_sum.gif)M(10<sup>18</sup>,10<sup>9</sup>,p\*q\*r) for 1000 ![<]({{ images_dir }}/symbol_lt.gif)p ![<]({{ images_dir }}/symbol_lt.gif)q ![<]({{ images_dir }}/symbol_lt.gif)r ![<]({{ images_dir }}/symbol_lt.gif)5000 and p,q,r prime.
10
+ Calculate ∑M(10<sup>18</sup>,10<sup>9</sup>,p\*q\*r) for 1000\<p\<q\<r\<5000 and p,q,r prime.
11
11
 
@@ -1,22 +1,19 @@
1
1
  ---
2
2
  :id: 366
3
3
  :name: Stone Game III
4
- :url: http://projecteuler.net/problem=366
5
- :content: "Two players, Anton and Bernhard, are playing the following game. \n\rThere
6
- is one pile of n stones. \n\rThe first player may remove any positive number of
7
- stones, but not the whole pile. \n\rThereafter, each player may remove at most
8
- twice the number of stones his opponent took on the previous move. \n\rThe player
9
- who removes the last stone wins.\n\nE.g. n=5 \n\rIf the first player takes anything
10
- more than one stone the next player will be able to take all remaining stones. \n\rIf
11
- the first player takes one stone, leaving four, his opponent will take also one
12
- stone, leaving three stones. \n\rThe first player cannot take all three because
13
- he may take at most 2x1=2 stones. So let's say he takes also one stone, leaving
14
- 2. The second player can take the two remaining stones and wins. \n\rSo 5 is a
15
- losing position for the first player. \n\rFor some winning positions there is more
16
- than one possible move for the first player. \n\rE.g. when n=17 the first player
17
- can remove one or four stones.\n\nLet M(n) be the maximum number of stones the first
18
- player can take from a winning position _at his first turn_ and M(n)=0 for any other
19
- position.\n\n![]({{ images_dir }}/symbol_sum.gif)M(n) for n ![]({{ images_dir
20
- }}/symbol_le.gif)100 is 728.\n\nFind ![∑]({{ images_dir }}/symbol_sum.gif)M(n) for
21
- n ![≤]({{ images_dir }}/symbol_le.gif)10<sup>18</sup>.\rGive your answer modulo
22
- 10<sup>8</sup>.\n\n"
4
+ :url: https://projecteuler.net/problem=366
5
+ :content: "Two players, Anton and Bernhard, are playing the following game. \nThere
6
+ is one pile of n stones. \nThe first player may remove any positive number of stones,
7
+ but not the whole pile. \nThereafter, each player may remove at most twice the
8
+ number of stones his opponent took on the previous move. \nThe player who removes
9
+ the last stone wins.\n\nE.g. n=5 \nIf the first player takes anything more than
10
+ one stone the next player will be able to take all remaining stones. \nIf the first
11
+ player takes one stone, leaving four, his opponent will take also one stone, leaving
12
+ three stones. \nThe first player cannot take all three because he may take at most
13
+ 2x1=2 stones. So let's say he takes also one stone, leaving 2. The second player
14
+ can take the two remaining stones and wins. \nSo 5 is a losing position for the
15
+ first player. \nFor some winning positions there is more than one possible move
16
+ for the first player. \nE.g. when n=17 the first player can remove one or four
17
+ stones.\n\nLet M(n) be the maximum number of stones the first player can take from
18
+ a winning position _at his first turn_ and M(n)=0 for any other position.\n\n∑M(n)
19
+ for n≤100 is 728.\n\nFind ∑M(n) for n≤10<sup>18</sup>. Give your answer modulo 10<sup>8</sup>.\n\n"
@@ -1,19 +1,19 @@
1
1
  ---
2
2
  :id: 367
3
3
  :name: Bozo sort
4
- :url: http://projecteuler.net/problem=367
4
+ :url: https://projecteuler.net/problem=367
5
5
  :content: " **Bozo sort** , not to be confused with the slightly less efficient **bogo
6
6
  sort** , consists out of checking if the input sequence is sorted and if not swapping
7
7
  randomly two elements. This is repeated until eventually the sequence is sorted.\n\nIf
8
8
  we consider all permutations of the first 4 natural numbers as input the expectation
9
- value of the number of swaps, averaged over all 4! input sequences is 24.75. \n\rThe
9
+ value of the number of swaps, averaged over all 4! input sequences is 24.75. \nThe
10
10
  already sorted sequence takes 0 steps.\n\nIn this problem we consider the following
11
- variant on bozo sort. \n\rIf the sequence is not in order we pick three elements
12
- at random and shuffle these three elements randomly. \n\rAll 3!=6 permutations
13
- of those three elements are equally likely. \n\rThe already sorted sequence will
14
- take 0 steps. \n\rIf we consider all permutations of the first 4 natural numbers
15
- as input the expectation value of the number of shuffles, averaged over all 4! input
16
- sequences is 27.5. \n\rConsider as input sequences the permutations of the first
17
- 11 natural numbers. \n\rAveraged over all 11! input sequences, what is the expected
18
- number of shuffles this sorting algorithm will perform?\n\nGive your answer rounded
19
- to the nearest integer.\n\n"
11
+ variant on bozo sort. \nIf the sequence is not in order we pick three elements
12
+ at random and shuffle these three elements randomly. \nAll 3!=6 permutations of
13
+ those three elements are equally likely. \nThe already sorted sequence will take
14
+ 0 steps. \nIf we consider all permutations of the first 4 natural numbers as input
15
+ the expectation value of the number of shuffles, averaged over all 4! input sequences
16
+ is 27.5. \nConsider as input sequences the permutations of the first 11 natural
17
+ numbers. \nAveraged over all 11! input sequences, what is the expected number of
18
+ shuffles this sorting algorithm will perform?\n\nGive your answer rounded to the
19
+ nearest integer.\n\n"
@@ -1,22 +1,18 @@
1
1
  ---
2
2
  :id: 368
3
3
  :name: A Kempner-like series
4
- :url: http://projecteuler.net/problem=368
5
- :content: "| The **harmonic series** 1 | + | \n\n| 1 |\n| 2 |\n\n | + | \n\n| 1 |\n|
6
- 3 |\n\n | + | \n\n| 1 |\n| 4 |\n\n | + ... is well known to be divergent. |\n\nIf
7
- we however omit from this series every term where the denominator has a 9 in it,
8
- the series remarkably enough converges to approximately 22.9206766193. \n\rThis
9
- modified harmonic series is called the **Kempner** series.\n\nLet us now consider
10
- another modified harmonic series by omitting from the harmonic series every term
11
- where the denominator has 3 or more equal consecutive digits.\rOne can verify that
12
- out of the first 1200 terms of the harmonic series, only 20 terms will be omitted.
13
- \ \n\rThese 20 omitted terms are:\n\n \n \n\n| 1 |\n| 111 |\n\n | , | \n\n| 1 |\n|
14
- 222 |\n\n | , | \n\n| 1 |\n| 333 |\n\n | , | \n\n| 1 |\n| 444 |\n\n | , | \n\n|
15
- 1 |\n| 555 |\n\n | , | \n\n| 1 |\n| 666 |\n\n | , | \n\n| 1 |\n| 777 |\n\n | , |
16
- \n\n| 1 |\n| 888 |\n\n | , | \n\n| 1 |\n| 999 |\n\n | , | \n\n| 1 |\n| 1000 |\n\n
17
- | , | \n\n| 1 |\n| 1110 |\n\n | , |\n\n \n \n\n| 1 |\n| 1111 |\n\n | , | \n\n| 1
18
- |\n| 1112 |\n\n | , | \n\n| 1 |\n| 1113 |\n\n | , | \n\n| 1 |\n| 1114 |\n\n | ,
19
- | \n\n| 1 |\n| 1115 |\n\n | , | \n\n| 1 |\n| 1116 |\n\n | , | \n\n| 1 |\n| 1117
20
- |\n\n | , | \n\n| 1 |\n| 1118 |\n\n | and | \n\n| 1 |\n| 1119 |\n\n | . |\n\nThis
21
- series converges as well.\n\nFind the value the series converges to. \n\rGive your
4
+ :url: https://projecteuler.net/problem=368
5
+ :content: "The **harmonic series** $1 + \\dfrac{1}{2} + \\dfrac{1}{3} + \\dfrac{1}{4}
6
+ + ...$ is well known to be divergent.\n\nIf we however omit from this series every
7
+ term where the denominator has a 9 in it, the series remarkably enough converges
8
+ to approximately 22.9206766193. \nThis modified harmonic series is called the **Kempner**
9
+ series.\n\nLet us now consider another modified harmonic series by omitting from
10
+ the harmonic series every term where the denominator has 3 or more equal consecutive
11
+ digits. One can verify that out of the first 1200 terms of the harmonic series,
12
+ only 20 terms will be omitted. \nThese 20 omitted terms are:\n\n$$\\dfrac{1}{111},
13
+ \\dfrac{1}{222}, \\dfrac{1}{333}, \\dfrac{1}{444}, \\dfrac{1}{555}, \\dfrac{1}{666},
14
+ \\dfrac{1}{777}, \\dfrac{1}{888}, \\dfrac{1}{999}, \\dfrac{1}{1000}, \\dfrac{1}{1110},
15
+ \\\\\\ \\dfrac{1}{1111}, \\dfrac{1}{1112}, \\dfrac{1}{1113}, \\dfrac{1}{1114}, \\dfrac{1}{1115},
16
+ \\dfrac{1}{1116}, \\dfrac{1}{1117}, \\dfrac{1}{1118}, \\dfrac{1}{1119}$$\n\nThis
17
+ series converges as well.\n\nFind the value the series converges to. \nGive your
22
18
  answer rounded to 10 digits behind the decimal point.\n\n"
@@ -1,11 +1,11 @@
1
1
  ---
2
2
  :id: 369
3
3
  :name: Badugi
4
- :url: http://projecteuler.net/problem=369
4
+ :url: https://projecteuler.net/problem=369
5
5
  :content: |+
6
6
  In a standard 52 card deck of playing cards, a set of 4 cards is a **Badugi** if it contains 4 cards with no pairs and no two cards of the same suit.
7
7
 
8
8
  Let f(<var>n</var>) be the number of ways to choose <var>n</var> cards with a 4 card subset that is a Badugi. For example, there are 2598960 ways to choose five cards from a standard 52 card deck, of which 514800 contain a 4 card subset that is a Badugi, so f(5) = 514800.
9
9
 
10
- Find ![]({{ images_dir }}/symbol_sum.gif)f(<var>n</var>) for 4 ![]({{ images_dir }}/symbol_le.gif) <var>n</var> ![]({{ images_dir }}/symbol_le.gif) 13.
10
+ Find ∑f(<var>n</var>) for 4 ≤ <var>n</var> ≤ 13.
11
11
 
data/data/problems/37.yml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  :id: 37
3
3
  :name: Truncatable primes
4
- :url: http://projecteuler.net/problem=37
4
+ :url: https://projecteuler.net/problem=37
5
5
  :content: |+
6
6
  The number 3797 has an interesting property. Being prime itself, it is possible to continuously remove digits from left to right, and remain prime at each stage: 3797, 797, 97, and 7. Similarly we can work from right to left: 3797, 379, 37, and 3.
7
7
 
@@ -1,13 +1,13 @@
1
1
  ---
2
2
  :id: 370
3
3
  :name: Geometric triangles
4
- :url: http://projecteuler.net/problem=370
4
+ :url: https://projecteuler.net/problem=370
5
5
  :content: |+
6
- Let us define a _geometric triangle_ as an integer sided triangle with sides <var>a</var> ![]({{ images_dir }}/symbol_le.gif) <var>b</var> ![]({{ images_dir }}/symbol_le.gif) <var>c</var> so that its sides form a **geometric progression** , i.e. <var>b<sup>2</sup></var> = <var>a</var> · <var>c</var> . 
6
+ Let us define a _geometric triangle_ as an integer sided triangle with sides <var>a</var> ≤ <var>b</var> ≤ <var>c</var> so that its sides form a **geometric progression** , i.e. <var>b<sup>2</sup></var>&nbsp;=&nbsp;<var>a</var>&nbsp;·&nbsp;<var>c</var>&nbsp;.&nbsp;
7
7
 
8
8
  An example of such a geometric triangle is the triangle with sides <var>a</var> = 144, <var>b</var> = 156 and <var>c</var> = 169.
9
9
 
10
- There are 861805 geometric triangles with perimeter ![]({{ images_dir }}/symbol_le.gif) 10<sup>6</sup> .
10
+ There are 861805 geometric triangles with perimeter ≤ 10<sup>6</sup> .
11
11
 
12
- How many geometric triangles exist with perimeter ![]({{ images_dir }}/symbol_le.gif) 2.5·10<sup>13</sup> ?
12
+ How many geometric triangles exist with perimeter ≤ 2.5·10<sup>13</sup> ?
13
13
 
@@ -1,12 +1,12 @@
1
1
  ---
2
2
  :id: 371
3
3
  :name: Licence plates
4
- :url: http://projecteuler.net/problem=371
4
+ :url: https://projecteuler.net/problem=371
5
5
  :content: "Oregon licence plates consist of three letters followed by a three digit
6
- number (each digit can be from [0..9]). \n\rWhile driving to work Seth plays the
7
- following game: \n\rWhenever the numbers of two licence plates seen on his trip
8
- add to 1000 that's a win.\n\nE.g. MIC-012 and HAN-988 is a win and RYU-500 and SET-500
6
+ number (each digit can be from [0..9]). \nWhile driving to work Seth plays the
7
+ following game: \nWhenever the numbers of two licence plates seen on his trip add
8
+ to 1000 that's a win.\n\nE.g. MIC-012 and HAN-988 is a win and RYU-500 and SET-500
9
9
  too. (as long as he sees them in the same trip).\n\nFind the expected number of
10
- plates he needs to see for a win. \n\rGive your answer rounded to 8 decimal places
10
+ plates he needs to see for a win. \nGive your answer rounded to 8 decimal places
11
11
  behind the decimal point.\n\n**Note:** We assume that each licence plate seen is
12
12
  equally likely to have any three digit number on it.\n\n"
@@ -1,11 +1,10 @@
1
1
  ---
2
2
  :id: 372
3
3
  :name: Pencils of rays
4
- :url: http://projecteuler.net/problem=372
4
+ :url: https://projecteuler.net/problem=372
5
5
  :content: "Let R(<var>M</var>, <var>N</var>) be the number of lattice points (<var>x</var>,
6
- <var>y</var>) which satisfy <var>M</var> ![<]({{ images_dir }}/symbol_lt.gif)<var>x</var>
7
- ![]({{ images_dir }}/symbol_le.gif)<var>N</var>, <var>M</var> ![<]({{ images_dir
8
- }}/symbol_lt.gif)<var>y</var> ![≤]({{ images_dir }}/symbol_le.gif)<var>N</var> and
9
- ![]({{ images_dir }}/p_372_pencilray1.jpg) is odd. \n\rWe can verify that R(0,
10
- 100) = 3019 and R(100, 10000) = 29750422. \n\rFind R(2·10<sup>6</sup>, 10<sup>9</sup>).\n\n<u><i>Note</i></u>:
11
- ![]({{ images_dir }}/p_372_pencilray2.gif) represents the floor function.\n\n"
6
+ <var>y</var>) which satisfy <var>M</var>\\<<var>x</var>≤<var>N</var>, <var>M</var>\\<<var>y</var>≤<var>N</var>
7
+ and ![p372_pencilray1.jpg]({{ images_dir }}/p372_pencilray1.jpg) is odd. \nWe can
8
+ verify that R(0, 100) = 3019 and R(100, 10000) = 29750422. \nFind R(2·10<sup>6</sup>,
9
+ 10<sup>9</sup>).\n\n<u><i>Note</i></u>: ![p372_pencilray2.gif]({{ images_dir }}/p372_pencilray2.gif)
10
+ represents the floor function.\n\n"
@@ -1,9 +1,13 @@
1
1
  ---
2
2
  :id: 373
3
3
  :name: Circumscribed Circles
4
- :url: http://projecteuler.net/problem=373
5
- :content: "Every triangle has a circumscribed circle that goes through the three vertices.\rConsider
6
- all integer sided triangles for which the radius of the circumscribed circle is
7
- integral as well.\n\nLet S(<var>n</var>) be the sum of the radii of the circumscribed
8
- circles of all such triangles for which the radius does not exceed <var>n</var>.\n\nS(100)=4950
9
- and S(1200)=1653605.\n\nFind S(10<sup>7</sup>).\n\n"
4
+ :url: https://projecteuler.net/problem=373
5
+ :content: |+
6
+ Every triangle has a circumscribed circle that goes through the three vertices. Consider all integer sided triangles for which the radius of the circumscribed circle is integral as well.
7
+
8
+ Let S(<var>n</var>) be the sum of the radii of the circumscribed circles of all such triangles for which the radius does not exceed <var>n</var>.
9
+
10
+ S(100)=4950 and S(1200)=1653605.
11
+
12
+ Find S(10<sup>7</sup>).
13
+
@@ -1,19 +1,17 @@
1
1
  ---
2
2
  :id: 374
3
3
  :name: Maximum Integer Partition Product
4
- :url: http://projecteuler.net/problem=374
4
+ :url: https://projecteuler.net/problem=374
5
5
  :content: "An integer partition of a number <var>n</var> is a way of writing <var>n</var>
6
6
  as a sum of positive integers.\n\nPartitions that differ only in the order of their
7
- summands are considered the same.\rA partition of <var>n</var> into **distinct parts**
7
+ summands are considered the same. A partition of <var>n</var> into **distinct parts**
8
8
  is a partition of <var>n</var> in which every part occurs at most once.\n\nThe partitions
9
- of 5 into distinct parts are:\r \n5, 4+1 and 3+2.\n\nLet f(<var>n</var>) be the
10
- maximum product of the parts of any such partition of <var>n</var> into distinct
11
- parts and let m(<var>n</var>) be the number of elements of any such partition of
12
- <var>n</var> with that product.\n\nSo f(5)=6 and m(5)=2.\n\nFor <var>n</var>=10
13
- the partition with the largest product is 10=2+3+5, which gives f(10)=30 and m(10)=3.\r
14
- \ \nAnd their product, f(10)·m(10) = 30·3 = 90\n\nIt can be verified that\r \n
15
- ![∑]({{ images_dir }}/symbol_sum.gif)f(<var>n</var>)·m(<var>n</var>) for 1 ![≤]({{
16
- images_dir }}/symbol_le.gif) <var>n</var> ![]({{ images_dir }}/symbol_le.gif) 100
17
- = 1683550844462.\n\nFind ![∑]({{ images_dir }}/symbol_sum.gif)f(<var>n</var>)·m(<var>n</var>)
18
- for 1 ![≤]({{ images_dir }}/symbol_le.gif) <var>n</var> ![≤]({{ images_dir }}/symbol_le.gif)
19
- 10<sup>14</sup>.\r \nGive your answer modulo 982451653, the 50 millionth prime.\n\n"
9
+ of 5 into distinct parts are: \n5, 4+1 and 3+2.\n\nLet f(<var>n</var>) be the maximum
10
+ product of the parts of any such partition of <var>n</var> into distinct parts and
11
+ let m(<var>n</var>) be the number of elements of any such partition of <var>n</var>
12
+ with that product.\n\nSo f(5)=6 and m(5)=2.\n\nFor <var>n</var>=10 the partition
13
+ with the largest product is 10=2+3+5, which gives f(10)=30 and m(10)=3. \nAnd their
14
+ product, f(10)·m(10) = 30·3 = 90\n\nIt can be verified that \n∑f(<var>n</var>)·m(<var>n</var>)
15
+ for 1 ≤ <var>n</var> ≤ 100 = 1683550844462.\n\nFind ∑f(<var>n</var>)·m(<var>n</var>)
16
+ for 1 <var>n</var> ≤ 10<sup>14</sup>. \nGive your answer modulo 982451653, the
17
+ 50 millionth prime.\n\n"
@@ -1,18 +1,15 @@
1
1
  ---
2
2
  :id: 375
3
3
  :name: Minimum of subsequences
4
- :url: http://projecteuler.net/problem=375
5
- :content: "<style type=\"text/css\"><![CDATA[\r\ntable.p375 td {\r\n padding: 0px
6
- 3px 0px 3px;\r\n vertical-align: bottom;\r\n text-align: left;\r\n}\r\n]]></style>\n\nLet
7
- <var>S</var><sub><var>n</var></sub> be an integer sequence produced with the following
8
- pseudo-random number generator:\n\n<center><table class=\"p375\">\r\n <tr>\r\n
9
- \ <td style=\"text-align:right\">\n<var>S</var><sub>0</sub>\n</td>\r\n <td>=<sub> </sub>\n</td>\r\n
10
- \ <td>290797<sub> </sub>\n</td>\r\n </tr>\n<tr>\r\n <td>\n<var>S</var><sub><var>n</var>+1</sub>\n</td>\r\n
11
- \ <td>=<sub> </sub>\n</td>\r\n <td>\n<var>S</var><sub><var>n</var></sub><sup>2</sup>
12
- mod 50515093</td>\r\n </tr>\r\n</table></center>\n\nLet A(<var>i</var>, <var>j</var>)
4
+ :url: https://projecteuler.net/problem=375
5
+ :content: "Let <var>S</var><sub><var>n</var></sub> be an integer sequence produced
6
+ with the following pseudo-random number generator:\n\n<center><table class=\"p375\">\n<tr>\n<td
7
+ style=\"text-align:right;\">\n<var>S</var><sub>0</sub>\n</td>\n <td>=<sub> </sub>\n</td>\n
8
+ \ <td>290797<sub> </sub>\n</td>\n </tr>\n<tr>\n<td>\n<var>S</var><sub><var>n</var>+1</sub>\n</td>\n
9
+ \ <td>=<sub> </sub>\n</td>\n <td>\n<var>S</var><sub><var>n</var></sub><sup>2</sup>
10
+ mod 50515093</td>\n </tr>\n</table></center>\n\nLet A(<var>i</var>, <var>j</var>)
13
11
  be the minimum of the numbers <var>S</var><sub><var>i</var></sub>, <var>S</var><sub><var>i</var>+1</sub>,
14
- ... , <var>S</var><sub><var>j</var></sub> for <var>i</var> ![]({{ images_dir }}/symbol_le.gif)
15
- <var>j</var>. \n\rLet M(<var>N</var>) = ΣA(<var>i</var>, <var>j</var>) for 1 ![]({{
16
- images_dir }}/symbol_le.gif) <var>i</var> ![≤]({{ images_dir }}/symbol_le.gif) <var>j</var>
17
- ![≤]({{ images_dir }}/symbol_le.gif) <var>N</var>. \n\rWe can verify that M(10)
18
- = 432256955 and M(10 000) = 3264567774119.\n\nFind M(2 000 000 000).\n\n"
12
+ ... , <var>S</var><sub><var>j</var></sub> for <var>i</var> ≤ <var>j</var>. \nLet
13
+ M(<var>N</var>) = ΣA(<var>i</var>, <var>j</var>) for 1 ≤ <var>i</var> ≤ <var>j</var>
14
+ <var>N</var>. \nWe can verify that M(10) = 432256955 and M(10 000) = 3264567774119.\n\nFind
15
+ M(2 000 000 000).\n\n"
@@ -1,23 +1,23 @@
1
1
  ---
2
2
  :id: 376
3
3
  :name: Nontransitive sets of dice
4
- :url: http://projecteuler.net/problem=376
4
+ :url: https://projecteuler.net/problem=376
5
5
  :content: "Consider the following set of dice with nonstandard pips:\n\nDie A: 1 4
6
- 4 4 4 4 \n\rDie B: 2 2 2 5 5 5 \n\rDie C: 3 3 3 3 3 6\n\nA game is played by two
7
- players picking a die in turn and rolling it. The player who rolls the highest value
8
- wins.\n\nIf the first player picks die A and the second player picks die B we get
9
- \ \n\rP(second player wins) = <sup>7</sup>/<sub>12</sub> > <sup>1</sup>/<sub>2</sub>\n\nIf
10
- the first player picks die B and the second player picks die C we get \n\rP(second
11
- player wins) = <sup>7</sup>/<sub>12</sub> > <sup>1</sup>/<sub>2</sub>\n\nIf the
12
- first player picks die C and the second player picks die A we get \n\rP(second
13
- player wins) = <sup>25</sup>/<sub>36</sub> > <sup>1</sup>/<sub>2</sub>\n\nSo whatever
14
- die the first player picks, the second player can pick another die and have a larger
15
- than 50% chance of winning. \n\rA set of dice having this property is called a
16
- **nontransitive set of dice** .\n\nWe wish to investigate how many sets of nontransitive
17
- dice exist. We will assume the following conditions:\n\n- There are three six-sided
18
- dice with each side having between 1 and <var>N</var> pips, inclusive.\n- Dice with
19
- the same set of pips are equal, regardless of which side on the die the pips are
20
- located.\n- The same pip value may appear on multiple dice; if both players roll
21
- the same value neither player wins.\n- The sets of dice {A,B,C}, {B,C,A} and {C,A,B}
22
- are the same set.\n\nFor <var>N</var> = 7 we find there are 9780 such sets. \n\rHow
23
- many are there for <var>N</var> = 30 ?\n\n"
6
+ 4 4 4 4 \nDie B: 2 2 2 5 5 5 \nDie C: 3 3 3 3 3 6\n\nA game is played by two players
7
+ picking a die in turn and rolling it. The player who rolls the highest value wins.\n\nIf
8
+ the first player picks die A and the second player picks die B we get \nP(second
9
+ player wins) = <sup>7</sup>/<sub>12</sub> \\> <sup>1</sup>/<sub>2</sub>\n\nIf the
10
+ first player picks die B and the second player picks die C we get \nP(second player
11
+ wins) = <sup>7</sup>/<sub>12</sub> \\> <sup>1</sup>/<sub>2</sub>\n\nIf the first
12
+ player picks die C and the second player picks die A we get \nP(second player wins)
13
+ = <sup>25</sup>/<sub>36</sub> \\> <sup>1</sup>/<sub>2</sub>\n\nSo whatever die the
14
+ first player picks, the second player can pick another die and have a larger than
15
+ 50% chance of winning. \nA set of dice having this property is called a **nontransitive
16
+ set of dice**.\n\nWe wish to investigate how many sets of nontransitive dice exist.
17
+ We will assume the following conditions:\n\n- There are three six-sided dice with
18
+ each side having between 1 and <var>N</var> pips, inclusive.\n- Dice with the same
19
+ set of pips are equal, regardless of which side on the die the pips are located.\n-
20
+ The same pip value may appear on multiple dice; if both players roll the same value
21
+ neither player wins.\n- The sets of dice {A,B,C}, {B,C,A} and {C,A,B} are the same
22
+ set.\n\nFor <var>N</var> = 7 we find there are 9780 such sets. \nHow many are there
23
+ for <var>N</var> = 30 ?\n\n"
@@ -1,10 +1,10 @@
1
1
  ---
2
2
  :id: 377
3
3
  :name: Sum of digits, experience 13
4
- :url: http://projecteuler.net/problem=377
4
+ :url: https://projecteuler.net/problem=377
5
5
  :content: "There are 16 positive integers that do not have a zero in their digits
6
- and that have a digital sum equal to 5, namely: \n\r5, 14, 23, 32, 41, 113, 122,
7
- 131, 212, 221, 311, 1112, 1121, 1211, 2111 and 11111. \n\rTheir sum is 17891.\n\nLet
6
+ and that have a digital sum equal to 5, namely: \n5, 14, 23, 32, 41, 113, 122,
7
+ 131, 212, 221, 311, 1112, 1121, 1211, 2111 and 11111. \nTheir sum is 17891.\n\nLet
8
8
  <var>f</var>(<var>n</var>) be the sum of all positive integers that do not have
9
- a zero in their digits and have a digital sum equal to <var>n</var>.\n\nFind ![]({{
10
- images_dir }}/sod_13.gif). \n\rGive the last 9 digits as your answer.\n\n"
9
+ a zero in their digits and have a digital sum equal to <var>n</var>.\n\nFind $\\displaystyle
10
+ \\sum\\_{i=1}^{17} f(13^i)$. \nGive the last 9 digits as your answer.\n\n"
@@ -1,12 +1,11 @@
1
1
  ---
2
2
  :id: 378
3
3
  :name: Triangle Triples
4
- :url: http://projecteuler.net/problem=378
5
- :content: "| \rLet T(<var>n</var>) be the <var>n</var><sup>th</sup> triangle number,
6
- so T(<var>n</var>) =\r | \n\n| <var>n</var> (<var>n</var>+1) |\n| 2 |\n\n | \r.\r
7
- |\n\nLet dT(<var>n</var>) be the number of divisors of T(<var>n</var>). \n\rE.g.:\rT(7)
8
- = 28 and dT(7) = 6.\n\nLet Tr(<var>n</var>) be the number of triples (<var>i</var>,
9
- <var>j</var>, <var>k</var>) such that 1 ![]({{ images_dir }}/symbol_le.gif) <var>i
10
- n</var> and dT(<var>i</var>) > dT(<var>j</var>) > dT(<var>k</var>). \n\rTr(20)
11
- = 14, Tr(100) = 5772 and Tr(1000) = 11174776.\n\nFind Tr(60 000 000). \n\rGive
12
- the last 18 digits of your answer.\n\n"
4
+ :url: https://projecteuler.net/problem=378
5
+ :content: "| Let T(<var>n</var>) be the <var>n</var><sup>th</sup> triangle number,
6
+ so T(<var>n</var>) = | \n\n| <var>n</var> (<var>n</var>+1) |\n| 2 |\n\n | . |\n\nLet
7
+ dT(<var>n</var>) be the number of divisors of T(<var>n</var>). \nE.g.: T(7) = 28
8
+ and dT(7) = 6.\n\nLet Tr(<var>n</var>) be the number of triples (<var>i</var>, <var>j</var>,
9
+ <var>k</var>) such that 1 ≤ <var>i &lt; j &lt; k ≤ n</var> and dT(<var>i</var>)
10
+ \\> dT(<var>j</var>) \\> dT(<var>k</var>). \nTr(20) = 14, Tr(100) = 5772 and Tr(1000)
11
+ = 11174776.\n\nFind Tr(60 000 000). \nGive the last 18 digits of your answer.\n\n"