title: Android Studio go back to Main Activity
body: <p>I am trying to develop a puzzle game. Each activity has an image and four buttons as answer. I want when user click on wrong answer message appears and after that go back to main activity.</p>
  
  <p>My code is:</p>
  
  <p><code>public void mess1(View view) {
          Toast.makeText(this, "Sorry! Better Luck Next Time", Toast.LENGTH_SHORT).show();
          Toast.makeText(this, "You Won Nothing", Toast.LENGTH_LONG).show();
          managerOfSound(y);
          Intent i = new Intent(this, MainActivity.class);
          startActivity(i);
      }</code></p>
  
  <p>But after clicking Toast and sound work but MainActivity doesn't start.
  Please help me, what is wrong with the code?</p>