Skip to content

Commit 7518e61

Browse files
Linting and minor wording
1 parent 3d4c8cb commit 7518e61

File tree

3 files changed

+20
-102
lines changed

3 files changed

+20
-102
lines changed

exercises/flower-field/canonical-data.json

Lines changed: 16 additions & 98 deletions
Original file line numberDiff line numberDiff line change
@@ -30,68 +30,36 @@
3030
"description": "no flowers",
3131
"property": "annotate",
3232
"input": {
33-
"garden": [
34-
" ",
35-
" ",
36-
" "
37-
]
33+
"garden": [" ", " ", " "]
3834
},
39-
"expected": [
40-
" ",
41-
" ",
42-
" "
43-
]
35+
"expected": [" ", " ", " "]
4436
},
4537
{
4638
"uuid": "225176a0-725e-43cd-aa13-9dced501f16e",
4739
"description": "garden full of flowers",
4840
"property": "annotate",
4941
"input": {
50-
"garden": [
51-
"***",
52-
"***",
53-
"***"
54-
]
42+
"garden": ["***", "***", "***"]
5543
},
56-
"expected": [
57-
"***",
58-
"***",
59-
"***"
60-
]
44+
"expected": ["***", "***", "***"]
6145
},
6246
{
6347
"uuid": "3f345495-f1a5-4132-8411-74bd7ca08c49",
6448
"description": "flower surrounded by spaces",
6549
"property": "annotate",
6650
"input": {
67-
"garden": [
68-
" ",
69-
" * ",
70-
" "
71-
]
51+
"garden": [" ", " * ", " "]
7252
},
73-
"expected": [
74-
"111",
75-
"1*1",
76-
"111"
77-
]
53+
"expected": ["111", "1*1", "111"]
7854
},
7955
{
8056
"uuid": "6cb04070-4199-4ef7-a6fa-92f68c660fca",
8157
"description": "space surrounded by flowers",
8258
"property": "annotate",
8359
"input": {
84-
"garden": [
85-
"***",
86-
"* *",
87-
"***"
88-
]
60+
"garden": ["***", "* *", "***"]
8961
},
90-
"expected": [
91-
"***",
92-
"*8*",
93-
"***"
94-
]
62+
"expected": ["***", "*8*", "***"]
9563
},
9664
{
9765
"uuid": "272d2306-9f62-44fe-8ab5-6b0f43a26338",
@@ -116,86 +84,36 @@
11684
"description": "vertical line",
11785
"property": "annotate",
11886
"input": {
119-
"garden": [
120-
" ",
121-
"*",
122-
" ",
123-
"*",
124-
" "
125-
]
87+
"garden": [" ", "*", " ", "*", " "]
12688
},
127-
"expected": [
128-
"1",
129-
"*",
130-
"2",
131-
"*",
132-
"1"
133-
]
89+
"expected": ["1", "*", "2", "*", "1"]
13490
},
13591
{
13692
"uuid": "b40f42f5-dec5-4abc-b167-3f08195189c1",
13793
"description": "vertical line, flowers at edges",
13894
"property": "annotate",
13995
"input": {
140-
"garden": [
141-
"*",
142-
" ",
143-
" ",
144-
" ",
145-
"*"
146-
]
96+
"garden": ["*", " ", " ", " ", "*"]
14797
},
148-
"expected": [
149-
"*",
150-
"1",
151-
" ",
152-
"1",
153-
"*"
154-
]
98+
"expected": ["*", "1", " ", "1", "*"]
15599
},
156100
{
157101
"uuid": "58674965-7b42-4818-b930-0215062d543c",
158102
"description": "cross",
159103
"property": "annotate",
160104
"input": {
161-
"garden": [
162-
" * ",
163-
" * ",
164-
"*****",
165-
" * ",
166-
" * "
167-
]
105+
"garden": [" * ", " * ", "*****", " * ", " * "]
168106
},
169-
"expected": [
170-
" 2*2 ",
171-
"25*52",
172-
"*****",
173-
"25*52",
174-
" 2*2 "
175-
]
107+
"expected": [" 2*2 ", "25*52", "*****", "25*52", " 2*2 "]
176108
},
177109
{
178110
"uuid": "dd9d4ca8-9e68-4f78-a677-a2a70fd7a7b8",
179111
"description": "large garden",
180112
"property": "annotate",
181113
"input": {
182-
"garden": [
183-
" * * ",
184-
" * ",
185-
" * ",
186-
" * *",
187-
" * * ",
188-
" "
189-
]
114+
"garden": [" * * ", " * ", " * ", " * *", " * * ", " "]
190115
},
191-
"expected": [
192-
"1*22*1",
193-
"12*322",
194-
" 123*2",
195-
"112*4*",
196-
"1*22*2",
197-
"111111"
198-
]
116+
"expected": ["1*22*1", "12*322", " 123*2", "112*4*", "1*22*2", "111111"]
199117
}
200118
]
201119
}

exercises/flower-field/instructions.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
# Instructions
22

3-
Your task is to add flower counts to empty squares in a completed Flower Field board.
4-
The board itself is a rectangle composed of squares that are either empty (`' '`) or a flower (`'*'`).
3+
Your task is to add flower counts to empty squares in a completed Flower Field garden.
4+
The garden itself is a rectangle board composed of squares that are either empty (`' '`) or a flower (`'*'`).
55

66
For each empty square, count the number of flowers adjacent to it (horizontally, vertically, diagonally).
77
If the empty square has no adjacent flowers, leave it empty.
Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
# Introduction
22

3-
[Flower Field][Wikipedia] is a compassionate reimagining of the popular game Minesweeper.
3+
[Flower Field][history] is a compassionate reimagining of the popular game Minesweeper.
44
The object of the game is to find all the flowers in the garden using numeric hints that indicate how many flowers are directly adjacent (horizontally, vertically, diagonally) to a square.
55
"Flower Field" shipped in regional versions of Microsoft Windows in Italy, Germany, South Korea, Japan and Taiwan.
66

7-
[Wikipedia]: https://en.wikipedia.org/wiki/Minesweeper_(video_game)#History
7+
[history]: https://web.archive.org/web/20020409051321fw_/http://rcm.usr.dsi.unimi.it/rcmweb/fnm/

0 commit comments

Comments
 (0)