Test your skills: Multicol

The aim of this skill test is to assess whether you understand CSS multiple-column layout, including the column-count, column-width, column-gap, column-span and column-rule properties and values. You will be working through three small tasks that use different elements of the material you have just covered.

Note: You can try solutions in the interactive editors on this page or in an online editor such as CodePen, JSFiddle, or Glitch.

If you get stuck, you can reach out to us in one of our communication channels.

Task 1

In this task, we want you to create three columns, with a 50px gap between each column.

Your final result should look like the image below:

Three columns of text

Try updating the live code below to recreate the finished example:

Download the starting point for this task to work in your own editor or in an online editor.

Task 2

In this task, we want you to create columns which have a minimum width of 200px. Then, add a 5px grey rule between each column, ensuring there is 10px of space between the edge of the rule and the column content.

Your final result should look like the image below:

Three columns of text with a grey rule between them.

Try updating the live code below to recreate the finished example:

Download the starting point for this task to work in your own editor or in an online editor.

Task 3

In this task, we want you to cause the element containing the heading and subheading to span across all columns so it looks like the image below:

Three columns of text with a heading and subheading spanning all three in the middle.

Try updating the live code below to recreate the finished example:

Download the starting point for this task to work in your own editor or in an online editor.