How to get the UIButton ID?
<p>I have created 5 buttons dynamically in Swift like this:</p>

<pre><code>for theIndex in 0..&lt;5 {

        let aButton = UIButton()
        aButton.frame = CGRectMake(self.view.bounds.width / 2 - 120, self.view.bounds.height / 2 - 150, 240, 300)
        aButton.setTitle("Button \(theIndex)", forState: .Normal)
        aButton.addTarget(self, action: "btnClicked:", forControlEvents:.TouchUpInside)

        self.view.addSubview(aButton) 
    }
</code></pre>

<p>But how can I get the <strong>BUTTON_ID</strong> for each one?</p>

<pre><code> func btnClicked(sender: AnyObject?) {
        let vc = storyboard!.instantiateViewControllerWithIdentifier("vc_name") as! DetailVC
        vc.selectedId = **WANT_TO_PASS_BUTTON_ID_HERE**
        self.presentViewController(vc, animated:true, completion:nil)
    }
</code></pre>