Android: Clear the back stack
问题 In Android I have some activities, let\'s say A, B, C. In A, I use this code to open B: Intent intent = new Intent(this, B.class); startActivity(intent); In B, I use this code to open C: Intent intent = new Intent(this, C.class); startActivity(intent); When the user taps a button in C, I want to go back to A and clear the back stack (close both B and C). So when the user use the back button B and C will not show up, I\'ve been trying the following: Intent intent = new Intent(this, A.class);