title: How to center vertically UIImage inside parent view programmatically using CGRect?
body: <p>I tried to do this one but, the place of the Image changes when I try to run on a different iPhone model in Simulator. I need to do this exactly with CGRect. Thanks in Advance!</p>
  <pre><code>    func configure() {
          //MARK: Logo Image
          view.addSubview(logo)
          logo.image = UIImage(named: &quot;cafelogo&quot;)
          logo.layer.cornerRadius = 25
          logo.frame = CGRect(x: 100, y: 200, width: 150, height: 150)
  </code></pre>