I spent hours struggling with level 77 of Coding Fantasy: Grid Attack. No matter what I tried, nothing seemed to work. There are no solutions provided in the game, and there's no way to skip the level. Can anyone help me with the solution please? 😢
The challenge is to fit the red land into the red border shown in the image below using grid-auto-rows, align-content, and span.
CSS
#field {
display: grid;
grid-template-columns: repeat(auto-fill, 1fr);
/* add your code here */
}
#field div:nth-child(3n) {
/* add your code here */
}
HTML
<div id="field">
<div class="greenLand"></div>
<div class="redLand"></div>
<div class="greenLand"></div>
<div class="redLand"></div>
<div class="greenLand"></div>
<div class="redLand"></div>
</div>
I've experimented with various values but haven't been successful yet.