thecodezone.
The Code Zone

CSS / FLOATS PRACTICE · STEP 1 OF 6

Wrap a study-club newsletter

GUIDED PRACTICE

Wrap a study-club newsletter

Open styles.css for this step. Follow the checklist, keeping your earlier work. If a named comment is missing from an older saved draft, add it without deleting your work. Keep index.html unchanged during this step.

Your code stays in one editor through every step. Word wrap is enabled.

Step 1 of 6

Let the first paragraph wrap

A float moves the image to one side and lets following text wrap alongside it. Ordinary images start inline; their size can still make a line look full. We will size the first photo before floating it.

Your task

Open styles.css for this step. Follow the checklist, keeping your earlier work. If a named comment is missing from an older saved draft, add it without deleting your work. Keep index.html unchanged during this step.

To pass this step:

  • In styles.css, add a rule with selector .intro-photo outside all media blocks, directly below the STYLE CLASS INTRO PHOTO comment.
  • Set its width property to 160px.
  • Set its float property to left.
  • Look for the first paragraph alongside the photo, on its right.

Press the play button labeled Run & check this step below the editor to run your code and see your check results.

A hint for this step

A declaration goes inside the selector’s braces. Here is one focused rule from this step: ``css .intro-photo { width: 160px; float: left; }

Your editor is opening.

Each step builds on the last. Finish the current step before opening the next one; your code stays with you.

Code and completed steps save in this browser when signed out. Sign in to save across devices.

Resources for this step

Looking things up is part of programming. Compare these explanations with the task, then return and try the idea in your own code.

Ready to checkRun the checks to see your results here.

Replace your editor code?

Your current work will be replaced. Choose Cancel to keep it.