trackler 2.2.1.130 → 2.2.1.131
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/trackler/version.rb +1 -1
- data/problem-specifications/exercises/crypto-square/description.md +4 -5
- data/problem-specifications/exercises/isbn-verifier/canonical-data.json +9 -1
- data/problem-specifications/exercises/kindergarten-garden/canonical-data.json +1 -4
- data/tracks/csharp/build.ps1 +46 -130
- data/tracks/csharp/build.sh +21 -70
- data/tracks/ecmascript/exercises/simple-cipher/simple-cipher.spec.js +14 -0
- data/tracks/fsharp/build.ps1 +46 -130
- data/tracks/fsharp/build.sh +21 -70
- data/tracks/fsharp/exercises/bank-account/BankAccountTest.fs +13 -12
- data/tracks/fsharp/exercises/bank-account/Example.fs +2 -2
- data/tracks/fsharp/exercises/grade-school/.meta/hints.md +1 -0
- data/tracks/fsharp/exercises/grade-school/GradeSchool.fs +6 -4
- data/tracks/fsharp/exercises/zipper/ZipperTest.fs +79 -26
- data/tracks/fsharp/generators/Common.fs +2 -0
- data/tracks/fsharp/generators/Generators.fs +100 -0
- data/tracks/java/exercises/house/.meta/src/reference/java/House.java +2 -2
- data/tracks/java/exercises/house/.meta/version +1 -1
- data/tracks/java/exercises/house/src/test/java/HouseTest.java +157 -172
- data/tracks/java/exercises/rectangles/.meta/version +1 -1
- data/tracks/java/exercises/rectangles/src/test/java/RectangleCounterTest.java +9 -1
- data/tracks/javascript/exercises/bob/bob.spec.js +1 -1
- data/tracks/javascript/exercises/bob/example.js +3 -0
- data/tracks/javascript/exercises/simple-cipher/simple-cipher.spec.js +14 -0
- data/tracks/julia/config.json +2 -2
- data/tracks/julia/exercises/nucleotide-count/example.jl +1 -1
- data/tracks/julia/exercises/nucleotide-count/runtests.jl +1 -1
- data/tracks/perl5/.travis.yml +1 -4
- data/tracks/perl5/exercises/food-chain/.meta/solutions/FoodChainSong.pm +1 -0
- data/tracks/perl5/exercises/pascals-triangle/.meta/solutions/Triangle.pm +1 -0
- data/tracks/perl5/exercises/pig-latin/.meta/solutions/PigLatin.pm +1 -0
- data/tracks/perl5/exercises/robot-simulator/.meta/solutions/Robot.pm +1 -0
- data/tracks/python/config.json +15 -0
- data/tracks/python/exercises/bowling/bowling_test.py +1 -1
- data/tracks/python/exercises/bracket-push/bracket_push_test.py +4 -1
- data/tracks/python/exercises/isbn-verifier/isbn_verifier_test.py +5 -2
- data/tracks/python/exercises/yacht/README.md +85 -0
- data/tracks/python/exercises/yacht/example.py +65 -0
- data/tracks/python/exercises/yacht/yacht.py +18 -0
- data/tracks/python/exercises/yacht/yacht_test.py +90 -0
- data/tracks/typescript/config.json +25 -0
- data/tracks/typescript/exercises/complex-numbers/README.md +64 -0
- data/tracks/typescript/exercises/complex-numbers/complex-numbers.example.ts +45 -0
- data/tracks/typescript/exercises/complex-numbers/complex-numbers.test.ts +216 -0
- data/tracks/typescript/exercises/complex-numbers/complex-numbers.ts +0 -0
- data/tracks/typescript/exercises/complex-numbers/package.json +36 -0
- data/tracks/typescript/exercises/complex-numbers/tsconfig.json +22 -0
- data/tracks/typescript/exercises/complex-numbers/tslint.json +127 -0
- data/tracks/typescript/exercises/complex-numbers/yarn.lock +2624 -0
- data/tracks/typescript/exercises/minesweeper/README.md +55 -0
- data/tracks/typescript/exercises/minesweeper/minesweeper.example.ts +58 -0
- data/tracks/typescript/exercises/minesweeper/minesweeper.test.ts +173 -0
- data/tracks/typescript/exercises/minesweeper/minesweeper.ts +0 -0
- data/tracks/typescript/exercises/minesweeper/package.json +36 -0
- data/tracks/typescript/exercises/minesweeper/tsconfig.json +22 -0
- data/tracks/typescript/exercises/minesweeper/tslint.json +127 -0
- data/tracks/typescript/exercises/minesweeper/yarn.lock +2624 -0
- data/tracks/typescript/exercises/simple-cipher/simple-cipher.test.ts +14 -0
- metadata +22 -2
@@ -33,7 +33,7 @@ class House {
|
|
33
33
|
verse.append("This is the " + CHARACTERS[verseNumber - 1]);
|
34
34
|
|
35
35
|
for (int i = verseNumber - 2; i >= 0; i--) {
|
36
|
-
verse.append("
|
36
|
+
verse.append(" that " + ACTIONS[i] + " the " + CHARACTERS[i]);
|
37
37
|
}
|
38
38
|
|
39
39
|
return verse.toString();
|
@@ -46,7 +46,7 @@ class House {
|
|
46
46
|
verses[i - startVerse] = verse(i);
|
47
47
|
}
|
48
48
|
|
49
|
-
return String.join("\n
|
49
|
+
return String.join("\n", verses);
|
50
50
|
}
|
51
51
|
|
52
52
|
String sing() {
|
@@ -1 +1 @@
|
|
1
|
-
2.
|
1
|
+
2.2.0
|
@@ -25,7 +25,7 @@ public class HouseTest {
|
|
25
25
|
@Test
|
26
26
|
public void verseTwo() {
|
27
27
|
String expected =
|
28
|
-
"This is the malt
|
28
|
+
"This is the malt " +
|
29
29
|
"that lay in the house that Jack built.";
|
30
30
|
int verse = 2;
|
31
31
|
|
@@ -36,8 +36,8 @@ public class HouseTest {
|
|
36
36
|
@Test
|
37
37
|
public void verseThree() {
|
38
38
|
String expected =
|
39
|
-
"This is the rat
|
40
|
-
"that ate the malt
|
39
|
+
"This is the rat " +
|
40
|
+
"that ate the malt " +
|
41
41
|
"that lay in the house that Jack built.";
|
42
42
|
int verse = 3;
|
43
43
|
|
@@ -48,9 +48,9 @@ public class HouseTest {
|
|
48
48
|
@Test
|
49
49
|
public void verseFour() {
|
50
50
|
String expected =
|
51
|
-
"This is the cat
|
52
|
-
"that killed the rat
|
53
|
-
"that ate the malt
|
51
|
+
"This is the cat " +
|
52
|
+
"that killed the rat " +
|
53
|
+
"that ate the malt " +
|
54
54
|
"that lay in the house that Jack built.";
|
55
55
|
int verse = 4;
|
56
56
|
|
@@ -61,10 +61,10 @@ public class HouseTest {
|
|
61
61
|
@Test
|
62
62
|
public void verseFive() {
|
63
63
|
String expected =
|
64
|
-
"This is the dog
|
65
|
-
"that worried the cat
|
66
|
-
"that killed the rat
|
67
|
-
"that ate the malt
|
64
|
+
"This is the dog " +
|
65
|
+
"that worried the cat " +
|
66
|
+
"that killed the rat " +
|
67
|
+
"that ate the malt " +
|
68
68
|
"that lay in the house that Jack built.";
|
69
69
|
int verse = 5;
|
70
70
|
|
@@ -75,11 +75,11 @@ public class HouseTest {
|
|
75
75
|
@Test
|
76
76
|
public void verseSix() {
|
77
77
|
String expected =
|
78
|
-
"This is the cow with the crumpled horn
|
79
|
-
"that tossed the dog
|
80
|
-
"that worried the cat
|
81
|
-
"that killed the rat
|
82
|
-
"that ate the malt
|
78
|
+
"This is the cow with the crumpled horn " +
|
79
|
+
"that tossed the dog " +
|
80
|
+
"that worried the cat " +
|
81
|
+
"that killed the rat " +
|
82
|
+
"that ate the malt " +
|
83
83
|
"that lay in the house that Jack built.";
|
84
84
|
int verse = 6;
|
85
85
|
|
@@ -90,12 +90,12 @@ public class HouseTest {
|
|
90
90
|
@Test
|
91
91
|
public void verseSeven() {
|
92
92
|
String expected =
|
93
|
-
"This is the maiden all forlorn
|
94
|
-
"that milked the cow with the crumpled horn
|
95
|
-
"that tossed the dog
|
96
|
-
"that worried the cat
|
97
|
-
"that killed the rat
|
98
|
-
"that ate the malt
|
93
|
+
"This is the maiden all forlorn " +
|
94
|
+
"that milked the cow with the crumpled horn " +
|
95
|
+
"that tossed the dog " +
|
96
|
+
"that worried the cat " +
|
97
|
+
"that killed the rat " +
|
98
|
+
"that ate the malt " +
|
99
99
|
"that lay in the house that Jack built.";
|
100
100
|
int verse = 7;
|
101
101
|
|
@@ -106,13 +106,13 @@ public class HouseTest {
|
|
106
106
|
@Test
|
107
107
|
public void verseEight() {
|
108
108
|
String expected =
|
109
|
-
"This is the man all tattered and torn
|
110
|
-
"that kissed the maiden all forlorn
|
111
|
-
"that milked the cow with the crumpled horn
|
112
|
-
"that tossed the dog
|
113
|
-
"that worried the cat
|
114
|
-
"that killed the rat
|
115
|
-
"that ate the malt
|
109
|
+
"This is the man all tattered and torn " +
|
110
|
+
"that kissed the maiden all forlorn " +
|
111
|
+
"that milked the cow with the crumpled horn " +
|
112
|
+
"that tossed the dog " +
|
113
|
+
"that worried the cat " +
|
114
|
+
"that killed the rat " +
|
115
|
+
"that ate the malt " +
|
116
116
|
"that lay in the house that Jack built.";
|
117
117
|
int verse = 8;
|
118
118
|
|
@@ -123,14 +123,14 @@ public class HouseTest {
|
|
123
123
|
@Test
|
124
124
|
public void verseNine() {
|
125
125
|
String expected =
|
126
|
-
"This is the priest all shaven and shorn
|
127
|
-
"that married the man all tattered and torn
|
128
|
-
"that kissed the maiden all forlorn
|
129
|
-
"that milked the cow with the crumpled horn
|
130
|
-
"that tossed the dog
|
131
|
-
"that worried the cat
|
132
|
-
"that killed the rat
|
133
|
-
"that ate the malt
|
126
|
+
"This is the priest all shaven and shorn " +
|
127
|
+
"that married the man all tattered and torn " +
|
128
|
+
"that kissed the maiden all forlorn " +
|
129
|
+
"that milked the cow with the crumpled horn " +
|
130
|
+
"that tossed the dog " +
|
131
|
+
"that worried the cat " +
|
132
|
+
"that killed the rat " +
|
133
|
+
"that ate the malt " +
|
134
134
|
"that lay in the house that Jack built.";
|
135
135
|
int verse = 9;
|
136
136
|
|
@@ -141,15 +141,15 @@ public class HouseTest {
|
|
141
141
|
@Test
|
142
142
|
public void verse10() {
|
143
143
|
String expected =
|
144
|
-
"This is the rooster that crowed in the morn
|
145
|
-
"that woke the priest all shaven and shorn
|
146
|
-
"that married the man all tattered and torn
|
147
|
-
"that kissed the maiden all forlorn
|
148
|
-
"that milked the cow with the crumpled horn
|
149
|
-
"that tossed the dog
|
150
|
-
"that worried the cat
|
151
|
-
"that killed the rat
|
152
|
-
"that ate the malt
|
144
|
+
"This is the rooster that crowed in the morn " +
|
145
|
+
"that woke the priest all shaven and shorn " +
|
146
|
+
"that married the man all tattered and torn " +
|
147
|
+
"that kissed the maiden all forlorn " +
|
148
|
+
"that milked the cow with the crumpled horn " +
|
149
|
+
"that tossed the dog " +
|
150
|
+
"that worried the cat " +
|
151
|
+
"that killed the rat " +
|
152
|
+
"that ate the malt " +
|
153
153
|
"that lay in the house that Jack built.";
|
154
154
|
int verse = 10;
|
155
155
|
|
@@ -160,16 +160,16 @@ public class HouseTest {
|
|
160
160
|
@Test
|
161
161
|
public void verse11() {
|
162
162
|
String expected =
|
163
|
-
"This is the farmer sowing his corn
|
164
|
-
"that kept the rooster that crowed in the morn
|
165
|
-
"that woke the priest all shaven and shorn
|
166
|
-
"that married the man all tattered and torn
|
167
|
-
"that kissed the maiden all forlorn
|
168
|
-
"that milked the cow with the crumpled horn
|
169
|
-
"that tossed the dog
|
170
|
-
"that worried the cat
|
171
|
-
"that killed the rat
|
172
|
-
"that ate the malt
|
163
|
+
"This is the farmer sowing his corn " +
|
164
|
+
"that kept the rooster that crowed in the morn " +
|
165
|
+
"that woke the priest all shaven and shorn " +
|
166
|
+
"that married the man all tattered and torn " +
|
167
|
+
"that kissed the maiden all forlorn " +
|
168
|
+
"that milked the cow with the crumpled horn " +
|
169
|
+
"that tossed the dog " +
|
170
|
+
"that worried the cat " +
|
171
|
+
"that killed the rat " +
|
172
|
+
"that ate the malt " +
|
173
173
|
"that lay in the house that Jack built.";
|
174
174
|
int verse = 11;
|
175
175
|
|
@@ -180,17 +180,17 @@ public class HouseTest {
|
|
180
180
|
@Test
|
181
181
|
public void verse12() {
|
182
182
|
String expected =
|
183
|
-
"This is the horse and the hound and the horn
|
184
|
-
"that belonged to the farmer sowing his corn
|
185
|
-
"that kept the rooster that crowed in the morn
|
186
|
-
"that woke the priest all shaven and shorn
|
187
|
-
"that married the man all tattered and torn
|
188
|
-
"that kissed the maiden all forlorn
|
189
|
-
"that milked the cow with the crumpled horn
|
190
|
-
"that tossed the dog
|
191
|
-
"that worried the cat
|
192
|
-
"that killed the rat
|
193
|
-
"that ate the malt
|
183
|
+
"This is the horse and the hound and the horn " +
|
184
|
+
"that belonged to the farmer sowing his corn " +
|
185
|
+
"that kept the rooster that crowed in the morn " +
|
186
|
+
"that woke the priest all shaven and shorn " +
|
187
|
+
"that married the man all tattered and torn " +
|
188
|
+
"that kissed the maiden all forlorn " +
|
189
|
+
"that milked the cow with the crumpled horn " +
|
190
|
+
"that tossed the dog " +
|
191
|
+
"that worried the cat " +
|
192
|
+
"that killed the rat " +
|
193
|
+
"that ate the malt " +
|
194
194
|
"that lay in the house that Jack built.";
|
195
195
|
int verse = 12;
|
196
196
|
|
@@ -201,39 +201,35 @@ public class HouseTest {
|
|
201
201
|
@Test
|
202
202
|
public void multipleVerses() {
|
203
203
|
String expected =
|
204
|
-
"This is the cat
|
205
|
-
"that killed the rat
|
206
|
-
"that ate the malt
|
204
|
+
"This is the cat " +
|
205
|
+
"that killed the rat " +
|
206
|
+
"that ate the malt " +
|
207
207
|
"that lay in the house that Jack built.\n" +
|
208
|
-
"
|
209
|
-
"
|
210
|
-
"that
|
211
|
-
"that
|
212
|
-
"that ate the malt\n" +
|
208
|
+
"This is the dog " +
|
209
|
+
"that worried the cat " +
|
210
|
+
"that killed the rat " +
|
211
|
+
"that ate the malt " +
|
213
212
|
"that lay in the house that Jack built.\n" +
|
214
|
-
"
|
215
|
-
"
|
216
|
-
"that
|
217
|
-
"that
|
218
|
-
"that
|
219
|
-
"that ate the malt\n" +
|
213
|
+
"This is the cow with the crumpled horn " +
|
214
|
+
"that tossed the dog " +
|
215
|
+
"that worried the cat " +
|
216
|
+
"that killed the rat " +
|
217
|
+
"that ate the malt " +
|
220
218
|
"that lay in the house that Jack built.\n" +
|
221
|
-
"
|
222
|
-
"
|
223
|
-
"that
|
224
|
-
"that
|
225
|
-
"that
|
226
|
-
"that
|
227
|
-
"that ate the malt\n" +
|
219
|
+
"This is the maiden all forlorn " +
|
220
|
+
"that milked the cow with the crumpled horn " +
|
221
|
+
"that tossed the dog " +
|
222
|
+
"that worried the cat " +
|
223
|
+
"that killed the rat " +
|
224
|
+
"that ate the malt " +
|
228
225
|
"that lay in the house that Jack built.\n" +
|
229
|
-
"
|
230
|
-
"
|
231
|
-
"that
|
232
|
-
"that
|
233
|
-
"that
|
234
|
-
"that
|
235
|
-
"that
|
236
|
-
"that ate the malt\n" +
|
226
|
+
"This is the man all tattered and torn " +
|
227
|
+
"that kissed the maiden all forlorn " +
|
228
|
+
"that milked the cow with the crumpled horn " +
|
229
|
+
"that tossed the dog " +
|
230
|
+
"that worried the cat " +
|
231
|
+
"that killed the rat " +
|
232
|
+
"that ate the malt " +
|
237
233
|
"that lay in the house that Jack built.";
|
238
234
|
|
239
235
|
int startVerse = 4;
|
@@ -247,93 +243,82 @@ public class HouseTest {
|
|
247
243
|
public void wholeRhyme() {
|
248
244
|
String expected =
|
249
245
|
"This is the house that Jack built.\n" +
|
250
|
-
"
|
251
|
-
"This is the malt\n" +
|
246
|
+
"This is the malt " +
|
252
247
|
"that lay in the house that Jack built.\n" +
|
253
|
-
"
|
254
|
-
"
|
255
|
-
"that ate the malt\n" +
|
248
|
+
"This is the rat " +
|
249
|
+
"that ate the malt " +
|
256
250
|
"that lay in the house that Jack built.\n" +
|
257
|
-
"
|
258
|
-
"
|
259
|
-
"that
|
260
|
-
"that ate the malt\n" +
|
251
|
+
"This is the cat " +
|
252
|
+
"that killed the rat " +
|
253
|
+
"that ate the malt " +
|
261
254
|
"that lay in the house that Jack built.\n" +
|
262
|
-
"
|
263
|
-
"
|
264
|
-
"that
|
265
|
-
"that
|
266
|
-
"that ate the malt\n" +
|
255
|
+
"This is the dog " +
|
256
|
+
"that worried the cat " +
|
257
|
+
"that killed the rat " +
|
258
|
+
"that ate the malt " +
|
267
259
|
"that lay in the house that Jack built.\n" +
|
268
|
-
"
|
269
|
-
"
|
270
|
-
"that
|
271
|
-
"that
|
272
|
-
"that
|
273
|
-
"that ate the malt\n" +
|
260
|
+
"This is the cow with the crumpled horn " +
|
261
|
+
"that tossed the dog " +
|
262
|
+
"that worried the cat " +
|
263
|
+
"that killed the rat " +
|
264
|
+
"that ate the malt " +
|
274
265
|
"that lay in the house that Jack built.\n" +
|
275
|
-
"
|
276
|
-
"
|
277
|
-
"that
|
278
|
-
"that
|
279
|
-
"that
|
280
|
-
"that
|
281
|
-
"that ate the malt\n" +
|
266
|
+
"This is the maiden all forlorn " +
|
267
|
+
"that milked the cow with the crumpled horn " +
|
268
|
+
"that tossed the dog " +
|
269
|
+
"that worried the cat " +
|
270
|
+
"that killed the rat " +
|
271
|
+
"that ate the malt " +
|
282
272
|
"that lay in the house that Jack built.\n" +
|
283
|
-
"
|
284
|
-
"
|
285
|
-
"that
|
286
|
-
"that
|
287
|
-
"that
|
288
|
-
"that
|
289
|
-
"that
|
290
|
-
"that ate the malt\n" +
|
273
|
+
"This is the man all tattered and torn " +
|
274
|
+
"that kissed the maiden all forlorn " +
|
275
|
+
"that milked the cow with the crumpled horn " +
|
276
|
+
"that tossed the dog " +
|
277
|
+
"that worried the cat " +
|
278
|
+
"that killed the rat " +
|
279
|
+
"that ate the malt " +
|
291
280
|
"that lay in the house that Jack built.\n" +
|
292
|
-
"
|
293
|
-
"
|
294
|
-
"that
|
295
|
-
"that
|
296
|
-
"that
|
297
|
-
"that
|
298
|
-
"that
|
299
|
-
"that
|
300
|
-
"that ate the malt\n" +
|
281
|
+
"This is the priest all shaven and shorn " +
|
282
|
+
"that married the man all tattered and torn " +
|
283
|
+
"that kissed the maiden all forlorn " +
|
284
|
+
"that milked the cow with the crumpled horn " +
|
285
|
+
"that tossed the dog " +
|
286
|
+
"that worried the cat " +
|
287
|
+
"that killed the rat " +
|
288
|
+
"that ate the malt " +
|
301
289
|
"that lay in the house that Jack built.\n" +
|
302
|
-
"
|
303
|
-
"
|
304
|
-
"that
|
305
|
-
"that
|
306
|
-
"that
|
307
|
-
"that
|
308
|
-
"that
|
309
|
-
"that
|
310
|
-
"that
|
311
|
-
"that ate the malt\n" +
|
290
|
+
"This is the rooster that crowed in the morn " +
|
291
|
+
"that woke the priest all shaven and shorn " +
|
292
|
+
"that married the man all tattered and torn " +
|
293
|
+
"that kissed the maiden all forlorn " +
|
294
|
+
"that milked the cow with the crumpled horn " +
|
295
|
+
"that tossed the dog " +
|
296
|
+
"that worried the cat " +
|
297
|
+
"that killed the rat " +
|
298
|
+
"that ate the malt " +
|
312
299
|
"that lay in the house that Jack built.\n" +
|
313
|
-
"
|
314
|
-
"
|
315
|
-
"that
|
316
|
-
"that
|
317
|
-
"that
|
318
|
-
"that
|
319
|
-
"that
|
320
|
-
"that
|
321
|
-
"that
|
322
|
-
"that
|
323
|
-
"that ate the malt\n" +
|
300
|
+
"This is the farmer sowing his corn " +
|
301
|
+
"that kept the rooster that crowed in the morn " +
|
302
|
+
"that woke the priest all shaven and shorn " +
|
303
|
+
"that married the man all tattered and torn " +
|
304
|
+
"that kissed the maiden all forlorn " +
|
305
|
+
"that milked the cow with the crumpled horn " +
|
306
|
+
"that tossed the dog " +
|
307
|
+
"that worried the cat " +
|
308
|
+
"that killed the rat " +
|
309
|
+
"that ate the malt " +
|
324
310
|
"that lay in the house that Jack built.\n" +
|
325
|
-
"
|
326
|
-
"
|
327
|
-
"that
|
328
|
-
"that
|
329
|
-
"that
|
330
|
-
"that
|
331
|
-
"that
|
332
|
-
"that
|
333
|
-
"that
|
334
|
-
"that
|
335
|
-
"that
|
336
|
-
"that ate the malt\n" +
|
311
|
+
"This is the horse and the hound and the horn " +
|
312
|
+
"that belonged to the farmer sowing his corn " +
|
313
|
+
"that kept the rooster that crowed in the morn " +
|
314
|
+
"that woke the priest all shaven and shorn " +
|
315
|
+
"that married the man all tattered and torn " +
|
316
|
+
"that kissed the maiden all forlorn " +
|
317
|
+
"that milked the cow with the crumpled horn " +
|
318
|
+
"that tossed the dog " +
|
319
|
+
"that worried the cat " +
|
320
|
+
"that killed the rat " +
|
321
|
+
"that ate the malt " +
|
337
322
|
"that lay in the house that Jack built.";
|
338
323
|
|
339
324
|
assertEquals(expected, house.sing());
|
@@ -1 +1 @@
|
|
1
|
-
1.
|
1
|
+
1.1.0
|