Welcome to the Treehouse Community

Want to collaborate on code errors? Have bugs you need feedback on? Looking for an extra set of eyes on your latest project? Get support with fellow developers, designers, and programmers of all backgrounds and skill levels here with the Treehouse Community! While you're at it, check out some resources Treehouse students have shared here.

Looking to learn something new?

Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and join thousands of Treehouse students and alumni in the community today.

Start your free trial

CSS Sass Basics Write Smart and Efficient CSS with Sass Create a Function for Flexbox Layout

Why does it make sense to multiply the number of items by the gutter value,as if they are linearly dependent?

.

1 Answer

Steven Parker
Steven Parker
231,268 Points

There's gutter space around each of the items, so the total space taken up by the gutters is the space of one multiplied by the number of items.

.

Steven Parker
Steven Parker
231,268 Points

The video example uses $gutter to represent one side, then converts it to percent and multiplies it by 2 to get $g-pct which represents both sides. That's the value that is multiplied by $items.