title: Search for a value in html with swift
body: <p>I started with an easy project to learn more about swift and Xcode.
  So i started with project where I'd like to find a certain value on an website. I retrieved the html code so far but now I'd like to narrow it down to the value I'd like to see.</p>
  
  <p>In this html i'd like to write the 9,62 into a variable. So I think I have to find the class, span and the text. What I found so far are tutorials to work with an html file...but that didn't help me with the code I have written so far as I don't want to store the html in a file.</p>
  
  <pre><code>    &lt;/div&gt;&lt;/div&gt;&lt;div class="My(6px) Pos(r) smartphone_Mt(6px)" 
      data-reactid="18"&gt;&lt;div class="" data-reactid="19"&gt;&lt;span 
      class="Trsdu(0.3s) Trsdu(0.3s) Fw(b) Fz(36px) Mb(-4px) D(b)" 
      data-reactid="20"&gt;9.62&lt;/span&gt;
  </code></pre>
  
  <p>This is the code i have done so far:</p>
  
  <pre><code>import UIKit
  import SwiftSoup
  
  class ViewController: UIViewController {
  
      override func viewDidLoad() {
          super.viewDidLoad()
  
          let html = URL(string: "https://finance.yahoo.com/quote/LEO.DE?p=LEO.DE.tsrc=fin-srch")
          let task = URLSession.shared.dataTask(with: html!) {(data, response, error) in
              if error != nil {
                  print(error)
              } else {
                  let html = NSString(data: data!, encoding: String.Encoding.utf8.rawValue)
                  print(html)
              }
          }
          task.resume()
      }
  }
  </code></pre>