Tell us what’s happening:
The code works. But I have a question not answered in the lesson.
Describe your issue in detail here.
My issue is I am learning how to use the repeat function with the grid-template-columns command which looks something like this…
grid-template-columns: repeat(100, 1fr);
What I don’t understand is how do I generation 100 of the items, item1-item100, without specifically doing it long hand a 100 times.
**Your code so far**
<style>
.item1{background:LightSkyBlue;}
.item2{background:LightSalmon;}
.item3{background:PaleTurquoise;}
.item4{background:LightPink;}
.item5{background:PaleGreen;}
.container {
font-size: 40px;
min-height: 300px;
width: 100%;
background: LightGray;
display: grid;
/* Only change code below this line */
grid-template-columns: repeat(100, 1fr);
/* Only change code above this line */
grid-template-rows: 1fr 1fr 1fr;
grid-gap: 10px;
}
</style>
<div class="container">
<div class="item1">1</div>
<div class="item2">2</div>
<div class="item3">3</div>
<div class="item4">4</div>
<div class="item5">5</div>
</div>
**Your browser information:**
User Agent is: Mozilla/5.0 (X11; CrOS x86_64 14388.61.0) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/98.0.4758.107 Safari/537.36
Challenge: Reduce Repetition Using the repeat Function
Link to the challenge: