title: Python BeautifulSoup select div class
body: <p>I am scraping an HTML like this</p>
  <pre><code>&lt;div class=&quot;col-16 text&quot;&gt; ... &lt;/div&gt;
  &lt;div class=&quot;col-16 image&quot;&gt; ... &lt;/div&gt;
  &lt;div class=&quot;col-16&quot;&gt; ... &lt;/div&gt;
  &lt;div class=&quot;col-16 text&quot;&gt; ... &lt;/div&gt;
  &lt;div class=&quot;col-16 image&quot;&gt; ... &lt;/div&gt;
  &lt;div class=&quot;col-16&quot;&gt; ... &lt;/div&gt;
  </code></pre>
  <p>I am using this</p>
  <pre><code>soup_object.find_all(&quot;div&quot;, {&quot;class&quot;: &quot;col-xs-12&quot;})
  </code></pre>
  <p>I want only a div with a class &quot;col-16&quot;, but it is returning all the divs.</p>
  <p>How can I select only a div class with &quot;col-16&quot;?</p>
  <p><strong>Edit</strong></p>
  <p>I want to get this</p>
  <pre><code>&lt;div class=&quot;col-16&quot;&gt; ... &lt;/div&gt;
  &lt;div class=&quot;col-16&quot;&gt; ... &lt;/div&gt;
  </code></pre>
  <p>But I am  getting this</p>
  <pre><code>&lt;div class=&quot;col-16 text&quot;&gt; ... &lt;/div&gt;
  &lt;div class=&quot;col-16 image&quot;&gt; ... &lt;/div&gt;
  &lt;div class=&quot;col-16&quot;&gt; ... &lt;/div&gt;
  &lt;div class=&quot;col-16 text&quot;&gt; ... &lt;/div&gt;
  &lt;div class=&quot;col-16 image&quot;&gt; ... &lt;/div&gt;
  &lt;div class=&quot;col-16&quot;&gt; ... &lt;/div&gt;
  </code></pre>