CSS CSS Selectors Advanced Selectors :nth Pseudo-Class Challenge

inside the media query. target images and float left?

Not sure what I'm typing in wrong. I looked at both the hints.

style.css
/* Write the CSS in the media query below */

@media (min-width: 607px) {
  .img {
  float: left;
}
}
index.html
<!DOCTYPE html>
<html>
<head>
    <title>Selectors</title>
  <meta name="viewport" content="width=device-width, initial-scale=1">
  <link rel="stylesheet" href="page.css">
  <link rel="stylesheet" href="style.css">
</head>
<body>
    <img src="thumb-forest.jpg" alt="">
    <img src="thumb-resort.jpg" alt="">
    <img src="thumb-trees.jpg" alt="">
    <img src="thumb-falls.jpg" alt="">
    <img src="thumb-view.jpg" alt="">
    <img src="thumb-sunset.jpg" alt="">
    <img src="thumb-lake.jpg" alt="">
    <img src="thumb-beach.jpg" alt="">
    <img src="thumb-bay.jpg" alt="">
    <img src="thumb-peaks.jpg" alt="">
    <img src="thumb-falls.jpg" alt="">
    <img src="thumb-resort.jpg" alt="">
</body>
</html>

1 Answer

img isn't a class so it won't be preceded by a period

Brandon Williams
Brandon Williams
6,678 Points

This. I was using a period before the img and couldn't get it to work.

@media (min-width: 607px) {
  img {
    float:left;
  }
}