title: Error:(26, 24) error: incompatible types: class cannot be converted to Fragment
body: <p>I'm trying to do a Menu app in Android through fragments</p>
  
  <p>All the classes I'm sending extend from a Fragment and that's what the array fragment it's asking me but still say is not.</p>
  
  <p><img src="https://i.stack.imgur.com/iMFYl.png" alt="enter image description here"></p>
  
  <pre><code>import android.app.Fragment;
  import android.app.FragmentManager;
  import android.app.FragmentTransaction;
  import android.support.v7.app.AppCompatActivity;
  import android.os.Bundle;
  
  public class  Actividades extends AppCompatActivity implements InterfaceMenu {
  
      //Array para menu y fragments
  
      Fragment[] array_frag;
  
      @Override
      protected void onCreate(Bundle savedInstanceState) {
          super.onCreate(savedInstanceState);
          setContentView(R.layout.activity_actividades);
  
          //Obtener del menu el boton pulsado
          Bundle extras=getIntent().getExtras();
          menu(extras.getInt("BotonPulsado"));
  
  
          array_frag = new Fragment[3];
          array_frag[0]= new Lintern();
          array_frag[1]= new Nivel();
          array_frag[2]= new Service();
      }
  
  
      @Override
      public void menu(int frag_boton) {
  
          //obtener fragmentmanager y empezar transaccion
          FragmentManager mimanager = getFragmentManager();
          FragmentTransaction mitransaction = mimanager.beginTransaction();
          //mandamos el id de donde se van a
          // cargar los fragments y que fragment vamos a mandar
          mitransaction.replace(R.id.actividades,array_frag[frag_boton]);
          mitransaction.commit();
      }
  }
  </code></pre>
  
  <p>Here it's one of my classes they are all empty just like this</p>
  
  <pre><code>import android.os.Bundle;
  import android.support.v4.app.Fragment;
  import android.view.LayoutInflater;
  import android.view.View;
  import android.view.ViewGroup;
  
  
  /**
   * A simple {@link Fragment} subclass.
   */
  public class Lintern extends Fragment {
  
  
      public Lintern() {
          // Required empty public constructor
      }
  
  
      @Override
      public View onCreateView(LayoutInflater inflater, ViewGroup container,
                               Bundle savedInstanceState) {
          // Inflate the layout for this fragment
          return inflater.inflate(R.layout.fragment_lintern, container, false);
      }
  
  }
  </code></pre>