title: Object reference count is different in swift and objective c
body: <p><strong>Swift Code</strong></p>
  
  <pre><code> override func viewDidLoad() {
              super.viewDidLoad()
              var v1 = ViewController()
              let v2 = ViewController2()
              print("\(CFGetRetainCount(v1)) and \(CFGetRetainCount(v2))")
          }
  </code></pre>
  
  <blockquote>
    <p>In Swift reference count printing <strong>as 2 and 2</strong></p>
  </blockquote>
  
  <p><strong>Objective C Code</strong></p>
  
  <pre><code>- (void)viewDidLoad {
      [super viewDidLoad];
      ViewController *v1 = [[ViewController alloc]init];
      ViewController2 *v2 = [[ViewController2 alloc]init];
      NSLog(@"%ld and %ld",CFGetRetainCount((__bridge CFTypeRef)(v1)),CFGetRetainCount((__bridge CFTypeRef)(v2)));
  } 
  </code></pre>
  
  <blockquote>
    <p>In Objective C reference count printing as 1 and 1</p>
  </blockquote>
  
  <p>Why reference counts are different in <strong>objective c</strong> and <strong>swift</strong> ?</p>