Even spacing inside a card in HTML & CSS

HTML & CSS interview exercise on Box model & units, difficulty 2 of 3. Solve it in the editor beside a worked example; the tests run the moment you do.

The card has 24px of padding. Paragraphs should be 16px apart, and the first paragraph must start exactly at the padding edge with no extra gap, the last must end exactly at it: the browser's default paragraph margins are getting in the way.

Each exercise pairs a worked example with a twin problem to solve in a real editor; the tests run the moment you do. Progress is saved in your browser, and in your account if you sign in.

More Box model & units in HTML & CSS

All HTML & CSS exercises · Other languages and frameworks