From 32cfed5f627aeb62e430ed04014eb1c0eda149d0 Mon Sep 17 00:00:00 2001 From: Peter Tseng Date: Thu, 17 Feb 2022 05:14:34 +0000 Subject: [PATCH 1/3] allow prettier to format more files It's my opinion that for these 20 files, we should not have a strong opinion on the formatting, and therefore should just accept what prettier gives us. This leaves only 13 files ignored. That leaves much less manual work needed. --- .prettierignore | 20 -- exercises/allergies/canonical-data.json | 26 +- exercises/book-store/canonical-data.json | 4 +- exercises/bowling/canonical-data.json | 92 +++++-- exercises/change/canonical-data.json | 4 +- exercises/dominoes/canonical-data.json | 66 ++++- exercises/grep/canonical-data.json | 42 +-- exercises/house/canonical-data.json | 8 +- .../kindergarten-garden/canonical-data.json | 119 ++------- exercises/knapsack/canonical-data.json | 8 +- exercises/markdown/canonical-data.json | 4 +- .../pascals-triangle/canonical-data.json | 22 +- exercises/poker/canonical-data.json | 250 ++++-------------- exercises/pov/canonical-data.json | 31 +-- .../pythagorean-triplet/canonical-data.json | 12 +- exercises/reverse-string/canonical-data.json | 4 +- exercises/roman-numerals/canonical-data.json | 4 +- .../rotational-cipher/canonical-data.json | 4 +- exercises/spiral-matrix/canonical-data.json | 6 +- exercises/tournament/canonical-data.json | 20 +- .../canonical-data.json | 8 +- 21 files changed, 275 insertions(+), 479 deletions(-) diff --git a/.prettierignore b/.prettierignore index b99e33a1c9..89cd6792e8 100644 --- a/.prettierignore +++ b/.prettierignore @@ -1,33 +1,13 @@ -exercises/allergies/canonical-data.json -exercises/book-store/canonical-data.json -exercises/bowling/canonical-data.json -exercises/change/canonical-data.json exercises/connect/canonical-data.json exercises/diamond/canonical-data.json -exercises/dominoes/canonical-data.json exercises/flatten-array/canonical-data.json exercises/forth/canonical-data.json exercises/go-counting/canonical-data.json -exercises/grep/canonical-data.json -exercises/house/canonical-data.json -exercises/kindergarten-garden/canonical-data.json -exercises/knapsack/canonical-data.json -exercises/markdown/canonical-data.json exercises/minesweeper/canonical-data.json exercises/ocr-numbers/canonical-data.json -exercises/pascals-triangle/canonical-data.json -exercises/poker/canonical-data.json -exercises/pov/canonical-data.json -exercises/pythagorean-triplet/canonical-data.json exercises/rectangles/canonical-data.json -exercises/reverse-string/canonical-data.json -exercises/roman-numerals/canonical-data.json -exercises/rotational-cipher/canonical-data.json exercises/saddle-points/canonical-data.json exercises/scale-generator/canonical-data.json exercises/sieve/canonical-data.json -exercises/spiral-matrix/canonical-data.json -exercises/tournament/canonical-data.json exercises/transpose/canonical-data.json -exercises/variable-length-quantity/canonical-data.json exercises/word-search/canonical-data.json diff --git a/exercises/allergies/canonical-data.json b/exercises/allergies/canonical-data.json index 86d2fea765..60353d0237 100644 --- a/exercises/allergies/canonical-data.json +++ b/exercises/allergies/canonical-data.json @@ -447,9 +447,7 @@ }, { "description": "list when:", - "comments": [ - "Given a number, list all things Tom is allergic to" - ], + "comments": ["Given a number, list all things Tom is allergic to"], "cases": [ { "uuid": "f9c1b8e7-7dc5-4887-aa93-cebdcc29dd8f", @@ -467,9 +465,7 @@ "input": { "score": 1 }, - "expected": [ - "eggs" - ] + "expected": ["eggs"] }, { "uuid": "8851c973-805e-4283-9e01-d0c0da0e4695", @@ -478,9 +474,7 @@ "input": { "score": 2 }, - "expected": [ - "peanuts" - ] + "expected": ["peanuts"] }, { "uuid": "2c8943cb-005e-435f-ae11-3e8fb558ea98", @@ -489,9 +483,7 @@ "input": { "score": 8 }, - "expected": [ - "strawberries" - ] + "expected": ["strawberries"] }, { "uuid": "6fa95d26-044c-48a9-8a7b-9ee46ec32c5c", @@ -500,10 +492,7 @@ "input": { "score": 3 }, - "expected": [ - "eggs", - "peanuts" - ] + "expected": ["eggs", "peanuts"] }, { "uuid": "19890e22-f63f-4c5c-a9fb-fb6eacddfe8e", @@ -512,10 +501,7 @@ "input": { "score": 5 }, - "expected": [ - "eggs", - "shellfish" - ] + "expected": ["eggs", "shellfish"] }, { "uuid": "4b68f470-067c-44e4-889f-c9fe28917d2f", diff --git a/exercises/book-store/canonical-data.json b/exercises/book-store/canonical-data.json index 17211d602c..82e33aa87a 100644 --- a/exercises/book-store/canonical-data.json +++ b/exercises/book-store/canonical-data.json @@ -171,7 +171,9 @@ ], "property": "total", "input": { - "basket": [1, 1, 1, 1, 1, 1, 2, 2, 2, 2, 2, 2, 3, 3, 3, 3, 3, 3, 4, 4, 5, 5] + "basket": [ + 1, 1, 1, 1, 1, 1, 2, 2, 2, 2, 2, 2, 3, 3, 3, 3, 3, 3, 4, 4, 5, 5 + ] }, "expected": 14560 }, diff --git a/exercises/bowling/canonical-data.json b/exercises/bowling/canonical-data.json index c8e8d13150..b2ff54dd18 100644 --- a/exercises/bowling/canonical-data.json +++ b/exercises/bowling/canonical-data.json @@ -25,7 +25,9 @@ "description": "should be able to score a game with all zeros", "property": "score", "input": { - "previousRolls": [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0] + "previousRolls": [ + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 + ] }, "expected": 0 }, @@ -34,7 +36,9 @@ "description": "should be able to score a game with no strikes or spares", "property": "score", "input": { - "previousRolls": [3, 6, 3, 6, 3, 6, 3, 6, 3, 6, 3, 6, 3, 6, 3, 6, 3, 6, 3, 6] + "previousRolls": [ + 3, 6, 3, 6, 3, 6, 3, 6, 3, 6, 3, 6, 3, 6, 3, 6, 3, 6, 3, 6 + ] }, "expected": 90 }, @@ -43,7 +47,9 @@ "description": "a spare followed by zeros is worth ten points", "property": "score", "input": { - "previousRolls": [6, 4, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0] + "previousRolls": [ + 6, 4, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 + ] }, "expected": 10 }, @@ -52,7 +58,9 @@ "description": "points scored in the roll after a spare are counted twice", "property": "score", "input": { - "previousRolls": [6, 4, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0] + "previousRolls": [ + 6, 4, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 + ] }, "expected": 16 }, @@ -61,7 +69,9 @@ "description": "consecutive spares each get a one roll bonus", "property": "score", "input": { - "previousRolls": [5, 5, 3, 7, 4, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0] + "previousRolls": [ + 5, 5, 3, 7, 4, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 + ] }, "expected": 31 }, @@ -70,7 +80,9 @@ "description": "a spare in the last frame gets a one roll bonus that is counted once", "property": "score", "input": { - "previousRolls": [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 7, 3, 7] + "previousRolls": [ + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 7, 3, 7 + ] }, "expected": 17 }, @@ -79,7 +91,9 @@ "description": "a strike earns ten points in a frame with a single roll", "property": "score", "input": { - "previousRolls": [10, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0] + "previousRolls": [ + 10, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 + ] }, "expected": 10 }, @@ -88,7 +102,9 @@ "description": "points scored in the two rolls after a strike are counted twice as a bonus", "property": "score", "input": { - "previousRolls": [10, 5, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0] + "previousRolls": [ + 10, 5, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 + ] }, "expected": 26 }, @@ -106,7 +122,9 @@ "description": "a strike in the last frame gets a two roll bonus that is counted once", "property": "score", "input": { - "previousRolls": [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 7, 1] + "previousRolls": [ + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 7, 1 + ] }, "expected": 18 }, @@ -115,7 +133,9 @@ "description": "rolling a spare with the two roll bonus does not get a bonus roll", "property": "score", "input": { - "previousRolls": [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 7, 3] + "previousRolls": [ + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 7, 3 + ] }, "expected": 20 }, @@ -124,7 +144,9 @@ "description": "strikes with the two roll bonus do not get bonus rolls", "property": "score", "input": { - "previousRolls": [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 10, 10] + "previousRolls": [ + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 10, 10 + ] }, "expected": 30 }, @@ -144,7 +166,9 @@ "description": "a strike with the one roll bonus after a spare in the last frame does not get a bonus", "property": "score", "input": { - "previousRolls": [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 7, 3, 10] + "previousRolls": [ + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 7, 3, 10 + ] }, "expected": 20 }, @@ -198,7 +222,9 @@ "description": "bonus roll after a strike in the last frame cannot score more than 10 points", "property": "roll", "input": { - "previousRolls": [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10], + "previousRolls": [ + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10 + ], "roll": 11 }, "expected": { @@ -210,7 +236,9 @@ "description": "two bonus rolls after a strike in the last frame cannot score more than 10 points", "property": "roll", "input": { - "previousRolls": [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 5], + "previousRolls": [ + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 5 + ], "roll": 6 }, "expected": { @@ -222,7 +250,9 @@ "description": "two bonus rolls after a strike in the last frame can score more than 10 points if one is a strike", "property": "score", "input": { - "previousRolls": [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 10, 6] + "previousRolls": [ + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 10, 6 + ] }, "expected": 26 }, @@ -231,7 +261,9 @@ "description": "the second bonus rolls after a strike in the last frame cannot be a strike if the first one is not a strike", "property": "roll", "input": { - "previousRolls": [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 6], + "previousRolls": [ + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 6 + ], "roll": 10 }, "expected": { @@ -243,7 +275,9 @@ "description": "second bonus roll after a strike in the last frame cannot score more than 10 points", "property": "roll", "input": { - "previousRolls": [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 10], + "previousRolls": [ + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 10 + ], "roll": 11 }, "expected": { @@ -277,7 +311,9 @@ "description": "cannot roll if game already has ten frames", "property": "roll", "input": { - "previousRolls": [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], + "previousRolls": [ + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 + ], "roll": 0 }, "expected": { @@ -289,7 +325,9 @@ "description": "bonus rolls for a strike in the last frame must be rolled before score can be calculated", "property": "score", "input": { - "previousRolls": [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10] + "previousRolls": [ + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10 + ] }, "expected": { "error": "Score cannot be taken until the end of the game" @@ -300,7 +338,9 @@ "description": "both bonus rolls for a strike in the last frame must be rolled before score can be calculated", "property": "score", "input": { - "previousRolls": [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 10] + "previousRolls": [ + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 10 + ] }, "expected": { "error": "Score cannot be taken until the end of the game" @@ -311,7 +351,9 @@ "description": "bonus roll for a spare in the last frame must be rolled before score can be calculated", "property": "score", "input": { - "previousRolls": [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 7, 3] + "previousRolls": [ + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 7, 3 + ] }, "expected": { "error": "Score cannot be taken until the end of the game" @@ -322,7 +364,9 @@ "description": "cannot roll after bonus roll for spare", "property": "roll", "input": { - "previousRolls": [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 7, 3, 2], + "previousRolls": [ + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 7, 3, 2 + ], "roll": 2 }, "expected": { @@ -334,7 +378,9 @@ "description": "cannot roll after bonus rolls for strike", "property": "roll", "input": { - "previousRolls": [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 3, 2], + "previousRolls": [ + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 3, 2 + ], "roll": 2 }, "expected": { diff --git a/exercises/change/canonical-data.json b/exercises/change/canonical-data.json index 291d82ce93..b5f2db3eae 100644 --- a/exercises/change/canonical-data.json +++ b/exercises/change/canonical-data.json @@ -64,7 +64,9 @@ "coins": [1, 2, 5, 10, 20, 50, 100], "target": 999 }, - "expected": [2, 2, 5, 20, 20, 50, 100, 100, 100, 100, 100, 100, 100, 100, 100] + "expected": [ + 2, 2, 5, 20, 20, 50, 100, 100, 100, 100, 100, 100, 100, 100, 100 + ] }, { "uuid": "f79d2e9b-0ae3-4d6a-bb58-dc978b0dba28", diff --git a/exercises/dominoes/canonical-data.json b/exercises/dominoes/canonical-data.json index 3b9b74d70e..620f7c818c 100644 --- a/exercises/dominoes/canonical-data.json +++ b/exercises/dominoes/canonical-data.json @@ -68,7 +68,11 @@ "description": "three elements", "property": "canChain", "input": { - "dominoes": [[1, 2], [3, 1], [2, 3]] + "dominoes": [ + [1, 2], + [3, 1], + [2, 3] + ] }, "expected": true }, @@ -77,7 +81,11 @@ "description": "can reverse dominoes", "property": "canChain", "input": { - "dominoes": [[1, 2], [1, 3], [2, 3]] + "dominoes": [ + [1, 2], + [1, 3], + [2, 3] + ] }, "expected": true }, @@ -86,7 +94,11 @@ "description": "can't be chained", "property": "canChain", "input": { - "dominoes": [[1, 2], [4, 1], [2, 3]] + "dominoes": [ + [1, 2], + [4, 1], + [2, 3] + ] }, "expected": false }, @@ -102,7 +114,10 @@ ], "property": "canChain", "input": { - "dominoes": [[1, 1], [2, 2]] + "dominoes": [ + [1, 1], + [2, 2] + ] }, "expected": false }, @@ -111,7 +126,12 @@ "description": "disconnected - double loop", "property": "canChain", "input": { - "dominoes": [[1, 2], [2, 1], [3, 4], [4, 3]] + "dominoes": [ + [1, 2], + [2, 1], + [3, 4], + [4, 3] + ] }, "expected": false }, @@ -120,7 +140,12 @@ "description": "disconnected - single isolated", "property": "canChain", "input": { - "dominoes": [[1, 2], [2, 3], [3, 1], [4, 4]] + "dominoes": [ + [1, 2], + [2, 3], + [3, 1], + [4, 4] + ] }, "expected": false }, @@ -136,7 +161,13 @@ ], "property": "canChain", "input": { - "dominoes": [[1, 2], [2, 3], [3, 1], [2, 4], [2, 4]] + "dominoes": [ + [1, 2], + [2, 3], + [3, 1], + [2, 4], + [2, 4] + ] }, "expected": true }, @@ -145,7 +176,14 @@ "description": "separate loops", "property": "canChain", "input": { - "dominoes": [[1, 2], [2, 3], [3, 1], [1, 1], [2, 2], [3, 3]] + "dominoes": [ + [1, 2], + [2, 3], + [3, 1], + [1, 1], + [2, 2], + [3, 3] + ] }, "expected": true }, @@ -154,7 +192,17 @@ "description": "nine elements", "property": "canChain", "input": { - "dominoes": [[1, 2], [5, 3], [3, 1], [1, 2], [2, 4], [1, 6], [2, 3], [3, 4], [5, 6]] + "dominoes": [ + [1, 2], + [5, 3], + [3, 1], + [1, 2], + [2, 4], + [1, 6], + [2, 3], + [3, 4], + [5, 6] + ] }, "expected": true } diff --git a/exercises/grep/canonical-data.json b/exercises/grep/canonical-data.json index dfa1a21dd7..9f5bbba39a 100644 --- a/exercises/grep/canonical-data.json +++ b/exercises/grep/canonical-data.json @@ -64,9 +64,7 @@ "flags": [], "files": ["iliad.txt"] }, - "expected": [ - "Of Atreus, Agamemnon, King of men." - ] + "expected": ["Of Atreus, Agamemnon, King of men."] }, { "uuid": "76519cce-98e3-46cd-b287-aac31b1d77d6", @@ -77,9 +75,7 @@ "flags": ["-n"], "files": ["paradise-lost.txt"] }, - "expected": [ - "2:Of that Forbidden Tree, whose mortal tast" - ] + "expected": ["2:Of that Forbidden Tree, whose mortal tast"] }, { "uuid": "af0b6d3c-e0e8-475e-a112-c0fc10a1eb30", @@ -90,9 +86,7 @@ "flags": ["-i"], "files": ["paradise-lost.txt"] }, - "expected": [ - "Of that Forbidden Tree, whose mortal tast" - ] + "expected": ["Of that Forbidden Tree, whose mortal tast"] }, { "uuid": "ff7af839-d1b8-4856-a53e-99283579b672", @@ -103,9 +97,7 @@ "flags": ["-l"], "files": ["paradise-lost.txt"] }, - "expected": [ - "paradise-lost.txt" - ] + "expected": ["paradise-lost.txt"] }, { "uuid": "8625238a-720c-4a16-81f2-924ec8e222cb", @@ -116,9 +108,7 @@ "flags": ["-x"], "files": ["paradise-lost.txt"] }, - "expected": [ - "With loss of Eden, till one greater Man" - ] + "expected": ["With loss of Eden, till one greater Man"] }, { "uuid": "2a6266b3-a60f-475c-a5f5-f5008a717d3e", @@ -129,9 +119,7 @@ "flags": ["-n", "-i", "-x"], "files": ["iliad.txt"] }, - "expected": [ - "9:Of Atreus, Agamemnon, King of men." - ] + "expected": ["9:Of Atreus, Agamemnon, King of men."] }, { "uuid": "842222da-32e8-4646-89df-0d38220f77a1", @@ -225,9 +213,7 @@ "flags": ["-n", "-l"], "files": ["iliad.txt"] }, - "expected": [ - "iliad.txt" - ] + "expected": ["iliad.txt"] }, { "uuid": "87b21b24-b788-4d6e-a68b-7afe9ca141fe", @@ -263,9 +249,7 @@ "flags": [], "files": ["iliad.txt", "midsummer-night.txt", "paradise-lost.txt"] }, - "expected": [ - "iliad.txt:Of Atreus, Agamemnon, King of men." - ] + "expected": ["iliad.txt:Of Atreus, Agamemnon, King of men."] }, { "uuid": "4539bd36-6daa-4bc3-8e45-051f69f5aa95", @@ -307,10 +291,7 @@ "flags": ["-l"], "files": ["iliad.txt", "midsummer-night.txt", "paradise-lost.txt"] }, - "expected": [ - "iliad.txt", - "paradise-lost.txt" - ] + "expected": ["iliad.txt", "paradise-lost.txt"] }, { "uuid": "d69f3606-7d15-4ddf-89ae-01df198e6b6c", @@ -395,10 +376,7 @@ "flags": ["-n", "-l"], "files": ["iliad.txt", "midsummer-night.txt", "paradise-lost.txt"] }, - "expected": [ - "iliad.txt", - "paradise-lost.txt" - ] + "expected": ["iliad.txt", "paradise-lost.txt"] }, { "uuid": "ff406330-2f0b-4b17-9ee4-4b71c31dd6d2", diff --git a/exercises/house/canonical-data.json b/exercises/house/canonical-data.json index d18f8fc5bc..2fa841a930 100644 --- a/exercises/house/canonical-data.json +++ b/exercises/house/canonical-data.json @@ -19,9 +19,7 @@ "startVerse": 1, "endVerse": 1 }, - "expected": [ - "This is the house that Jack built." - ] + "expected": ["This is the house that Jack built."] }, { "uuid": "ebc825ac-6e2b-4a5e-9afd-95732191c8da", @@ -31,9 +29,7 @@ "startVerse": 2, "endVerse": 2 }, - "expected": [ - "This is the malt that lay in the house that Jack built." - ] + "expected": ["This is the malt that lay in the house that Jack built."] }, { "uuid": "1ed8bb0f-edb8-4bd1-b6d4-b64754fe4a60", diff --git a/exercises/kindergarten-garden/canonical-data.json b/exercises/kindergarten-garden/canonical-data.json index e76089ed9e..2c00358d2c 100644 --- a/exercises/kindergarten-garden/canonical-data.json +++ b/exercises/kindergarten-garden/canonical-data.json @@ -12,12 +12,7 @@ "diagram": "RC\nGG", "student": "Alice" }, - "expected": [ - "radishes", - "clover", - "grass", - "grass" - ] + "expected": ["radishes", "clover", "grass", "grass"] }, { "uuid": "acd19dc1-2200-4317-bc2a-08f021276b40", @@ -27,12 +22,7 @@ "diagram": "VC\nRC", "student": "Alice" }, - "expected": [ - "violets", - "clover", - "radishes", - "clover" - ] + "expected": ["violets", "clover", "radishes", "clover"] }, { "uuid": "c376fcc8-349c-446c-94b0-903947315757", @@ -42,12 +32,7 @@ "diagram": "VVCG\nVVRC", "student": "Bob" }, - "expected": [ - "clover", - "grass", - "radishes", - "clover" - ] + "expected": ["clover", "grass", "radishes", "clover"] }, { "description": "multiple students for the same garden with three students", @@ -60,12 +45,7 @@ "diagram": "VVCCGG\nVVCCGG", "student": "Bob" }, - "expected": [ - "clover", - "clover", - "clover", - "clover" - ] + "expected": ["clover", "clover", "clover", "clover"] }, { "uuid": "57712331-4896-4364-89f8-576421d69c44", @@ -75,12 +55,7 @@ "diagram": "VVCCGG\nVVCCGG", "student": "Charlie" }, - "expected": [ - "grass", - "grass", - "grass", - "grass" - ] + "expected": ["grass", "grass", "grass", "grass"] } ] } @@ -97,12 +72,7 @@ "diagram": "VRCGVVRVCGGCCGVRGCVCGCGV\nVRCCCGCRRGVCGCRVVCVGCGCV", "student": "Alice" }, - "expected": [ - "violets", - "radishes", - "violets", - "radishes" - ] + "expected": ["violets", "radishes", "violets", "radishes"] }, { "uuid": "ba25dbbc-10bd-4a37-b18e-f89ecd098a5e", @@ -112,12 +82,7 @@ "diagram": "VRCGVVRVCGGCCGVRGCVCGCGV\nVRCCCGCRRGVCGCRVVCVGCGCV", "student": "Bob" }, - "expected": [ - "clover", - "grass", - "clover", - "clover" - ] + "expected": ["clover", "grass", "clover", "clover"] }, { "uuid": "566b621b-f18e-4c5f-873e-be30544b838c", @@ -127,12 +92,7 @@ "diagram": "VRCGVVRVCGGCCGVRGCVCGCGV\nVRCCCGCRRGVCGCRVVCVGCGCV", "student": "Charlie" }, - "expected": [ - "violets", - "violets", - "clover", - "grass" - ] + "expected": ["violets", "violets", "clover", "grass"] }, { "uuid": "3ad3df57-dd98-46fc-9269-1877abf612aa", @@ -142,12 +102,7 @@ "diagram": "VRCGVVRVCGGCCGVRGCVCGCGV\nVRCCCGCRRGVCGCRVVCVGCGCV", "student": "David" }, - "expected": [ - "radishes", - "violets", - "clover", - "radishes" - ] + "expected": ["radishes", "violets", "clover", "radishes"] }, { "uuid": "0f0a55d1-9710-46ed-a0eb-399ba8c72db2", @@ -157,12 +112,7 @@ "diagram": "VRCGVVRVCGGCCGVRGCVCGCGV\nVRCCCGCRRGVCGCRVVCVGCGCV", "student": "Eve" }, - "expected": [ - "clover", - "grass", - "radishes", - "grass" - ] + "expected": ["clover", "grass", "radishes", "grass"] }, { "uuid": "a7e80c90-b140-4ea1-aee3-f4625365c9a4", @@ -172,12 +122,7 @@ "diagram": "VRCGVVRVCGGCCGVRGCVCGCGV\nVRCCCGCRRGVCGCRVVCVGCGCV", "student": "Fred" }, - "expected": [ - "grass", - "clover", - "violets", - "clover" - ] + "expected": ["grass", "clover", "violets", "clover"] }, { "uuid": "9d94b273-2933-471b-86e8-dba68694c615", @@ -187,12 +132,7 @@ "diagram": "VRCGVVRVCGGCCGVRGCVCGCGV\nVRCCCGCRRGVCGCRVVCVGCGCV", "student": "Ginny" }, - "expected": [ - "clover", - "grass", - "grass", - "clover" - ] + "expected": ["clover", "grass", "grass", "clover"] }, { "uuid": "f55bc6c2-ade8-4844-87c4-87196f1b7258", @@ -202,12 +142,7 @@ "diagram": "VRCGVVRVCGGCCGVRGCVCGCGV\nVRCCCGCRRGVCGCRVVCVGCGCV", "student": "Harriet" }, - "expected": [ - "violets", - "radishes", - "radishes", - "violets" - ] + "expected": ["violets", "radishes", "radishes", "violets"] }, { "uuid": "759070a3-1bb1-4dd4-be2c-7cce1d7679ae", @@ -217,12 +152,7 @@ "diagram": "VRCGVVRVCGGCCGVRGCVCGCGV\nVRCCCGCRRGVCGCRVVCVGCGCV", "student": "Ileana" }, - "expected": [ - "grass", - "clover", - "violets", - "clover" - ] + "expected": ["grass", "clover", "violets", "clover"] }, { "uuid": "78578123-2755-4d4a-9c7d-e985b8dda1c6", @@ -232,12 +162,7 @@ "diagram": "VRCGVVRVCGGCCGVRGCVCGCGV\nVRCCCGCRRGVCGCRVVCVGCGCV", "student": "Joseph" }, - "expected": [ - "violets", - "clover", - "violets", - "grass" - ] + "expected": ["violets", "clover", "violets", "grass"] }, { "uuid": "6bb66df7-f433-41ab-aec2-3ead6e99f65b", @@ -247,12 +172,7 @@ "diagram": "VRCGVVRVCGGCCGVRGCVCGCGV\nVRCCCGCRRGVCGCRVVCVGCGCV", "student": "Kincaid" }, - "expected": [ - "grass", - "clover", - "clover", - "grass" - ] + "expected": ["grass", "clover", "clover", "grass"] }, { "uuid": "d7edec11-6488-418a-94e6-ed509e0fa7eb", @@ -262,12 +182,7 @@ "diagram": "VRCGVVRVCGGCCGVRGCVCGCGV\nVRCCCGCRRGVCGCRVVCVGCGCV", "student": "Larry" }, - "expected": [ - "grass", - "violets", - "clover", - "violets" - ] + "expected": ["grass", "violets", "clover", "violets"] } ] } diff --git a/exercises/knapsack/canonical-data.json b/exercises/knapsack/canonical-data.json index 892abcfbd0..94a3db5ff4 100644 --- a/exercises/knapsack/canonical-data.json +++ b/exercises/knapsack/canonical-data.json @@ -1,8 +1,6 @@ { "exercise": "knapsack", - "comments": [ - "Depending on the language, the input type can be modified" - ], + "comments": ["Depending on the language, the input type can be modified"], "cases": [ { "uuid": "a4d7d2f0-ad8a-460c-86f3-88ba709d41a7", @@ -20,9 +18,7 @@ "property": "maximumValue", "input": { "maximumWeight": 10, - "items": [ - { "weight": 100, "value": 1 } - ] + "items": [{ "weight": 100, "value": 1 }] }, "expected": 0 }, diff --git a/exercises/markdown/canonical-data.json b/exercises/markdown/canonical-data.json index 3143d00d0a..21c36d32a8 100644 --- a/exercises/markdown/canonical-data.json +++ b/exercises/markdown/canonical-data.json @@ -1,8 +1,6 @@ { "exercise": "markdown", - "comments": [ - "Markdown is a shorthand for creating HTML from text strings." - ], + "comments": ["Markdown is a shorthand for creating HTML from text strings."], "cases": [ { "uuid": "e75c8103-a6b8-45d9-84ad-e68520545f6e", diff --git a/exercises/pascals-triangle/canonical-data.json b/exercises/pascals-triangle/canonical-data.json index fd1fe0c833..be586b0615 100644 --- a/exercises/pascals-triangle/canonical-data.json +++ b/exercises/pascals-triangle/canonical-data.json @@ -66,7 +66,14 @@ "input": { "count": 6 }, - "expected": [[1], [1, 1], [1, 2, 1], [1, 3, 3, 1], [1, 4, 6, 4, 1], [1, 5, 10, 10, 5, 1]] + "expected": [ + [1], + [1, 1], + [1, 2, 1], + [1, 3, 3, 1], + [1, 4, 6, 4, 1], + [1, 5, 10, 10, 5, 1] + ] }, { "uuid": "6cb26c66-7b57-4161-962c-81ec8c99f16b", @@ -75,7 +82,18 @@ "input": { "count": 10 }, - "expected": [[1], [1, 1], [1, 2, 1], [1, 3, 3, 1], [1, 4, 6, 4, 1], [1, 5, 10, 10, 5, 1], [1, 6, 15, 20, 15, 6, 1], [1, 7, 21, 35, 35, 21, 7, 1], [1, 8, 28, 56, 70, 56, 28, 8, 1], [1, 9, 36, 84, 126, 126, 84, 36, 9, 1]] + "expected": [ + [1], + [1, 1], + [1, 2, 1], + [1, 3, 3, 1], + [1, 4, 6, 4, 1], + [1, 5, 10, 10, 5, 1], + [1, 6, 15, 20, 15, 6, 1], + [1, 7, 21, 35, 35, 21, 7, 1], + [1, 8, 28, 56, 70, 56, 28, 8, 1], + [1, 9, 36, 84, 126, 126, 84, 36, 9, 1] + ] } ] } diff --git a/exercises/poker/canonical-data.json b/exercises/poker/canonical-data.json index df1bacb4b6..a594530f0a 100644 --- a/exercises/poker/canonical-data.json +++ b/exercises/poker/canonical-data.json @@ -6,28 +6,18 @@ "description": "single hand always wins", "property": "bestHands", "input": { - "hands": [ - "4S 5S 7H 8D JC" - ] + "hands": ["4S 5S 7H 8D JC"] }, - "expected": [ - "4S 5S 7H 8D JC" - ] + "expected": ["4S 5S 7H 8D JC"] }, { "uuid": "370ac23a-a00f-48a9-9965-6f3fb595cf45", "description": "highest card out of all hands wins", "property": "bestHands", "input": { - "hands": [ - "4D 5S 6S 8D 3C", - "2S 4C 7S 9H 10H", - "3S 4S 5D 6H JH" - ] + "hands": ["4D 5S 6S 8D 3C", "2S 4C 7S 9H 10H", "3S 4S 5D 6H JH"] }, - "expected": [ - "3S 4S 5D 6H JH" - ] + "expected": ["3S 4S 5D 6H JH"] }, { "uuid": "d94ad5a7-17df-484b-9932-c64fc26cff52", @@ -41,360 +31,232 @@ "3H 4H 5C 6C JD" ] }, - "expected": [ - "3S 4S 5D 6H JH", - "3H 4H 5C 6C JD" - ] + "expected": ["3S 4S 5D 6H JH", "3H 4H 5C 6C JD"] }, { "uuid": "61ed83a9-cfaa-40a5-942a-51f52f0a8725", "description": "multiple hands with the same high cards, tie compares next highest ranked, down to last card", "property": "bestHands", "input": { - "hands": [ - "3S 5H 6S 8D 7H", - "2S 5D 6D 8C 7S" - ] + "hands": ["3S 5H 6S 8D 7H", "2S 5D 6D 8C 7S"] }, - "expected": [ - "3S 5H 6S 8D 7H" - ] + "expected": ["3S 5H 6S 8D 7H"] }, { "uuid": "f7175a89-34ff-44de-b3d7-f6fd97d1fca4", "description": "one pair beats high card", "property": "bestHands", "input": { - "hands": [ - "4S 5H 6C 8D KH", - "2S 4H 6S 4D JH" - ] + "hands": ["4S 5H 6C 8D KH", "2S 4H 6S 4D JH"] }, - "expected": [ - "2S 4H 6S 4D JH" - ] + "expected": ["2S 4H 6S 4D JH"] }, { "uuid": "e114fd41-a301-4111-a9e7-5a7f72a76561", "description": "highest pair wins", "property": "bestHands", "input": { - "hands": [ - "4S 2H 6S 2D JH", - "2S 4H 6C 4D JD" - ] + "hands": ["4S 2H 6S 2D JH", "2S 4H 6C 4D JD"] }, - "expected": [ - "2S 4H 6C 4D JD" - ] + "expected": ["2S 4H 6C 4D JD"] }, { "uuid": "935bb4dc-a622-4400-97fa-86e7d06b1f76", "description": "two pairs beats one pair", "property": "bestHands", "input": { - "hands": [ - "2S 8H 6S 8D JH", - "4S 5H 4C 8C 5C" - ] + "hands": ["2S 8H 6S 8D JH", "4S 5H 4C 8C 5C"] }, - "expected": [ - "4S 5H 4C 8C 5C" - ] + "expected": ["4S 5H 4C 8C 5C"] }, { "uuid": "c8aeafe1-6e3d-4711-a6de-5161deca91fd", "description": "both hands have two pairs, highest ranked pair wins", "property": "bestHands", "input": { - "hands": [ - "2S 8H 2D 8D 3H", - "4S 5H 4C 8S 5D" - ] + "hands": ["2S 8H 2D 8D 3H", "4S 5H 4C 8S 5D"] }, - "expected": [ - "2S 8H 2D 8D 3H" - ] + "expected": ["2S 8H 2D 8D 3H"] }, { "uuid": "88abe1ba-7ad7-40f3-847e-0a26f8e46a60", "description": "both hands have two pairs, with the same highest ranked pair, tie goes to low pair", "property": "bestHands", "input": { - "hands": [ - "2S QS 2C QD JH", - "JD QH JS 8D QC" - ] + "hands": ["2S QS 2C QD JH", "JD QH JS 8D QC"] }, - "expected": [ - "JD QH JS 8D QC" - ] + "expected": ["JD QH JS 8D QC"] }, { "uuid": "15a7a315-0577-47a3-9981-d6cf8e6f387b", "description": "both hands have two identically ranked pairs, tie goes to remaining card (kicker)", "property": "bestHands", "input": { - "hands": [ - "JD QH JS 8D QC", - "JS QS JC 2D QD" - ] + "hands": ["JD QH JS 8D QC", "JS QS JC 2D QD"] }, - "expected": [ - "JD QH JS 8D QC" - ] + "expected": ["JD QH JS 8D QC"] }, { "uuid": "21e9f1e6-2d72-49a1-a930-228e5e0195dc", "description": "three of a kind beats two pair", "property": "bestHands", "input": { - "hands": [ - "2S 8H 2H 8D JH", - "4S 5H 4C 8S 4H" - ] + "hands": ["2S 8H 2H 8D JH", "4S 5H 4C 8S 4H"] }, - "expected": [ - "4S 5H 4C 8S 4H" - ] + "expected": ["4S 5H 4C 8S 4H"] }, { "uuid": "c2fffd1f-c287-480f-bf2d-9628e63bbcc3", "description": "both hands have three of a kind, tie goes to highest ranked triplet", "property": "bestHands", "input": { - "hands": [ - "2S 2H 2C 8D JH", - "4S AH AS 8C AD" - ] + "hands": ["2S 2H 2C 8D JH", "4S AH AS 8C AD"] }, - "expected": [ - "4S AH AS 8C AD" - ] + "expected": ["4S AH AS 8C AD"] }, { "uuid": "eb856cc2-481c-4b0d-9835-4d75d07a5d9d", "description": "with multiple decks, two players can have same three of a kind, ties go to highest remaining cards", "property": "bestHands", "input": { - "hands": [ - "4S AH AS 7C AD", - "4S AH AS 8C AD" - ] + "hands": ["4S AH AS 7C AD", "4S AH AS 8C AD"] }, - "expected": [ - "4S AH AS 8C AD" - ] + "expected": ["4S AH AS 8C AD"] }, { "uuid": "a858c5d9-2f28-48e7-9980-b7fa04060a60", "description": "a straight beats three of a kind", "property": "bestHands", "input": { - "hands": [ - "4S 5H 4C 8D 4H", - "3S 4D 2S 6D 5C" - ] + "hands": ["4S 5H 4C 8D 4H", "3S 4D 2S 6D 5C"] }, - "expected": [ - "3S 4D 2S 6D 5C" - ] + "expected": ["3S 4D 2S 6D 5C"] }, { "uuid": "73c9c756-e63e-4b01-a88d-0d4491a7a0e3", "description": "aces can end a straight (10 J Q K A)", "property": "bestHands", "input": { - "hands": [ - "4S 5H 4C 8D 4H", - "10D JH QS KD AC" - ] + "hands": ["4S 5H 4C 8D 4H", "10D JH QS KD AC"] }, - "expected": [ - "10D JH QS KD AC" - ] + "expected": ["10D JH QS KD AC"] }, { "uuid": "76856b0d-35cd-49ce-a492-fe5db53abc02", "description": "aces can start a straight (A 2 3 4 5)", "property": "bestHands", "input": { - "hands": [ - "4S 5H 4C 8D 4H", - "4D AH 3S 2D 5C" - ] + "hands": ["4S 5H 4C 8D 4H", "4D AH 3S 2D 5C"] }, - "expected": [ - "4D AH 3S 2D 5C" - ] + "expected": ["4D AH 3S 2D 5C"] }, { "uuid": "6980c612-bbff-4914-b17a-b044e4e69ea1", "description": "both hands with a straight, tie goes to highest ranked card", "property": "bestHands", "input": { - "hands": [ - "4S 6C 7S 8D 5H", - "5S 7H 8S 9D 6H" - ] + "hands": ["4S 6C 7S 8D 5H", "5S 7H 8S 9D 6H"] }, - "expected": [ - "5S 7H 8S 9D 6H" - ] + "expected": ["5S 7H 8S 9D 6H"] }, { "uuid": "5135675c-c2fc-4e21-9ba3-af77a32e9ba4", "description": "even though an ace is usually high, a 5-high straight is the lowest-scoring straight", "property": "bestHands", "input": { - "hands": [ - "2H 3C 4D 5D 6H", - "4S AH 3S 2D 5H" - ] + "hands": ["2H 3C 4D 5D 6H", "4S AH 3S 2D 5H"] }, - "expected": [ - "2H 3C 4D 5D 6H" - ] + "expected": ["2H 3C 4D 5D 6H"] }, { "uuid": "c601b5e6-e1df-4ade-b444-b60ce13b2571", "description": "flush beats a straight", "property": "bestHands", "input": { - "hands": [ - "4C 6H 7D 8D 5H", - "2S 4S 5S 6S 7S" - ] + "hands": ["4C 6H 7D 8D 5H", "2S 4S 5S 6S 7S"] }, - "expected": [ - "2S 4S 5S 6S 7S" - ] + "expected": ["2S 4S 5S 6S 7S"] }, { "uuid": "4d90261d-251c-49bd-a468-896bf10133de", "description": "both hands have a flush, tie goes to high card, down to the last one if necessary", "property": "bestHands", "input": { - "hands": [ - "4H 7H 8H 9H 6H", - "2S 4S 5S 6S 7S" - ] + "hands": ["4H 7H 8H 9H 6H", "2S 4S 5S 6S 7S"] }, - "expected": [ - "4H 7H 8H 9H 6H" - ] + "expected": ["4H 7H 8H 9H 6H"] }, { "uuid": "3a19361d-8974-455c-82e5-f7152f5dba7c", "description": "full house beats a flush", "property": "bestHands", "input": { - "hands": [ - "3H 6H 7H 8H 5H", - "4S 5H 4C 5D 4H" - ] + "hands": ["3H 6H 7H 8H 5H", "4S 5H 4C 5D 4H"] }, - "expected": [ - "4S 5H 4C 5D 4H" - ] + "expected": ["4S 5H 4C 5D 4H"] }, { "uuid": "eb73d0e6-b66c-4f0f-b8ba-bf96bc0a67f0", "description": "both hands have a full house, tie goes to highest-ranked triplet", "property": "bestHands", "input": { - "hands": [ - "4H 4S 4D 9S 9D", - "5H 5S 5D 8S 8D" - ] + "hands": ["4H 4S 4D 9S 9D", "5H 5S 5D 8S 8D"] }, - "expected": [ - "5H 5S 5D 8S 8D" - ] + "expected": ["5H 5S 5D 8S 8D"] }, { "uuid": "34b51168-1e43-4c0d-9b32-e356159b4d5d", "description": "with multiple decks, both hands have a full house with the same triplet, tie goes to the pair", "property": "bestHands", "input": { - "hands": [ - "5H 5S 5D 9S 9D", - "5H 5S 5D 8S 8D" - ] + "hands": ["5H 5S 5D 9S 9D", "5H 5S 5D 8S 8D"] }, - "expected": [ - "5H 5S 5D 9S 9D" - ] + "expected": ["5H 5S 5D 9S 9D"] }, { "uuid": "d61e9e99-883b-4f99-b021-18f0ae50c5f4", "description": "four of a kind beats a full house", "property": "bestHands", "input": { - "hands": [ - "4S 5H 4D 5D 4H", - "3S 3H 2S 3D 3C" - ] + "hands": ["4S 5H 4D 5D 4H", "3S 3H 2S 3D 3C"] }, - "expected": [ - "3S 3H 2S 3D 3C" - ] + "expected": ["3S 3H 2S 3D 3C"] }, { "uuid": "2e1c8c63-e0cb-4214-a01b-91954490d2fe", "description": "both hands have four of a kind, tie goes to high quad", "property": "bestHands", "input": { - "hands": [ - "2S 2H 2C 8D 2D", - "4S 5H 5S 5D 5C" - ] + "hands": ["2S 2H 2C 8D 2D", "4S 5H 5S 5D 5C"] }, - "expected": [ - "4S 5H 5S 5D 5C" - ] + "expected": ["4S 5H 5S 5D 5C"] }, { "uuid": "892ca75d-5474-495d-9f64-a6ce2dcdb7e1", - "description": "with multiple decks, both hands with identical four of a kind, tie determined by kicker" , + "description": "with multiple decks, both hands with identical four of a kind, tie determined by kicker", "property": "bestHands", "input": { - "hands": [ - "3S 3H 2S 3D 3C", - "3S 3H 4S 3D 3C" - ] + "hands": ["3S 3H 2S 3D 3C", "3S 3H 4S 3D 3C"] }, - "expected": [ - "3S 3H 4S 3D 3C" - ] + "expected": ["3S 3H 4S 3D 3C"] }, { "uuid": "923bd910-dc7b-4f7d-a330-8b42ec10a3ac", "description": "straight flush beats four of a kind", "property": "bestHands", "input": { - "hands": [ - "4S 5H 5S 5D 5C", - "7S 8S 9S 6S 10S" - ] + "hands": ["4S 5H 5S 5D 5C", "7S 8S 9S 6S 10S"] }, - "expected": [ - "7S 8S 9S 6S 10S" - ] + "expected": ["7S 8S 9S 6S 10S"] }, { "uuid": "d0927f70-5aec-43db-aed8-1cbd1b6ee9ad", "description": "both hands have straight flush, tie goes to highest-ranked card", "property": "bestHands", "input": { - "hands": [ - "4H 6H 7H 8H 5H", - "5S 7S 8S 9S 6S" - ] + "hands": ["4H 6H 7H 8H 5H", "5S 7S 8S 9S 6S"] }, - "expected": [ - "5S 7S 8S 9S 6S" - ] + "expected": ["5S 7S 8S 9S 6S"] } ] } diff --git a/exercises/pov/canonical-data.json b/exercises/pov/canonical-data.json index 183697c114..b10d346bd6 100644 --- a/exercises/pov/canonical-data.json +++ b/exercises/pov/canonical-data.json @@ -354,10 +354,7 @@ ] } }, - "expected": [ - "x", - "parent" - ] + "expected": ["x", "parent"] }, { "uuid": "d0002674-fcfb-4cdc-9efa-bfc54e3c31b5", @@ -384,11 +381,7 @@ ] } }, - "expected": [ - "x", - "parent", - "b" - ] + "expected": ["x", "parent", "b"] }, { "uuid": "c9877cd1-0a69-40d4-b362-725763a5c38f", @@ -436,13 +429,7 @@ ] } }, - "expected": [ - "x", - "parent", - "grandparent", - "uncle", - "cousin-1" - ] + "expected": ["x", "parent", "grandparent", "uncle", "cousin-1"] }, { "uuid": "9fb17a82-2c14-4261-baa3-2f3f234ffa03", @@ -471,11 +458,7 @@ ] } }, - "expected": [ - "x", - "parent", - "sibling-1" - ] + "expected": ["x", "parent", "sibling-1"] }, { "uuid": "5124ed49-7845-46ad-bc32-97d5ac7451b2", @@ -502,11 +485,7 @@ ] } }, - "expected": [ - "a", - "parent", - "c" - ] + "expected": ["a", "parent", "c"] }, { "uuid": "f52a183c-25cc-4c87-9fc9-0e7f81a5725c", diff --git a/exercises/pythagorean-triplet/canonical-data.json b/exercises/pythagorean-triplet/canonical-data.json index ae7ce4d313..46836a1b37 100644 --- a/exercises/pythagorean-triplet/canonical-data.json +++ b/exercises/pythagorean-triplet/canonical-data.json @@ -8,9 +8,7 @@ "input": { "n": 12 }, - "expected": [ - [3, 4, 5] - ] + "expected": [[3, 4, 5]] }, { "uuid": "48b21332-0a3d-43b2-9a52-90b2a6e5c9f5", @@ -19,9 +17,7 @@ "input": { "n": 108 }, - "expected": [ - [27, 36, 45] - ] + "expected": [[27, 36, 45]] }, { "uuid": "dffc1266-418e-4daa-81af-54c3e95c3bb5", @@ -30,9 +26,7 @@ "input": { "n": 1000 }, - "expected": [ - [200, 375, 425] - ] + "expected": [[200, 375, 425]] }, { "uuid": "5f86a2d4-6383-4cce-93a5-e4489e79b186", diff --git a/exercises/reverse-string/canonical-data.json b/exercises/reverse-string/canonical-data.json index cc23c6a47e..3608727afb 100644 --- a/exercises/reverse-string/canonical-data.json +++ b/exercises/reverse-string/canonical-data.json @@ -1,6 +1,8 @@ { "exercise": "reverse-string", - "comments": ["If property based testing tools are available, a good property to test is reversing a string twice: reverse(reverse(string)) == string"], + "comments": [ + "If property based testing tools are available, a good property to test is reversing a string twice: reverse(reverse(string)) == string" + ], "cases": [ { "uuid": "c3b7d806-dced-49ee-8543-933fd1719b1c", diff --git a/exercises/roman-numerals/canonical-data.json b/exercises/roman-numerals/canonical-data.json index 5bbf351167..1de2ff22ac 100644 --- a/exercises/roman-numerals/canonical-data.json +++ b/exercises/roman-numerals/canonical-data.json @@ -89,7 +89,9 @@ { "uuid": "607ead62-23d6-4c11-a396-ef821e2e5f75", "description": "49 is XLIX", - "comments": ["Because 49 is not 40 + 5 + 4, but rather (50 - 10) + (10 - 1)"], + "comments": [ + "Because 49 is not 40 + 5 + 4, but rather (50 - 10) + (10 - 1)" + ], "property": "roman", "input": { "number": 49 diff --git a/exercises/rotational-cipher/canonical-data.json b/exercises/rotational-cipher/canonical-data.json index 6b6f0430cc..03456211cc 100644 --- a/exercises/rotational-cipher/canonical-data.json +++ b/exercises/rotational-cipher/canonical-data.json @@ -1,8 +1,6 @@ { "exercise": "rotational-cipher", - "comments": [ - "The tests are a series of rotation tests: " - ], + "comments": ["The tests are a series of rotation tests: "], "cases": [ { "uuid": "74e58a38-e484-43f1-9466-877a7515e10f", diff --git a/exercises/spiral-matrix/canonical-data.json b/exercises/spiral-matrix/canonical-data.json index aa44f92355..460a88f142 100644 --- a/exercises/spiral-matrix/canonical-data.json +++ b/exercises/spiral-matrix/canonical-data.json @@ -52,10 +52,10 @@ "size": 4 }, "expected": [ - [ 1, 2, 3, 4], + [1, 2, 3, 4], [12, 13, 14, 5], [11, 16, 15, 6], - [10, 9, 8, 7] + [10, 9, 8, 7] ] }, { @@ -66,7 +66,7 @@ "size": 5 }, "expected": [ - [ 1, 2, 3, 4, 5], + [1, 2, 3, 4, 5], [16, 17, 18, 19, 6], [15, 24, 25, 20, 7], [14, 23, 22, 21, 8], diff --git a/exercises/tournament/canonical-data.json b/exercises/tournament/canonical-data.json index a6238747d4..990fdbd55e 100644 --- a/exercises/tournament/canonical-data.json +++ b/exercises/tournament/canonical-data.json @@ -16,18 +16,14 @@ "input": { "rows": [] }, - "expected": [ - "Team | MP | W | D | L | P" - ] + "expected": ["Team | MP | W | D | L | P"] }, { "uuid": "1b4a8aef-0734-4007-80a2-0626178c88f4", "description": "a win is three points, a loss is zero points", "property": "tally", "input": { - "rows": [ - "Allegoric Alaskans;Blithering Badgers;win" - ] + "rows": ["Allegoric Alaskans;Blithering Badgers;win"] }, "expected": [ "Team | MP | W | D | L | P", @@ -40,9 +36,7 @@ "description": "a win can also be expressed as a loss", "property": "tally", "input": { - "rows": [ - "Blithering Badgers;Allegoric Alaskans;loss" - ] + "rows": ["Blithering Badgers;Allegoric Alaskans;loss"] }, "expected": [ "Team | MP | W | D | L | P", @@ -55,9 +49,7 @@ "description": "a different team can win", "property": "tally", "input": { - "rows": [ - "Blithering Badgers;Allegoric Alaskans;win" - ] + "rows": ["Blithering Badgers;Allegoric Alaskans;win"] }, "expected": [ "Team | MP | W | D | L | P", @@ -70,9 +62,7 @@ "description": "a draw is one point each", "property": "tally", "input": { - "rows": [ - "Allegoric Alaskans;Blithering Badgers;draw" - ] + "rows": ["Allegoric Alaskans;Blithering Badgers;draw"] }, "expected": [ "Team | MP | W | D | L | P", diff --git a/exercises/variable-length-quantity/canonical-data.json b/exercises/variable-length-quantity/canonical-data.json index 1fcae474b8..a78d42e2ff 100644 --- a/exercises/variable-length-quantity/canonical-data.json +++ b/exercises/variable-length-quantity/canonical-data.json @@ -170,7 +170,9 @@ "input": { "integers": [8192, 1193046, 268435455, 0, 16383, 16384] }, - "expected": [192, 0, 200, 232, 86, 255, 255, 255, 127, 0, 255, 127, 129, 128, 0] + "expected": [ + 192, 0, 200, 232, 86, 255, 255, 255, 127, 0, 255, 127, 129, 128, 0 + ] } ] }, @@ -249,7 +251,9 @@ "description": "multiple values", "property": "decode", "input": { - "integers": [192, 0, 200, 232, 86, 255, 255, 255, 127, 0, 255, 127, 129, 128, 0] + "integers": [ + 192, 0, 200, 232, 86, 255, 255, 255, 127, 0, 255, 127, 129, 128, 0 + ] }, "expected": [8192, 1193046, 268435455, 0, 16383, 16384] } From ac3cbd26900ddc61a558a705dc87d3305c5abffe Mon Sep 17 00:00:00 2001 From: Peter Tseng Date: Thu, 17 Feb 2022 08:09:06 +0000 Subject: [PATCH 2/3] dominoes: we affirm that inputs should be on one line --- .prettierignore | 1 + exercises/dominoes/canonical-data.json | 66 ++++---------------------- 2 files changed, 10 insertions(+), 57 deletions(-) diff --git a/.prettierignore b/.prettierignore index 89cd6792e8..18b18968e9 100644 --- a/.prettierignore +++ b/.prettierignore @@ -1,5 +1,6 @@ exercises/connect/canonical-data.json exercises/diamond/canonical-data.json +exercises/dominoes/canonical-data.json exercises/flatten-array/canonical-data.json exercises/forth/canonical-data.json exercises/go-counting/canonical-data.json diff --git a/exercises/dominoes/canonical-data.json b/exercises/dominoes/canonical-data.json index 620f7c818c..3b9b74d70e 100644 --- a/exercises/dominoes/canonical-data.json +++ b/exercises/dominoes/canonical-data.json @@ -68,11 +68,7 @@ "description": "three elements", "property": "canChain", "input": { - "dominoes": [ - [1, 2], - [3, 1], - [2, 3] - ] + "dominoes": [[1, 2], [3, 1], [2, 3]] }, "expected": true }, @@ -81,11 +77,7 @@ "description": "can reverse dominoes", "property": "canChain", "input": { - "dominoes": [ - [1, 2], - [1, 3], - [2, 3] - ] + "dominoes": [[1, 2], [1, 3], [2, 3]] }, "expected": true }, @@ -94,11 +86,7 @@ "description": "can't be chained", "property": "canChain", "input": { - "dominoes": [ - [1, 2], - [4, 1], - [2, 3] - ] + "dominoes": [[1, 2], [4, 1], [2, 3]] }, "expected": false }, @@ -114,10 +102,7 @@ ], "property": "canChain", "input": { - "dominoes": [ - [1, 1], - [2, 2] - ] + "dominoes": [[1, 1], [2, 2]] }, "expected": false }, @@ -126,12 +111,7 @@ "description": "disconnected - double loop", "property": "canChain", "input": { - "dominoes": [ - [1, 2], - [2, 1], - [3, 4], - [4, 3] - ] + "dominoes": [[1, 2], [2, 1], [3, 4], [4, 3]] }, "expected": false }, @@ -140,12 +120,7 @@ "description": "disconnected - single isolated", "property": "canChain", "input": { - "dominoes": [ - [1, 2], - [2, 3], - [3, 1], - [4, 4] - ] + "dominoes": [[1, 2], [2, 3], [3, 1], [4, 4]] }, "expected": false }, @@ -161,13 +136,7 @@ ], "property": "canChain", "input": { - "dominoes": [ - [1, 2], - [2, 3], - [3, 1], - [2, 4], - [2, 4] - ] + "dominoes": [[1, 2], [2, 3], [3, 1], [2, 4], [2, 4]] }, "expected": true }, @@ -176,14 +145,7 @@ "description": "separate loops", "property": "canChain", "input": { - "dominoes": [ - [1, 2], - [2, 3], - [3, 1], - [1, 1], - [2, 2], - [3, 3] - ] + "dominoes": [[1, 2], [2, 3], [3, 1], [1, 1], [2, 2], [3, 3]] }, "expected": true }, @@ -192,17 +154,7 @@ "description": "nine elements", "property": "canChain", "input": { - "dominoes": [ - [1, 2], - [5, 3], - [3, 1], - [1, 2], - [2, 4], - [1, 6], - [2, 3], - [3, 4], - [5, 6] - ] + "dominoes": [[1, 2], [5, 3], [3, 1], [1, 2], [2, 4], [1, 6], [2, 3], [3, 4], [5, 6]] }, "expected": true } From a62dc2d579309113141f64d14f9f424dcf9745b1 Mon Sep 17 00:00:00 2001 From: Peter Tseng Date: Thu, 17 Feb 2022 08:17:32 +0000 Subject: [PATCH 3/3] book-store,bowling,change,vlq: inputs on one line (vlq = variable-length-quantity) --- .prettierignore | 4 + exercises/book-store/canonical-data.json | 4 +- exercises/bowling/canonical-data.json | 92 +++++-------------- exercises/change/canonical-data.json | 4 +- .../canonical-data.json | 8 +- 5 files changed, 31 insertions(+), 81 deletions(-) diff --git a/.prettierignore b/.prettierignore index 18b18968e9..2d1a836a16 100644 --- a/.prettierignore +++ b/.prettierignore @@ -1,3 +1,6 @@ +exercises/book-store/canonical-data.json +exercises/bowling/canonical-data.json +exercises/change/canonical-data.json exercises/connect/canonical-data.json exercises/diamond/canonical-data.json exercises/dominoes/canonical-data.json @@ -11,4 +14,5 @@ exercises/saddle-points/canonical-data.json exercises/scale-generator/canonical-data.json exercises/sieve/canonical-data.json exercises/transpose/canonical-data.json +exercises/variable-length-quantity/canonical-data.json exercises/word-search/canonical-data.json diff --git a/exercises/book-store/canonical-data.json b/exercises/book-store/canonical-data.json index 82e33aa87a..17211d602c 100644 --- a/exercises/book-store/canonical-data.json +++ b/exercises/book-store/canonical-data.json @@ -171,9 +171,7 @@ ], "property": "total", "input": { - "basket": [ - 1, 1, 1, 1, 1, 1, 2, 2, 2, 2, 2, 2, 3, 3, 3, 3, 3, 3, 4, 4, 5, 5 - ] + "basket": [1, 1, 1, 1, 1, 1, 2, 2, 2, 2, 2, 2, 3, 3, 3, 3, 3, 3, 4, 4, 5, 5] }, "expected": 14560 }, diff --git a/exercises/bowling/canonical-data.json b/exercises/bowling/canonical-data.json index b2ff54dd18..c8e8d13150 100644 --- a/exercises/bowling/canonical-data.json +++ b/exercises/bowling/canonical-data.json @@ -25,9 +25,7 @@ "description": "should be able to score a game with all zeros", "property": "score", "input": { - "previousRolls": [ - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 - ] + "previousRolls": [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0] }, "expected": 0 }, @@ -36,9 +34,7 @@ "description": "should be able to score a game with no strikes or spares", "property": "score", "input": { - "previousRolls": [ - 3, 6, 3, 6, 3, 6, 3, 6, 3, 6, 3, 6, 3, 6, 3, 6, 3, 6, 3, 6 - ] + "previousRolls": [3, 6, 3, 6, 3, 6, 3, 6, 3, 6, 3, 6, 3, 6, 3, 6, 3, 6, 3, 6] }, "expected": 90 }, @@ -47,9 +43,7 @@ "description": "a spare followed by zeros is worth ten points", "property": "score", "input": { - "previousRolls": [ - 6, 4, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 - ] + "previousRolls": [6, 4, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0] }, "expected": 10 }, @@ -58,9 +52,7 @@ "description": "points scored in the roll after a spare are counted twice", "property": "score", "input": { - "previousRolls": [ - 6, 4, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 - ] + "previousRolls": [6, 4, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0] }, "expected": 16 }, @@ -69,9 +61,7 @@ "description": "consecutive spares each get a one roll bonus", "property": "score", "input": { - "previousRolls": [ - 5, 5, 3, 7, 4, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 - ] + "previousRolls": [5, 5, 3, 7, 4, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0] }, "expected": 31 }, @@ -80,9 +70,7 @@ "description": "a spare in the last frame gets a one roll bonus that is counted once", "property": "score", "input": { - "previousRolls": [ - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 7, 3, 7 - ] + "previousRolls": [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 7, 3, 7] }, "expected": 17 }, @@ -91,9 +79,7 @@ "description": "a strike earns ten points in a frame with a single roll", "property": "score", "input": { - "previousRolls": [ - 10, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 - ] + "previousRolls": [10, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0] }, "expected": 10 }, @@ -102,9 +88,7 @@ "description": "points scored in the two rolls after a strike are counted twice as a bonus", "property": "score", "input": { - "previousRolls": [ - 10, 5, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 - ] + "previousRolls": [10, 5, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0] }, "expected": 26 }, @@ -122,9 +106,7 @@ "description": "a strike in the last frame gets a two roll bonus that is counted once", "property": "score", "input": { - "previousRolls": [ - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 7, 1 - ] + "previousRolls": [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 7, 1] }, "expected": 18 }, @@ -133,9 +115,7 @@ "description": "rolling a spare with the two roll bonus does not get a bonus roll", "property": "score", "input": { - "previousRolls": [ - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 7, 3 - ] + "previousRolls": [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 7, 3] }, "expected": 20 }, @@ -144,9 +124,7 @@ "description": "strikes with the two roll bonus do not get bonus rolls", "property": "score", "input": { - "previousRolls": [ - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 10, 10 - ] + "previousRolls": [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 10, 10] }, "expected": 30 }, @@ -166,9 +144,7 @@ "description": "a strike with the one roll bonus after a spare in the last frame does not get a bonus", "property": "score", "input": { - "previousRolls": [ - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 7, 3, 10 - ] + "previousRolls": [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 7, 3, 10] }, "expected": 20 }, @@ -222,9 +198,7 @@ "description": "bonus roll after a strike in the last frame cannot score more than 10 points", "property": "roll", "input": { - "previousRolls": [ - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10 - ], + "previousRolls": [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10], "roll": 11 }, "expected": { @@ -236,9 +210,7 @@ "description": "two bonus rolls after a strike in the last frame cannot score more than 10 points", "property": "roll", "input": { - "previousRolls": [ - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 5 - ], + "previousRolls": [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 5], "roll": 6 }, "expected": { @@ -250,9 +222,7 @@ "description": "two bonus rolls after a strike in the last frame can score more than 10 points if one is a strike", "property": "score", "input": { - "previousRolls": [ - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 10, 6 - ] + "previousRolls": [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 10, 6] }, "expected": 26 }, @@ -261,9 +231,7 @@ "description": "the second bonus rolls after a strike in the last frame cannot be a strike if the first one is not a strike", "property": "roll", "input": { - "previousRolls": [ - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 6 - ], + "previousRolls": [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 6], "roll": 10 }, "expected": { @@ -275,9 +243,7 @@ "description": "second bonus roll after a strike in the last frame cannot score more than 10 points", "property": "roll", "input": { - "previousRolls": [ - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 10 - ], + "previousRolls": [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 10], "roll": 11 }, "expected": { @@ -311,9 +277,7 @@ "description": "cannot roll if game already has ten frames", "property": "roll", "input": { - "previousRolls": [ - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 - ], + "previousRolls": [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], "roll": 0 }, "expected": { @@ -325,9 +289,7 @@ "description": "bonus rolls for a strike in the last frame must be rolled before score can be calculated", "property": "score", "input": { - "previousRolls": [ - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10 - ] + "previousRolls": [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10] }, "expected": { "error": "Score cannot be taken until the end of the game" @@ -338,9 +300,7 @@ "description": "both bonus rolls for a strike in the last frame must be rolled before score can be calculated", "property": "score", "input": { - "previousRolls": [ - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 10 - ] + "previousRolls": [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 10] }, "expected": { "error": "Score cannot be taken until the end of the game" @@ -351,9 +311,7 @@ "description": "bonus roll for a spare in the last frame must be rolled before score can be calculated", "property": "score", "input": { - "previousRolls": [ - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 7, 3 - ] + "previousRolls": [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 7, 3] }, "expected": { "error": "Score cannot be taken until the end of the game" @@ -364,9 +322,7 @@ "description": "cannot roll after bonus roll for spare", "property": "roll", "input": { - "previousRolls": [ - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 7, 3, 2 - ], + "previousRolls": [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 7, 3, 2], "roll": 2 }, "expected": { @@ -378,9 +334,7 @@ "description": "cannot roll after bonus rolls for strike", "property": "roll", "input": { - "previousRolls": [ - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 3, 2 - ], + "previousRolls": [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 3, 2], "roll": 2 }, "expected": { diff --git a/exercises/change/canonical-data.json b/exercises/change/canonical-data.json index b5f2db3eae..291d82ce93 100644 --- a/exercises/change/canonical-data.json +++ b/exercises/change/canonical-data.json @@ -64,9 +64,7 @@ "coins": [1, 2, 5, 10, 20, 50, 100], "target": 999 }, - "expected": [ - 2, 2, 5, 20, 20, 50, 100, 100, 100, 100, 100, 100, 100, 100, 100 - ] + "expected": [2, 2, 5, 20, 20, 50, 100, 100, 100, 100, 100, 100, 100, 100, 100] }, { "uuid": "f79d2e9b-0ae3-4d6a-bb58-dc978b0dba28", diff --git a/exercises/variable-length-quantity/canonical-data.json b/exercises/variable-length-quantity/canonical-data.json index a78d42e2ff..1fcae474b8 100644 --- a/exercises/variable-length-quantity/canonical-data.json +++ b/exercises/variable-length-quantity/canonical-data.json @@ -170,9 +170,7 @@ "input": { "integers": [8192, 1193046, 268435455, 0, 16383, 16384] }, - "expected": [ - 192, 0, 200, 232, 86, 255, 255, 255, 127, 0, 255, 127, 129, 128, 0 - ] + "expected": [192, 0, 200, 232, 86, 255, 255, 255, 127, 0, 255, 127, 129, 128, 0] } ] }, @@ -251,9 +249,7 @@ "description": "multiple values", "property": "decode", "input": { - "integers": [ - 192, 0, 200, 232, 86, 255, 255, 255, 127, 0, 255, 127, 129, 128, 0 - ] + "integers": [192, 0, 200, 232, 86, 255, 255, 255, 127, 0, 255, 127, 129, 128, 0] }, "expected": [8192, 1193046, 268435455, 0, 16383, 16384] }