title: Using Annotations In Swift - .addAnnotation() Not Working
body: <p>I am using the <code>MapKit</code> and I am receiving the following error: </p>
  
  <p><a href="https://i.stack.imgur.com/D5Uk6.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/D5Uk6.png" alt="enter image description here"></a></p>
  
  <p>The <code>locations.count?</code>  is not working even when I am putting that in as the argument. It says that it doesn't allow <code>Int</code> as a parameter. I'm not too sure why this isn't working.</p>
  
  <pre><code>import UIKit
  import MapKit
  
  class MapViewController: UIViewController, MKMapViewDelegate {
  
      @IBOutlet weak var myMapView: MKMapView!
  
      override func viewDidLoad() {
          super.viewDidLoad()
  
          let italy = MKPointAnnotation()
          italy.coordinate = CLLocationCoordinate2D(latitude: 41.8947400, longitude: 12.4839000)
          italy.title = "Rome, Italy"
  
          let england = MKPointAnnotation()
          england.coordinate = CLLocationCoordinate2D(latitude: 51.5085300, longitude: -0.1257400)
          england.title = "London, England"
  
          let norway = MKPointAnnotation()
          norway.coordinate = CLLocationCoordinate2D(latitude: 59.914225, longitude: 10.75256)
          norway.title = "Oslo, Norway"
  
          let spain = MKPointAnnotation()
          spain.coordinate = CLLocationCoordinate2D(latitude: 40.41694, longitude: -3.70081)
          spain.title = "Madrid, Spain"
  
          let locations = [italy, england, norway, spain]
  
          myMapView.addAnnotation(locations)
      }
  
      func mapView(mapView: MKMapView, viewForAnnotation annotation: MKAnnotation) -&gt; MKAnnotationView? {
          let pin = MKPinAnnotationView(annotation: annotation, reuseIdentifier: "pinIdentifier")
          pin.canShowCallout = true
          return pin
      }
  }
  </code></pre>