Chapter 29, page 699, in MapViewController.swift file, func region(for annotations: )

This part of code a little discouraged me

let center = CLLocationCoordinate2D(
latitude: topLeft.latitude -
(topLeft.latitude - bottomRight.latitude) / 2,
longitude: topLeft.longitude - //////this
(topLeft.longitude - bottomRight.longitude) / 2) //////and this line

a think better if…
let center = CLLocationCoordinate2D(
latitude: topLeft.latitude -
(topLeft.latitude - bottomRight.latitude) / 2,
longitude: topLeft.longitude +
( bottomRight.longitude - topLeft.longitude) / 2)

… better for understanding

@tskho Thank you for sharing your solution - much appreciated! :]

This topic was automatically closed after 166 days. New replies are no longer allowed.