akaaafk commited on
Commit
27fa60a
·
verified ·
1 Parent(s): 64036e1

Add files using upload-large-folder tool

Browse files
Files changed (20) hide show
  1. benchmark/IOAI/IOAI-2025/Individual-Contest/Restroom/training_set/crop/female/44.png +3 -0
  2. benchmark/IOAI/IOAI-2025/Individual-Contest/Restroom/training_set/crop/female/45.png +3 -0
  3. benchmark/IOAI/IOAI-2025/Individual-Contest/Restroom/training_set/crop/female/46.png +3 -0
  4. benchmark/IOAI/IOAI-2025/Individual-Contest/Restroom/training_set/crop/female/47.png +3 -0
  5. benchmark/IOAI/IOAI-2025/Individual-Contest/Restroom/training_set/crop/female/48.png +3 -0
  6. benchmark/IOAI/IOAI-2025/Individual-Contest/Restroom/training_set/orig/female/59.png +3 -0
  7. benchmark/IOAI/IOAI-2025/Individual-Contest/Restroom/training_set/orig/female/6.png +3 -0
  8. benchmark/IOAI/IOAI-2025/Individual-Contest/Restroom/training_set/orig/female/60.png +3 -0
  9. benchmark/IOAI/IOAI-2025/Individual-Contest/Restroom/training_set/orig/female/63.png +3 -0
  10. benchmark/IOAI/IOAI-2025/Individual-Contest/Restroom/training_set/orig/female/64.png +3 -0
  11. benchmark/IOAI/IOAI-2025/Individual-Contest/Restroom/training_set/orig/female/65.png +3 -0
  12. benchmark/IOAI/IOAI-2025/Individual-Contest/Restroom/training_set/orig/female/66.png +3 -0
  13. benchmark/IOAI/IOAI-2025/Individual-Contest/Restroom/training_set/orig/female/67.png +3 -0
  14. benchmark/IOAI/IOAI-2025/Individual-Contest/Restroom/training_set/orig/female/68.png +3 -0
  15. benchmark/IOAI/IOAI-2025/Individual-Contest/Restroom/training_set/orig/female/69.png +3 -0
  16. benchmark/IOAI/IOAI-2025/Individual-Contest/Restroom/training_set/orig/female/7.png +3 -0
  17. benchmark/MIT_Mystery_Hunt/puzzles/by_tsv/1999/1999_puzzles_4Detective_SanFrancisco_san_francisco.html/san_francisco.html +21 -0
  18. benchmark/MIT_Mystery_Hunt/puzzles/by_tsv/1999/1999_puzzles_4Detective_SanFrancisco_san_francisco.html/solution.html +11 -0
  19. benchmark/MIT_Mystery_Hunt/puzzles/by_tsv/1999/1999_puzzles_4Detective_SanFrancisco_san_francisco.html/solvinggrid.pdf +0 -0
  20. benchmark/MIT_Mystery_Hunt/puzzles/by_tsv/1999/1999_puzzles_4Detective_Santiago_santiago.html/checkanswer.js +281 -0
benchmark/IOAI/IOAI-2025/Individual-Contest/Restroom/training_set/crop/female/44.png ADDED

Git LFS Details

  • SHA256: 70385eb5a59da4548191eff02fb8c9054f9e7a6fdc8dffa2bb9ff5074dae8243
  • Pointer size: 130 Bytes
  • Size of remote file: 56.4 kB
benchmark/IOAI/IOAI-2025/Individual-Contest/Restroom/training_set/crop/female/45.png ADDED

Git LFS Details

  • SHA256: 258b2c94612241fcf1875cf23ab0596aeb99de2f94dcaaad6b8057a85524a7c8
  • Pointer size: 130 Bytes
  • Size of remote file: 76.1 kB
benchmark/IOAI/IOAI-2025/Individual-Contest/Restroom/training_set/crop/female/46.png ADDED

Git LFS Details

  • SHA256: f7424d8e45f11172a2c721fe7f265ec04b9f93383effabd11e24a29ba2d77e36
  • Pointer size: 130 Bytes
  • Size of remote file: 17 kB
benchmark/IOAI/IOAI-2025/Individual-Contest/Restroom/training_set/crop/female/47.png ADDED

Git LFS Details

  • SHA256: 032bb913f9b2f06b333c9bf14a075a9c230524bd00be507165bd64d757b8f4c4
  • Pointer size: 130 Bytes
  • Size of remote file: 14.3 kB
benchmark/IOAI/IOAI-2025/Individual-Contest/Restroom/training_set/crop/female/48.png ADDED

Git LFS Details

  • SHA256: d05b9fe613b810685c681d4d8862bba5d8500b3d0ae15abb7ace584e04701988
  • Pointer size: 130 Bytes
  • Size of remote file: 17 kB
benchmark/IOAI/IOAI-2025/Individual-Contest/Restroom/training_set/orig/female/59.png ADDED

Git LFS Details

  • SHA256: 3c63682a78dd71f1effe26e4d352671d98661f700e0be21e6db7f8626671f16f
  • Pointer size: 131 Bytes
  • Size of remote file: 168 kB
benchmark/IOAI/IOAI-2025/Individual-Contest/Restroom/training_set/orig/female/6.png ADDED

Git LFS Details

  • SHA256: 4d8721367fabe828373fc11810cde409656fba432e986ace2bfa8625304f596b
  • Pointer size: 130 Bytes
  • Size of remote file: 12.1 kB
benchmark/IOAI/IOAI-2025/Individual-Contest/Restroom/training_set/orig/female/60.png ADDED

Git LFS Details

  • SHA256: ed75e4edd326ac6bff01bcf806701d45ab70d484936b91aaf92eccff55b02b52
  • Pointer size: 130 Bytes
  • Size of remote file: 41.6 kB
benchmark/IOAI/IOAI-2025/Individual-Contest/Restroom/training_set/orig/female/63.png ADDED

Git LFS Details

  • SHA256: 809c9fa609c9635bf1cbbeb8ee18c086d73ba8d2d974eb07472fbc04c2013967
  • Pointer size: 130 Bytes
  • Size of remote file: 80.8 kB
benchmark/IOAI/IOAI-2025/Individual-Contest/Restroom/training_set/orig/female/64.png ADDED

Git LFS Details

  • SHA256: fc89fc89b975f37bd403e54d38f6ab782bb867770ba83e9f0bd02b9c0c69424c
  • Pointer size: 131 Bytes
  • Size of remote file: 115 kB
benchmark/IOAI/IOAI-2025/Individual-Contest/Restroom/training_set/orig/female/65.png ADDED

Git LFS Details

  • SHA256: 66b7a23d5fa7ba9fe809c401d84874acc4c94db72b03b9bf9f3ea3606ce0bdcc
  • Pointer size: 130 Bytes
  • Size of remote file: 66.5 kB
benchmark/IOAI/IOAI-2025/Individual-Contest/Restroom/training_set/orig/female/66.png ADDED

Git LFS Details

  • SHA256: f991fdb70861145edc85ebcdd5b7e2c7fb4e5479cc72a21d3f9bb3223be0d122
  • Pointer size: 131 Bytes
  • Size of remote file: 142 kB
benchmark/IOAI/IOAI-2025/Individual-Contest/Restroom/training_set/orig/female/67.png ADDED

Git LFS Details

  • SHA256: 6a8aea145b963c56ab51cbfe377a630deac05c6b4f45303227ce66d4e75a6012
  • Pointer size: 131 Bytes
  • Size of remote file: 143 kB
benchmark/IOAI/IOAI-2025/Individual-Contest/Restroom/training_set/orig/female/68.png ADDED

Git LFS Details

  • SHA256: 36b6612d0917c3acf93bb9033b10ae983049d4a00252d0d89cf9aada925a94af
  • Pointer size: 131 Bytes
  • Size of remote file: 111 kB
benchmark/IOAI/IOAI-2025/Individual-Contest/Restroom/training_set/orig/female/69.png ADDED

Git LFS Details

  • SHA256: 0b224a890b1fc01bb172c16d738e94a71a94e3b36e184962c3119dc7b7081baa
  • Pointer size: 131 Bytes
  • Size of remote file: 144 kB
benchmark/IOAI/IOAI-2025/Individual-Contest/Restroom/training_set/orig/female/7.png ADDED

Git LFS Details

  • SHA256: 9fba4e68242291e5d68a4e2cf014dbad11c052026c17f491940c8a06b0539f62
  • Pointer size: 129 Bytes
  • Size of remote file: 5.39 kB
benchmark/MIT_Mystery_Hunt/puzzles/by_tsv/1999/1999_puzzles_4Detective_SanFrancisco_san_francisco.html/san_francisco.html ADDED
@@ -0,0 +1,21 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <html>
2
+ <head>
3
+ <title>San Francisco</title>
4
+ </head>
5
+ <body>
6
+
7
+ <h1>San Francisco</h1>
8
+
9
+ <p>
10
+ Please send two people only to our offices to witness a crime. Later you will be given a lineup and asked to pick the crooks out of it.
11
+ When you do the calculations for the puzzle eventually, it will be important to remember to include the space.
12
+ </p>
13
+
14
+
15
+ <p><em><strong>Archivist's Note</strong></em>: One of the solving teams had <a href="solvinggrid.pdf">this grid</a> to solve this puzzle. It
16
+ is not known whether they made this grid themselves, or if it was given out by the writing team.
17
+ </p>
18
+
19
+ <p><a href="solution.html">Solution</a></p>
20
+ </body><script type="module" src="/checkanswer.js"></script>
21
+ </html>
benchmark/MIT_Mystery_Hunt/puzzles/by_tsv/1999/1999_puzzles_4Detective_SanFrancisco_san_francisco.html/solution.html ADDED
@@ -0,0 +1,11 @@
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <html>
2
+ <head>
3
+ <title>San Francisco: Solution</title>
4
+ </head>
5
+ <body>
6
+ <h1>San Francisco: Solution</h1>
7
+ <p>
8
+ Solution needed. The answer is <strong>MODUS OPERANDI</strong>.
9
+ </p>
10
+ </body>
11
+ </html>
benchmark/MIT_Mystery_Hunt/puzzles/by_tsv/1999/1999_puzzles_4Detective_SanFrancisco_san_francisco.html/solvinggrid.pdf ADDED
Binary file (43.8 kB). View file
 
benchmark/MIT_Mystery_Hunt/puzzles/by_tsv/1999/1999_puzzles_4Detective_Santiago_santiago.html/checkanswer.js ADDED
@@ -0,0 +1,281 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ // Do this first so that layout shift isn't too bad:
2
+ const container = document.createElement("div");
3
+ container.style = `
4
+ font-size: 16px;
5
+ font-size: clamp(16px, 2.4vw, 21px);
6
+ height: 2.5em;
7
+ `;
8
+ document.body.prepend(container);
9
+
10
+ import { React, html, css, render } from "./package.js";
11
+
12
+ /**
13
+ * Remove non-alphanumeric characters.
14
+ */
15
+ const normalizeAnswer = (answer) => {
16
+ if (getYear() === 2003) {
17
+ if (document.URL.includes("teamGuest/2")) {
18
+ // Special case: 2003 R2, whose answers are emoji.
19
+ return answer.trim();
20
+ } else if (document.URL.includes("6_3")) {
21
+ // Special case: Answer is literal Greek letter.
22
+ return answer.trim();
23
+ }
24
+ }
25
+ return answer.toUpperCase().replaceAll(/[^A-Z0-9]/g, "");
26
+ };
27
+
28
+ /**
29
+ * Returns the year of the hunt we're in.
30
+ */
31
+ const getYear = () => {
32
+ return Number(RegExp(`^.*/([0-9]{4})/.*$`).exec(document.URL)?.[1] ?? 0);
33
+ };
34
+
35
+ /**
36
+ * Fetches the answers as a list of {url, answer, prompt, intermediate}.
37
+ */
38
+ const getData = async () => {
39
+ const res = await fetch("/answers.tsv");
40
+ const data = await res.text();
41
+ const [header, ...body] = data.split("\n");
42
+ const headers = header.trim().split("\t");
43
+ return body.map((row) => {
44
+ const res = {};
45
+ row.split("\t").forEach((item, i) => {
46
+ res[headers[i]] = item.trim();
47
+ });
48
+ return res;
49
+ });
50
+ };
51
+
52
+ /**
53
+ * Gets the base URL; removes trailing index.html and .html, removes everything
54
+ * before the year, and then removes trailing slash.
55
+ */
56
+ const getBase = (url) => {
57
+ const root =
58
+ RegExp(`^(.*/)index.html`).exec(url)?.[1] ??
59
+ RegExp(`^(.*).html`).exec(url)?.[1] ??
60
+ url;
61
+ const base = RegExp(`^.*/([0-9]{4}/.*)$`).exec(root)?.[1] ?? root;
62
+ return base.endsWith("/") ? base.slice(0, -1) : base;
63
+ };
64
+
65
+ /**
66
+ * Get all rows in the data corresponding to a given URL. Group by same prompt.
67
+ */
68
+ const getAnswers = (data, url) => {
69
+ const base = getBase(url);
70
+ const rows = data.filter((row) => getBase(row.url) === base);
71
+ const prompts = [];
72
+ for (const row of rows) {
73
+ const { prompt } = row;
74
+ const group = prompts.find((group) => group.prompt === prompt);
75
+ if (group) {
76
+ group.rows.push(row);
77
+ } else {
78
+ prompts.push({ prompt, rows: [row] });
79
+ }
80
+ }
81
+ return prompts;
82
+ };
83
+
84
+ /**
85
+ * A single textbox and submit button in the rows of possible responses.
86
+ */
87
+ const ResponseRow = ({ prompt, rows, setFeedback }) => {
88
+ const [response, setResponse] = React.useState("");
89
+
90
+ const form = css`
91
+ align-items: baseline;
92
+ display: flex;
93
+ justify-content: right;
94
+ margin-bottom: 0.5em;
95
+
96
+ @media (max-width: 600px) {
97
+ align-items: flex-start;
98
+ flex-direction: column;
99
+ }
100
+ `;
101
+
102
+ const input = css`
103
+ background: #fafafa;
104
+ border: 1px solid #aaa;
105
+ border-radius: 2px;
106
+ color: #121212;
107
+ font-family: inherit;
108
+ font-size: 100%;
109
+ line-height: 1.2;
110
+ margin: 0 0.5em;
111
+ padding: 0.25em 0.5em;
112
+
113
+ @media (max-width: 600px) {
114
+ margin: 0 0 0.25em;
115
+ }
116
+ `;
117
+
118
+ const onSubmit = (e) => {
119
+ e.preventDefault();
120
+ let set = false;
121
+ for (const row of rows) {
122
+ const correct = normalizeAnswer(row.answer) === normalizeAnswer(response);
123
+ if (correct) {
124
+ setFeedback(
125
+ row.intermediate?.trim() === "TRUE"
126
+ ? "Correct! See the solution page for the answer."
127
+ : `Solved! The answer was ${row.answer}.`
128
+ );
129
+ set = true;
130
+ break;
131
+ }
132
+ }
133
+ if (!set) {
134
+ setFeedback("Incorrect.");
135
+ }
136
+ };
137
+
138
+ const onChange = (e) => setResponse(e.target.value);
139
+
140
+ return html`
141
+ <form class=${form} onSubmit=${onSubmit}>
142
+ <label htmlFor=${prompt + " prompt"}>
143
+ ${prompt || "Enter your guess"}:
144
+ </label>
145
+ <input
146
+ class=${input}
147
+ id=${prompt + " prompt"}
148
+ onChange=${onChange}
149
+ required
150
+ type="text"
151
+ value=${response}
152
+ />
153
+ <button type="submit">Submit</button>
154
+ </form>
155
+ `;
156
+ };
157
+
158
+ /**
159
+ * Check answer button, rendered at top of page.
160
+ */
161
+ const CheckButton = ({ prompts }) => {
162
+ const [open, setOpen] = React.useState(false);
163
+ const [feedback, setFeedback] = React.useState("Call in an answer.");
164
+
165
+ const wrapper = css`
166
+ font-family: "PT Sans", sans-serif;
167
+ font-size: 16px;
168
+ font-size: clamp(16px, 2.4vw, 21px);
169
+ height: 2.5em;
170
+
171
+ button {
172
+ background: #555;
173
+ border: none;
174
+ border-radius: 2px;
175
+ color: #fff;
176
+ cursor: pointer;
177
+ display: inline-block;
178
+ font-size: 1em;
179
+ font-family: "PT Sans", sans-serif;
180
+ font-weight: bold;
181
+ line-height: 1.2;
182
+ padding: 0.25em 1em;
183
+ text-align: center;
184
+ text-decoration: none;
185
+ text-transform: none;
186
+ }
187
+
188
+ p {
189
+ margin: 0 0 1em;
190
+ }
191
+
192
+ a {
193
+ color: inherit !important;
194
+ }
195
+ `;
196
+
197
+ const btnTop = [2015, 2016].includes(getYear())
198
+ ? "50px"
199
+ : [2012].includes(getYear())
200
+ ? "-2.5em"
201
+ : "0px";
202
+
203
+ const button = css`
204
+ box-sizing: border-box;
205
+ height: 2.5em;
206
+ left: 0;
207
+ position: absolute;
208
+ top: ${btnTop};
209
+ width: 100%;
210
+ z-index: 9999;
211
+ `;
212
+
213
+ const dropdownWrapper = css`
214
+ background: #edeff0;
215
+ color: #121212;
216
+ left: 0;
217
+ position: absolute;
218
+ right: 0;
219
+ top: calc(2.5em + ${btnTop});
220
+ z-index: 9999;
221
+ `;
222
+
223
+ const dropdown = css`
224
+ margin: 0 auto;
225
+ max-width: 40em;
226
+ padding: 1em;
227
+ z-index: 9999;
228
+ `;
229
+
230
+ const responses = css`
231
+ margin: 0 auto;
232
+ width: fit-content;
233
+
234
+ @media (max-width: 600px) {
235
+ width: auto;
236
+ }
237
+ `;
238
+
239
+ const onClick = () => setOpen(!open);
240
+
241
+ const body =
242
+ prompts.length > 0
243
+ ? prompts.map(
244
+ (group) =>
245
+ html`<${ResponseRow} setFeedback=${setFeedback} ...${group} />`
246
+ )
247
+ : html`<p>
248
+ No answers found on this page. Please report this to${" "}
249
+ <a href="mailto:puzzle@mit.edu">puzzle@mit.edu</a>.
250
+ </p>`;
251
+
252
+ return html`
253
+ <style>
254
+ @import url("https://fonts.googleapis.com/css2?family=PT+Sans:wght@400;700&display=swap");
255
+
256
+ ${[2015, 2016].includes(getYear()) &&
257
+ ".navbar-fixed-top { z-index: 10000 }"}
258
+ ${[2012].includes(getYear()) &&
259
+ "body { top: 2.5em } #check-answer, #shortcuts { z-index: 10000 !important }"}
260
+ ${[2006].includes(getYear()) && 'img[alt="Check Answer"] { display: none }'}
261
+ </style>
262
+ <div class=${wrapper}>
263
+ <button class=${button} onClick=${onClick}>
264
+ Check your answers spoiler-free
265
+ </button>
266
+ ${open &&
267
+ html`
268
+ <div class=${dropdownWrapper}>
269
+ <div class=${dropdown}>
270
+ <p>${feedback}</p>
271
+ <div class=${responses}>${body}</div>
272
+ </div>
273
+ </div>
274
+ `}
275
+ </div>
276
+ `;
277
+ };
278
+
279
+ const data = await getData();
280
+ const prompts = getAnswers(data, document.URL);
281
+ render(html`<${CheckButton} prompts=${prompts} />`, container);