Segundo parcial

Proy01_Lista_de_Invitados 
<LinearLayout
    xmlns:android="http://schemas.android.com/apk/res/android"
    android:orientation="vertical"
    android:layout_width="match_parent"
    android:layout_height="match_parent"
    android:background="@android:color/darker_gray">
    <TextView
        android:text="Lista de Invitados"
        android:layout_width="wrap_content"
        android:layout_height="wrap_content"
        android:background="#4CAF50"
        android:textSize="24sp"/>
    <TextView
        android:text="Oswaldo"
        android:layout_width="match_parent"
        android:layout_height="wrap_content"
        android:background="#4CAF50"
        android:textSize="24sp"/>

    <TextView
        android:layout_width="wrap_content"
        android:layout_height="wrap_content"
        android:background="#4CAF50"
        android:text="Axel"
        android:textSize="24sp" />
    <TextView
        android:text="Elian"
        android:layout_width="wrap_content"
        android:layout_height="wrap_content"
        android:background="#4CAF50"
        android:textSize="24sp"/>

</LinearLayout>

Proy02_Lista_de_Invitados
<LinearLayout
    xmlns:android="http://schemas.android.com/apk/res/android"
    android:orientation="vertical"
    android:layout_width="match_parent"
    android:layout_height="match_parent"
    android:background="@android:color/darker_gray">
    <TextView
        android:text="Lista de Invitados"
        android:layout_width="match_parent"
        android:layout_height="wrap_content"
        android:background="#4CAF50"
        android:textSize="24sp"
        android:layout_weight="1"/>

    <TextView
        android:text="Oswaldo"
        android:layout_width="match_parent"
        android:layout_height="wrap_content"
        android:background="#4CAF50"
        android:textSize="24sp"
        android:layout_weight="1"/>
    <TextView
        android:text="Axel"
        android:layout_width="match_parent"
        android:layout_height="50dp"
        android:background="#4CAF50"
        android:textSize="24sp"
        android:layout_weight="1"/>
    <TextView
        android:text="Elian"
        android:layout_width="match_parent"
        android:layout_height="wrap_content"
        android:background="#4CAF50"
        android:textSize="24sp"
        android:layout_weight="1"/>

</LinearLayout>

Proy03_Insertar_Imagen
<LinearLayout
    xmlns:android="http://schemas.android.com/apk/res/android"
    android:orientation="vertical"
    android:layout_width="match_parent"
    android:layout_height="match_parent">
    <ImageView
        android:src="@drawable/jaja"
        android:layout_width="wrap_content"
        android:layout_height="wrap_content"
        android:layout_weight="1"
        android:scaleType="centerCrop"/>

    <TextView
        android:layout_width="match_parent"
        android:layout_height="wrap_content"
        android:layout_weight=""
        android:background="#009688"
        android:text="You're invited!"
        android:textColor="@android:color/white"
        android:textSize="54sp" />
    <TextView
        android:text="Bonfire at the beach"
        android:layout_width="wrap_content"
        android:layout_height="wrap_content"
        android:layout_weight="0"
        android:textColor="@android:color/white"
        android:textSize="34sp"
        android:background="#009688"/>

</LinearLayout>

Proy04_Relative_Layout
<RelativeLayout
    xmlns:android="http://schemas.android.com/apk/res/android"
    android:layout_width="match_parent"
    android:layout_height="match_parent"
    android:padding="16dp">
    <TextView
        android:text="I'm in this corner"
        android:layout_width="wrap_content"
        android:layout_height="wrap_content"
        android:layout_alignParentBottom="true"
        android:layout_alignParentLeft="true"/>
    <TextView
        android:text="No, up here"
        android:layout_width="wrap_content"
        android:layout_height="wrap_content"
        android:layout_alignParentTop="true"
        android:layout_alignParentLeft="true"/>
    <TextView
        android:text="Wait, I'm here"
        android:layout_width="wrap_content"
        android:layout_height="wrap_content"
        android:layout_alignParentBottom="true"
        android:layout_alignParentRight="true"/>
    <TextView
        android:text="Actually, I'm here"
        android:layout_width="wrap_content"
        android:layout_height="wrap_content"
        android:layout_alignParentTop="true"
        android:layout_alignParentRight="true"/>

</RelativeLayout>

Proy05_Relative_Layout
<RelativeLayout
    xmlns:android="http://schemas.android.com/apk/res/android"
    android:layout_width="match_parent"
    android:layout_height="match_parent">
    <TextView
        android:id="@+id/lyla_text_view"
        android:layout_width="wrap_content"
        android:layout_height="wrap_content"
        android:layout_alignParentBottom="true"
        android:layout_alignParentLeft="true"
        android:textSize="24sp"
        android:text="Lyla"/>
    <TextView
        android:id="@+id/me_text_view"
        android:layout_width="wrap_content"
        android:layout_height="wrap_content"
        android:layout_alignParentBottom="true"
        android:layout_toRightOf="@+id/lyla_text_view"
        android:textSize="24sp"
        android:text="Me" />
    <TextView
        android:id="@+id/natalie_text_view"
        android:layout_width="wrap_content"
        android:layout_height="wrap_content"
        android:textSize="24sp"
        android:text="Natalie"/>
    <TextView
        android:id="@+id/jennie_text_view"
        android:layout_width="wrap_content"
        android:layout_height="wrap_content"
        android:layout_alignParentBottom="true"
        android:layout_alignParentRight="true"
        android:text="Jennie"
        android:textSize="24sp"/>
    <TextView
        android:id="@+id/amy_text_view"
        android:layout_width="wrap_content"
        android:layout_height="wrap_content"
        android:layout_alignParentBottom="true"
        android:layout_toLeftOf="@id/jennie_text_view"
        android:text="Amy"
        android:textSize="24sp"/>
    <TextView
        android:id="@+id/ben_text_view"
        android:layout_width="wrap_content"
        android:layout_height="wrap_content"
        android:layout_alignParentTop="true"
        android:layout_centerInParent="true"
        android:text="Ben"
        android:textSize="24sp"/>
    <TextView
        android:id="@+id/kunal_text_view"
        android:layout_width="wrap_content"
        android:layout_height="wrap_content"
        android:layout_alignParentTop="true"
        android:layout_toLeftOf="@id/ben_text_view"
        android:text="Kunal"
        android:textSize="24sp"/>
    <TextView
        android:id="@+id/kagure_text_view"
        android:layout_width="wrap_content"
        android:layout_height="wrap_content"
        android:layout_alignParentTop="true"
        android:layout_alignParentRight="true"
        android:text="Kagure"
        android:textSize="24sp"/>
    <TextView
        android:id="@+id/omoju_text_view"
        android:layout_width="wrap_content"
        android:layout_height="wrap_content"
        android:layout_alignStart="@id/jennie_text_view"
        android:layout_above="@id/jennie_text_view"
        android:text="Omoju"
        android:textSize="24sp"
        />

</RelativeLayout>

Proy06_imagen:  Utilizando el siguiente código genera la invitación según se muestra

<LinearLayout
    xmlns:android="http://schemas.android.com/apk/res/android"
    android:orientation="vertical"
    android:layout_width="match_parent"
    android:layout_height="match_parent">
    <ImageView
        android:id="@+id/photo"
        android:src="@drawable/jaja"
        android:layout_width="56dp"
        android:layout_height="56dp"
        android:scaleType="centerCrop"/>

    <TextView
        android:layout_width="wrap_content"
        android:layout_height="wrap_content"
        android:text="pebble beach"

        android:layout_alingParentTop="true"
        android:layout_alingParentLeft="true"
        android:layout_toLeftOf="@id/photo"

        android:textAppearance="?android:textAppearanceMedium"/>

    <TextView
        android:layout_width="wrap_content"
        android:layout_height="wrap_content"
        android:text="California"
        android:textAppearance="?android:textAppearanceSmall"/>

        android:textColor="@android:color/white"
        android:textSize="34sp" />
    <TextView
        android:layout_width="wrap_content"
        android:layout_height="wrap_content"
        android:text="10 miles away"
        android:textAppearance="?android:textAppearanceSmall"/>

    android:textColor="@android:color/white"
    android:textSize="34sp" />

</LinearLayout>

Actividad 02: “Scrollview en Android”
<?xml version="1.0" encoding="utf-8"?>
<android.support.constraint.ConstraintLayout
    xmlns:android="http://schemas.android.com/apk/res/android"
    xmlns:tools="http://schemas.android.com/tools"
    xmlns:app="http://schemas.android.com/apk/res-auto"
    android:layout_width="match_parent"
    android:layout_height="match_parent"
    tools:context="com.example.lap_c_pc38.myapplication2.MainActivity">

    <LinearLayout
        android:layout_width="match_parent"
        android:layout_height="match_parent"
        android:orientation="vertical">

        <ScrollView
            android:layout_width="match_parent"
            android:layout_height="match_parent"
            android:layout_weight="1">

            <LinearLayout
                android:layout_width="match_parent"
                android:layout_height="wrap_content"
                android:orientation="vertical">

                <Button
                    android:id="@+id/button74"
                    android:layout_width="match_parent"
                    android:layout_height="wrap_content"
                    android:text="Button" />

                <Button
                    android:id="@+id/button81"
                    android:layout_width="match_parent"
                    android:layout_height="wrap_content"
                    android:text="Button" />

                <Button
                    android:id="@+id/button80"
                    android:layout_width="match_parent"
                    android:layout_height="wrap_content"
                    android:text="Button" />

                <Button
                    android:id="@+id/button79"
                    android:layout_width="match_parent"
                    android:layout_height="wrap_content"
                    android:text="Button" />

                <Button
                    android:id="@+id/button78"
                    android:layout_width="match_parent"
                    android:layout_height="wrap_content"
                    android:text="Button" />

                <Button
                    android:id="@+id/button77"
                    android:layout_width="match_parent"
                    android:layout_height="wrap_content"
                    android:text="Button" />

                <Button
                    android:id="@+id/button76"
                    android:layout_width="match_parent"
                    android:layout_height="wrap_content"
                    android:text="Button" />

                <Button
                    android:id="@+id/button75"
                    android:layout_width="match_parent"
                    android:layout_height="wrap_content"
                    android:text="Button" />

                <Button
                    android:id="@+id/button72"
                    android:layout_width="match_parent"
                    android:layout_height="wrap_content"
                    android:text="Button" />
            </LinearLayout>
        </ScrollView>

        <HorizontalScrollView
            android:layout_width="match_parent"
            android:layout_height="match_parent"
            android:layout_weight="1">

            <LinearLayout
                android:layout_width="wrap_content"
                android:layout_height="match_parent"
                android:orientation="horizontal">

                <Button
                    android:id="@+id/button109"
                    android:layout_width="match_parent"
                    android:layout_height="match_parent"
                    android:layout_weight="1"
                    android:text="Button" />

                <Button
                    android:id="@+id/button122"
                    android:layout_width="match_parent"
                    android:layout_height="match_parent"
                    android:layout_weight="1"
                    android:text="Button" />

                <Button
                    android:id="@+id/button121"
                    android:layout_width="match_parent"
                    android:layout_height="match_parent"
                    android:layout_weight="1"
                    android:text="Button" />

                <Button
                    android:id="@+id/button120"
                    android:layout_width="match_parent"
                    android:layout_height="match_parent"
                    android:layout_weight="1"
                    android:text="Button" />

                <Button
                    android:id="@+id/button119"
                    android:layout_width="match_parent"
                    android:layout_height="match_parent"
                    android:layout_weight="1"
                    android:text="Button" />

                <Button
                    android:id="@+id/button118"
                    android:layout_width="match_parent"
                    android:layout_height="match_parent"
                    android:layout_weight="1"
                    android:text="Button" />

                <Button
                    android:id="@+id/button117"
                    android:layout_width="match_parent"
                    android:layout_height="match_parent"
                    android:layout_weight="1"
                    android:text="Button" />

                <Button
                    android:id="@+id/button110"
                    android:layout_width="match_parent"
                    android:layout_height="match_parent"
                    android:layout_weight="1"
                    android:text="Button" />

                <Button
                    android:id="@+id/button111"
                    android:layout_width="match_parent"
                    android:layout_height="match_parent"
                    android:layout_weight="1"
                    android:text="Button" />

                <Button
                    android:id="@+id/button112"
                    android:layout_width="match_parent"
                    android:layout_height="match_parent"
                    android:layout_weight="1"
                    android:text="Button" />


            </LinearLayout>

        </HorizontalScrollView>

    </LinearLayout>
</android.support.constraint.ConstraintLayout>

Conclusión:
Aprendí que hay muchas maneras de acomodar todos los objetos que necesitan, ademas de hacer un scroll view

Actividad 03: “Constraintlayout en Android”
<ImageView
    android:id="@+id/imageView"
    android:layout_width="125dp"
    android:layout_height="124dp"
    app:srcCompat="@drawable/dgeti"
    tools:layout_editor_absoluteX="16dp"
    tools:layout_editor_absoluteY="26dp" />
<TextView
    android:id="@+id/textView"
    android:layout_width="140dp"
    android:layout_height="40dp"
    android:layout_marginBottom="64dp"
    android:text="Bienvenidos"
    android:textSize="24sp"
    app:layout_constrai_absoluteX="179dp" />
<TextView
    android:id="@+id/textView2"
    android:layout_width="wrap_content"
    android:layout_height="25dp"
    android:layout_marginTop="8dp"
    android:text="A la programacion "
    android:textSize="18sp"
    app:layout_constraintTop_toBottomOf="@+id/imageView"
    tools:layout_editor_absoluteX="28dp" />
<TextView
    android:id="@+id/textView3"
    android:layout_width="wrap_content"
    android:layout_height="wrap_content"
    android:layout_marginBottom="12dp"
    android:text="Con Android"
    android:textSize="18sp"
    app:layout_constraintBottom_toTopOf="@+id/textView4"
    tools:layout_editor_absoluteX="242dp" />
<TextView
    android:id="@+id/textView4"
    android:layout_width="wrap_content"
    android:layout_height="wrap_content"
    android:layout_marginBottom="28dp"
    android:layout_marginEnd="8dp"
    android:layout_marginStart="8dp"
    android:text="Estudiante De Bachillerato"
    android:textSize="18sp"
    app:layout_constraintBottom_toTopOf="@+id/textView5"
    app:layout_constraintEnd_toEndOf="parent"
    app:layout_constraintStart_toStartOf="parent" />
<TextView
    android:id="@+id/textView5"
    android:layout_width="wrap_content"
    android:layout_height="wrap_content"
    android:layout_marginBottom="20dp"
    android:layout_marginEnd="8dp"
    android:layout_marginStart="8dp"
    android:text="Un Mundo fantastico te espera"
    android:textSize="18sp"
    app:layout_constraintBottom_toTopOf="@+id/textView6"
    app:layout_constraintEnd_toEndOf="parent"
    app:layout_constraintStart_toStartOf="parent" />
<TextView
    android:id="@+id/textView6"
    android:layout_width="wrap_content"
    android:layout_height="wrap_content"
    android:layout_marginEnd="8dp"
    android:layout_marginStart="8dp"
    android:text="Con Android"
    android:textSize="18sp"
    app:layout_constraintEnd_toEndOf="parent"
    app:layout_constraintHorizontal_bias="0.501"
    app:layout_constraintStart_toStartOf="parent"
    tools:layout_editor_absoluteY="290dp" />
<TextView
    android:id="@+id/textView7"
    android:layout_width="wrap_content"
    android:layout_height="wrap_content"
    android:layout_marginEnd="8dp"
    android:layout_marginStart="8dp"
    android:text="¿Estas Preparado?"
    android:textSize="18sp"
    app:layout_constraintEnd_toEndOf="parent"
    app:layout_constraintHorizontal_bias="0.502"
    app:layout_constraintStart_toStartOf="parent"
    tools:layout_editor_absoluteY="343dp" />
<Button
    android:id="@+id/button2"
    android:layout_width="wrap_content"
    android:layout_height="wrap_content"
    android:layout_marginEnd="8dp"
    android:layout_marginStart="8dp"
    android:text="Off"
    app:layout_constraintEnd_toEndOf="parent"
    app:layout_constraintStart_toStartOf="parent"
    app:layout_constraintTop_toBottomOf="@+id/textView7" />

<TextView
    android:id="@+id/textView8"
    android:layout_width="147dp"
    android:layout_height="34dp"
    android:layout_marginBottom="8dp"
    android:layout_marginEnd="8dp"
    android:layout_marginStart="8dp"
    android:text="No te arrepentiras"
    android:textSize="18sp"
    app:layout_constraintBottom_toBottomOf="parent"
    app:layout_constraintEnd_toEndOf="parent"
    app:layout_constraintHorizontal_bias="0.502"
    app:layout_constraintStart_toStartOf="parent"
    app:layout_constraintTop_toBottomOf="@+id/button2"
    app:layout_constraintVertical_bias="0.226" />
<Button
    android:id="@+id/button3"
    android:layout_width="wrap_content"
    android:layout_height="wrap_content"
    android:layout_marginEnd="8dp"
    android:layout_marginStart="8dp"
    android:text="Salir"
    app:layout_constraintBottom_toBottomOf="parent"
    app:layout_constraintEnd_toEndOf="parent"
    app:layout_constraintHorizontal_bias="0.928"
    app:layout_constraintStart_toStartOf="parent" />
Conclusión:
Aprendí que las relaciones son importantes, para que todo se mantenga en orden dentro de la pantalla, aunque a primera vista no se note



Actividad 04: “CALCULADORA_1”
<?xml version="1.0" encoding="utf-8"?>

<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
    xmlns:app="http://schemas.android.com/apk/res-auto"
    xmlns:tools="http://schemas.android.com/tools"
    android:layout_width="match_parent"
    android:layout_height="match_parent"
    android:orientation="vertical"
 tools:context="com.example.lap_c_pc36.myapplication.MainActivity">

    <TextView

        android:id="@+id/textView2"
        android:layout_width="117dp"
        android:layout_height="30dp"
        android:text="Numero 1"
        android:textSize="20dp" />

    <EditText

        android:id="@+id/num1"
        android:layout_width="match_parent"
        android:layout_height="wrap_content"
        android:ems="10"
        android:hint="Introduce un numero"
        android:inputType="numberDecimal" />

    <TextView

        android:id="@+id/textView3"
        android:layout_width="82dp"
        android:layout_height="30dp"
        android:text="Numero 2"
        android:textSize="20dp"/>

    <EditText

        android:id="@+id/num2"
        android:layout_width="match_parent"
        android:layout_height="wrap_content"
        android:ems="10"
        android:hint="Introduce un numero"
        android:inputType="numberDecimal" />

<LinearLayout

    android:layout_width="match_parent"
    android:layout_height="match_parent"
    android:orientation="vertical">

    <Button

        android:id="@+id/btn"
        android:layout_width="match_parent"
        android:layout_height="wrap_content"
        android:onClick="operacionsuma"
        android:text="Suma" />

    <Button

        android:id="@+id/btn3"
        android:layout_width="match_parent"
        android:layout_height="wrap_content"
        android:onClick="operacionresta"
        android:text="Resta" />

    <Button

        android:id="@+id/btn2"
        android:layout_width="match_parent"
        android:layout_height="wrap_content"
        android:onClick="operacionmulti"
        android:text="Multiplicacion" />

   

<Button
        android:id="@+id/btn1"
        android:layout_width="match_parent"
        android:layout_height="wrap_content"
        android:onClick="operaciondivision"
        android:text="Division" />

    <LinearLayout

        android:layout_width="match_parent"
        android:layout_height="match_parent"
        android:orientation="vertical">

        <TextView

            android:id="@+id/textView5"
            android:layout_width="191dp"
            android:layout_height="wrap_content"
            android:layout_weight="1"
            android:text="RESULTADO"
            android:textSize="20dp" />

        <EditText
            android:id="@+id/num3"
            android:layout_width="293dp"
            android:layout_height="4dp"
            android:layout_weight="2"
            android:ems="10"
            android:hint="Resultado"
            android:inputType="numberDecimal" />
    </LinearLayout>
</LinearLayout></LinearLayout>

Otro código 

package com.example.lap_c_pc36.myapplication;
import android.support.v7.app.AppCompatActivity;
import android.os.Bundle;
import android.view.View;
import android.widget.EditText;
public class MainActivity extends AppCompatActivity {
public EditText numero1, numero2, resul;

    @Override

    protected void onCreate(Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);
        setContentView(R.layout.activity_main);
        numero1=(EditText)findViewById(R.id.num1);
        numero2=(EditText)findViewById(R.id.num2);
        resul=(EditText)findViewById(R.id.num3);

    }

    public void operacionsuma(View view){

        float suma;
        float n1= Float.parseFloat(numero1.getText().toString());
        float n2=Float.parseFloat(numero2.getText().toString());
        suma= n1+n2;
        resul.setText(String.valueOf(suma));

    }

    public void operacionresta(View view){

        float resta;
        float n1=Float.parseFloat(numero1.getText().toString());
        float n2=Float.parseFloat(numero2.getText().toString());
        resta= n1-n2;
        resul.setText(String.valueOf(resta));

    }
public void operacionmulti(View view){

        float mul;
        float n1=Float.parseFloat(numero1.getText().toString());
        float n2=Float.parseFloat(numero2.getText().toString());
        mul=n1*n2;
        resul.setText(String.valueOf(mul));

    }

    public void operaciondivision(View view)

    {

      float div;
      float n1=Float.parseFloat(numero1.getText().toString());
      float n2=Float.parseFloat(numero2.getText().toString());
      div= n1/n2;
      resul.setText(String.valueOf(div));


    }
Conclusión: aprendí a utilizar variables y a usar el hint

Actividad 05: “Parimpar”

<?xml version="1.0" encoding="utf-8"?>
<android.support.constraint.ConstraintLayout xmlns:android="http://schemas.android.com/apk/res/android"
    xmlns:app="http://schemas.android.com/apk/res-auto"
    xmlns:tools="http://schemas.android.com/tools"
    android:layout_width="match_parent"
    android:layout_height="match_parent"
    android:background="@android:color/holo_green_light"
    tools:context="com.example.lap_c_pc26.deter.MainActivity">


    <TextView
        android:id="@+id/textView"
        android:layout_width="248dp"
        android:layout_height="28dp"
        android:layout_marginEnd="8dp"
        android:layout_marginStart="8dp"
        android:layout_marginTop="76dp"
        android:text="Escribe un numero"
        android:textSize="24dp"
        app:layout_constraintEnd_toEndOf="parent"
        app:layout_constraintStart_toStartOf="parent"
        app:layout_constraintTop_toTopOf="parent" />

    <EditText
        android:id="@+id/lolete"
        android:layout_width="wrap_content"
        android:layout_height="51dp"
        android:layout_marginEnd="8dp"
        android:layout_marginStart="8dp"
        android:layout_marginTop="72dp"
        android:ems="10"
        android:hint="Introduce tu numero"
        android:inputType="numberDecimal"
        android:textSize="24dp"
        app:layout_constraintEnd_toEndOf="parent"
        app:layout_constraintHorizontal_bias="0.506"
        app:layout_constraintStart_toStartOf="parent"
        app:layout_constraintTop_toBottomOf="@+id/textView" />

    <Button
        android:id="@+id/button"
        android:layout_width="wrap_content"
        android:layout_height="wrap_content"
        android:layout_marginBottom="300dp"
        android:layout_marginEnd="8dp"
        android:layout_marginStart="8dp"
        android:layout_marginTop="8dp"
        android:onClick="Verificar"
        android:text="Comprobar"
        app:layout_constraintBottom_toBottomOf="parent"
        app:layout_constraintEnd_toEndOf="parent"
        app:layout_constraintStart_toStartOf="parent"
        app:layout_constraintTop_toBottomOf="@+id/lolete"
        app:layout_constraintVertical_bias="0.0" />

    <TextView
        android:id="@+id/t_r"
        android:layout_width="194dp"
        android:layout_height="37dp"
        android:layout_marginEnd="8dp"
        android:layout_marginStart="8dp"
        android:layout_marginTop="24dp"
        android:hint="Resultado"
        android:textSize="24dp"
        app:layout_constraintEnd_toEndOf="parent"
        app:layout_constraintStart_toStartOf="parent"
        app:layout_constraintTop_toBottomOf="@+id/button" />

    <Button
        android:id="@+id/button2"
        android:layout_width="124dp"
        android:layout_height="wrap_content"
        android:onClick="Limpan"
        android:text="Limpiar pantalla"
        tools:layout_editor_absoluteX="39dp"
        tools:layout_editor_absoluteY="402dp" />
</android.support.constraint.ConstraintLayout>

Código 2:

package com.example.lap_c_pc26.deter;
import android.support.v7.app.AppCompatActivity;
import android.os.Bundle;
import android.view.View;
import android.widget.EditText;
import android.widget.TextView;
public class MainActivity extends AppCompatActivity {
public EditText numero;
public TextView resultado;
    @Override
    protected void onCreate(Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);
        setContentView(R.layout.activity_main);
        numero=(EditText)findViewById(R.id.lolete);
    resultado=(TextView)findViewById(R.id.t_r);
    }
    public void Verificar(View view){
        int num;
        String respuesta;
        num=Integer.parseInt(numero.getText().toString());
        if (num%2==0)
            respuesta="Numero Par";
        else
            respuesta="Numero impar";
        resultado.setText(respuesta);
    }
    public void Limpan(View view){
        resultado.setText("");
        numero.setText("");
    }
}
Conclusión: En esta practica aprendí a hacer un botón de limpiar pantalla y a usar "if"



Comentarios