File tree Expand file tree Collapse file tree
exercises/practice/connect Expand file tree Collapse file tree Original file line number Diff line number Diff line change 1- # This is an auto-generated file. Regular comments will be removed when this
2- # file is regenerated. Regenerating will not touch any manually added keys,
3- # so comments can be added in a "comment" key.
1+ # This is an auto-generated file.
2+ #
3+ # Regenerating this file via `configlet sync` will:
4+ # - Recreate every `description` key/value pair
5+ # - Recreate every `reimplements` key/value pair, where they exist in problem-specifications
6+ # - Remove any `include = true` key/value pair (an omitted `include` key implies inclusion)
7+ # - Preserve any other key/value pair
8+ #
9+ # As user-added comments (using the # character) will be removed when this file
10+ # is regenerated, comments can be added via a `comment` key.
411
512[6eff0df4-3e92-478d-9b54-d3e8b354db56 ]
613description = " an empty board has no winner"
@@ -23,6 +30,12 @@ description = "nobody wins crossing adjacent angles"
2330[cd61c143-92f6-4a8d-84d9-cb2b359e226b ]
2431description = " X wins crossing from left to right"
2532
33+ [495e33ed-30a9-4012-b46e-d7c4d5fe13c3 ]
34+ description = " X wins with left-hand dead end fork"
35+
36+ [ab167ab0-4a98-4d0f-a1c0-e1cddddc3d58 ]
37+ description = " X wins with right-hand dead end fork"
38+
2639[73d1eda6-16ab-4460-9904-b5f5dd401d0b ]
2740description = " O wins crossing from top to bottom"
2841
Original file line number Diff line number Diff line change @@ -111,6 +111,36 @@ public function testXWinsCrossingFromLeftToRight(): void
111111 $ this ->assertEquals ("black " , winner ($ lines ));
112112 }
113113
114+ /**
115+ * uuid 495e33ed-30a9-4012-b46e-d7c4d5fe13c3
116+ */
117+ #[TestDox('X wins with left-hand dead end fork ' )]
118+ public function testXWinsWithLeftHandDeadEndFork (): void
119+ {
120+ $ lines = [
121+ ". . X . " ,
122+ " X X . . " ,
123+ " . X X X " ,
124+ " O O O O " ,
125+ ];
126+ $ this ->assertEquals ("black " , winner ($ lines ));
127+ }
128+
129+ /**
130+ * uuid ab167ab0-4a98-4d0f-a1c0-e1cddddc3d58
131+ */
132+ #[TestDox('X wins with right-hand dead end fork ' )]
133+ public function testXWinsWithRightHandDeadEndFork (): void
134+ {
135+ $ lines = [
136+ ". . X X " ,
137+ " X X . . " ,
138+ " . X X . " ,
139+ " O O O O " ,
140+ ];
141+ $ this ->assertEquals ("black " , winner ($ lines ));
142+ }
143+
114144 /**
115145 * uuid 73d1eda6-16ab-4460-9904-b5f5dd401d0b
116146 */
You can’t perform that action at this time.
0 commit comments