Android Back Navigation ParentActivityName not working
<p>i tried using this tutorial on how to provide a back navigation as in this code</p>

<p><a href="https://developer.android.com/training/implementing-navigation/temporal.html" rel="nofollow">https://developer.android.com/training/implementing-navigation/temporal.html</a></p>

<pre><code> &lt;activity android:name=".controller.general.AccountPickerScreen"
              android:parentActivityName="ph.edu.upm.agila.extendthelife.controller.general.LogInScreen"&gt;
        &lt;intent-filter&gt;
            &lt;action android:name="ph.edu.upm.agila.extendthelife.controller.general.AccountPickerScreen" /&gt;

            &lt;category android:name="android.intent.category.DEFAULT" /&gt;
        &lt;/intent-filter&gt;
</code></pre>

<p>I already specificied the parentActivityName but whenever I press the back button the app exits? any solutions?</p>

<p>tried this        </p>

<pre><code>public void onBackPressed() {
     Intent intent = NavUtils.getParentActivityIntent(AccountPickerScreen.this);
    startActivity(intent);
    finish();
}
</code></pre>

<p>it does work however i want to know if it is the right way of doing it? 
what does finish() do exactly</p>