SHARE
TWEET

Untitled

a guest Dec 19th, 2015 13 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. <?php
  2. // The actual answer
  3. $startyear = 2015;
  4.  
  5. //$answer['Q1'] = "15/12";
  6. $answer['Q2'] = "5/11";
  7. /*$answer['Q3'] = "15/1";
  8. $answer['Q4'] = "3/2";
  9. $answer['Q5'] = "fwestern";
  10. $answer['Q6'] = "990.2";
  11. $answer['Q7'] = "21/12";*/
  12. $answer['Q8'] = "19/12";
  13. /*$answer['Q9'] = "12/2";
  14. $answer['Q10'] = "cooktown";
  15. $answer['Q11'] = "4";
  16. $answer['Q12'] = "-19.2";
  17. $answer['Q13'] = "44.5";
  18. $answer['Q14'] = "13";
  19. $answer['Q15'] = "5";
  20. //$answer['Q16'] = "caleb,debbie";
  21. $answer['Q17'] = "1870";
  22. $answer['Q18'] = "16";
  23. $answer['Q19'] = "weipa";
  24. $answer['Q20'] = "215";*/
  25.  
  26. $locations['cooktown'] = '-15.4667, 145.2833';
  27. $locations['broome'] = '-17.9619, 122.2361';
  28. $locations['cairns'] = '-16.9256, 145.7753';
  29. $locations['darwin'] = '-12.4500, 130.8333';
  30. $locations['gove'] = '-12.2833, 136.8167';
  31. $locations['karratha'] = '-20.7364, 116.8464';
  32. $locations['mackay'] = '-21.1411, 149.1861';
  33. $locations['mornington'] = '-16.5000, 139.5000';
  34. $locations['hedland'] = '-20.3100, 118.6011';
  35. $locations['rockhampton'] = '-23.3750, 150.5117';
  36. $locations['townsville'] = '-19.2564, 146.8183';
  37. $locations['weipa'] = '-12.6167, 141.8667';
  38. $locations['wyndham'] = '-15.4825, 128.1228';
  39.  
  40. // The type of comparison to do on the answer
  41. // Answers with type "key" must have actual answers defined in the $anspoints array, not $answer
  42. // The entry in $answer is used for displaying the correct answer only, and not calculation for "key" types!
  43. $anstype['Q1'] = 'date';
  44. $anstype['Q2'] = 'date';
  45. $anstype['Q3'] = 'date';
  46. $anstype['Q4'] = 'date';
  47. $anstype['Q5'] = 'key';
  48. $anstype['Q6'] = 'number';
  49. $anstype['Q7'] = 'date';
  50. $anstype['Q8'] = 'date';
  51. $anstype['Q9'] = 'date';
  52. $anstype['Q10'] = 'distance';
  53. $anstype['Q11'] = 'key';
  54. $anstype['Q12'] = 'number';
  55. $anstype['Q13'] = 'number';
  56. $anstype['Q14'] = 'number';
  57. $anstype['Q15'] = 'number';
  58. $anstype['Q16'] = 'key';
  59. $anstype['Q17'] = 'number';
  60. $anstype['Q18'] = 'number';
  61. $anstype['Q19'] = 'key';
  62. $anstype['Q20'] = 'number';
  63.  
  64. // Points awarded for each answer [closeness] = points;
  65. $anspoints['Q1']['0'] = '10';
  66. $anspoints['Q1']['2'] = '8';
  67. $anspoints['Q1']['4'] = '7';
  68. $anspoints['Q1']['7'] = '6';
  69. $anspoints['Q1']['10'] = '5';
  70. $anspoints['Q1']['20'] = '4';
  71. $anspoints['Q1']['30'] = '3';
  72. $anspoints['Q1']['40'] = '2';
  73. $anspoints['Q1']['50'] = '1';
  74.  
  75. $anspoints['Q2']['0'] = '10';
  76. $anspoints['Q2']['1'] = '8';
  77. $anspoints['Q2']['2'] = '7';
  78. $anspoints['Q2']['3'] = '6';
  79. $anspoints['Q2']['5'] = '5';
  80. $anspoints['Q2']['7'] = '4';
  81. $anspoints['Q2']['10'] = '3';
  82. $anspoints['Q2']['15'] = '2';
  83. $anspoints['Q2']['20'] = '1';
  84.  
  85. $anspoints['Q3']['0'] = '10';
  86. $anspoints['Q3']['2'] = '8';
  87. $anspoints['Q3']['4'] = '7';
  88. $anspoints['Q3']['7'] = '6';
  89. $anspoints['Q3']['10'] = '5';
  90. $anspoints['Q3']['20'] = '4';
  91. $anspoints['Q3']['30'] = '3';
  92. $anspoints['Q3']['40'] = '2';
  93. $anspoints['Q3']['50'] = '1';
  94.  
  95. $anspoints['Q4']['0'] = '10';
  96. $anspoints['Q4']['1'] = '8';
  97. $anspoints['Q4']['3'] = '7';
  98. $anspoints['Q4']['5'] = '6';
  99. $anspoints['Q4']['10'] = '5';
  100. $anspoints['Q4']['15'] = '4';
  101. $anspoints['Q4']['20'] = '3';
  102. $anspoints['Q4']['30'] = '2';
  103. $anspoints['Q4']['40'] = '1';
  104.  
  105. $anspoints['Q5']['fwestern'] = '5';
  106. $anspoints['Q5']['eastern'] = '2';
  107. $anspoints['Q5']['northern'] = '1';
  108.  
  109. $anspoints['Q6']['5'] = '5';
  110. $anspoints['Q6']['10'] = '4';
  111. $anspoints['Q6']['15'] = '3';
  112. $anspoints['Q6']['20'] = '2';
  113. $anspoints['Q6']['30'] = '1';
  114.  
  115. $anspoints['Q7']['0'] = '10';
  116. $anspoints['Q7']['2'] = '8';
  117. $anspoints['Q7']['4'] = '7';
  118. $anspoints['Q7']['7'] = '6';
  119. $anspoints['Q7']['10'] = '5';
  120. $anspoints['Q7']['20'] = '4';
  121. $anspoints['Q7']['30'] = '3';
  122. $anspoints['Q7']['40'] = '2';
  123. $anspoints['Q7']['50'] = '1';
  124.  
  125. $anspoints['Q8']['0'] = '10';
  126. $anspoints['Q8']['1'] = '8';
  127. $anspoints['Q8']['2'] = '7';
  128. $anspoints['Q8']['3'] = '6';
  129. $anspoints['Q8']['5'] = '5';
  130. $anspoints['Q8']['7'] = '4';
  131. $anspoints['Q8']['10'] = '3';
  132. $anspoints['Q8']['15'] = '2';
  133. $anspoints['Q8']['20'] = '1';
  134.  
  135. $anspoints['Q9']['0'] = '10';
  136. $anspoints['Q9']['1'] = '8';
  137. $anspoints['Q9']['3'] = '7';
  138. $anspoints['Q9']['5'] = '6';
  139. $anspoints['Q9']['7'] = '5';
  140. $anspoints['Q9']['10'] = '4';
  141. $anspoints['Q9']['15'] = '3';
  142. $anspoints['Q9']['20'] = '2';
  143. $anspoints['Q9']['30'] = '1';
  144.  
  145. $anspoints['Q10']['100'] = '10';
  146. $anspoints['Q10']['200'] = '8';
  147. $anspoints['Q10']['300'] = '7';
  148. $anspoints['Q10']['400'] = '6';
  149. $anspoints['Q10']['600'] = '5';
  150. $anspoints['Q10']['800'] = '4';
  151. $anspoints['Q10']['1000'] = '3';
  152. $anspoints['Q10']['1250'] = '2';
  153. $anspoints['Q10']['1500'] = '1';
  154.  
  155. $anspoints['Q11']['5'] = '2';
  156. $anspoints['Q11']['4'] = '5';
  157. $anspoints['Q11']['3'] = '2';
  158.  
  159. $anspoints['Q12']['0.5'] = '10';
  160. $anspoints['Q12']['1.0'] = '8';
  161. $anspoints['Q12']['2.0'] = '7';
  162. $anspoints['Q12']['3.0'] = '6';
  163. $anspoints['Q12']['4.0'] = '5';
  164. $anspoints['Q12']['5.0'] = '4';
  165. $anspoints['Q12']['6.0'] = '3';
  166. $anspoints['Q12']['8.0'] = '2';
  167. $anspoints['Q12']['10.0'] = '1';
  168.  
  169. $anspoints['Q13']['0'] = '10';
  170. $anspoints['Q13']['0.1'] = '8';
  171. $anspoints['Q13']['0.3'] = '7';
  172. $anspoints['Q13']['0.5'] = '6';
  173. $anspoints['Q13']['0.7'] = '5';
  174. $anspoints['Q13']['1.0'] = '4';
  175. $anspoints['Q13']['1.5'] = '3';
  176. $anspoints['Q13']['2.0'] = '2';
  177. $anspoints['Q13']['2.5'] = '1';
  178.  
  179. $anspoints['Q14']['0'] = '10';
  180. $anspoints['Q14']['1'] = '6';
  181. $anspoints['Q14']['2'] = '4';
  182. $anspoints['Q14']['3'] = '2';
  183. $anspoints['Q14']['4'] = '1';
  184.  
  185. $anspoints['Q15']['0'] = '10';
  186. $anspoints['Q15']['1'] = '6';
  187. $anspoints['Q15']['2'] = '4';
  188. $anspoints['Q15']['3'] = '2';
  189. $anspoints['Q15']['4'] = '1';
  190.  
  191. $anspoints['Q16']['stan'] = '0'; // Cat 1
  192. $anspoints['Q16']['tatiana'] = '2'; // Cat 2
  193. $anspoints['Q16']['uriah'] = '2';
  194. $anspoints['Q16']['yvette'] = '4';
  195. $anspoints['Q16']['alfred'] = '0';
  196. $anspoints['Q16']['blanche'] = '4';
  197. $anspoints['Q16']['caleb'] = '5';
  198. $anspoints['Q16']['debbie'] = '5';
  199.  
  200. $anspoints['Q17']['25'] = '10';
  201. $anspoints['Q17']['50'] = '8';
  202. $anspoints['Q17']['100'] = '7';
  203. $anspoints['Q17']['150'] = '6';
  204. $anspoints['Q17']['200'] = '5';
  205. $anspoints['Q17']['300'] = '4';
  206. $anspoints['Q17']['400'] = '3';
  207. $anspoints['Q17']['500'] = '2';
  208. $anspoints['Q17']['600'] = '1';
  209.  
  210. $anspoints['Q18']['0'] = '10';
  211. $anspoints['Q18']['1'] = '8';
  212. $anspoints['Q18']['2'] = '7';
  213. $anspoints['Q18']['3'] = '6';
  214. $anspoints['Q18']['4'] = '5';
  215. $anspoints['Q18']['6'] = '4';
  216. $anspoints['Q18']['8'] = '3';
  217. $anspoints['Q18']['10'] = '2';
  218. $anspoints['Q18']['15'] = '1';
  219.  
  220. $anspoints['Q19']['weipa'] = '10';
  221. $anspoints['Q19']['cairns'] = '6';
  222. $anspoints['Q19']['gove'] = '4';
  223. $anspoints['Q19']['broome'] = '2';
  224. $anspoints['Q19']['rockhampton'] = '1';
  225.  
  226. $anspoints['Q20']['5'] = '10';
  227. $anspoints['Q20']['10'] = '8';
  228. $anspoints['Q20']['20'] = '7';
  229. $anspoints['Q20']['30'] = '6';
  230. $anspoints['Q20']['40'] = '5';
  231. $anspoints['Q20']['50'] = '4';
  232. $anspoints['Q20']['75'] = '3';
  233. $anspoints['Q20']['100'] = '2';
  234. $anspoints['Q20']['150'] = '1';
  235.  
  236.  
  237. ?>
RAW Paste Data
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy. OK, I Understand
 
Top