How To Generate Signed .Apk File in Android Studio 2020!

Generate .apk file in android studio of 2020. About Android Studio , Basic of Android studio and need of signed .apk file for Play store console ...

This App Belong to Math Solver , In this app we can handle the problem of math like finding value of sin, cos, tan, square root, cube root , and factorial values .you can visit my app on Play Store App link is given this link Click >>>> MATH SOLVE APP…

In this Section we will be saying that google play store is very good platform to store our App on Play Store …We can easily handle our apps and Update our App Time to Time ..Google play store are not take much more time in Update .For More You Can Download and Install My All App on Google Play Store….

Visit my Google Play Store Apps Click on this Link

This My Creative App Click on DeepCrazyWorld App>>>>>>>>>>>

To Solve Your Math Calculation Math Solve App >>>>>

Spinner Bottle Game App>>>>>>>>>>>>>>>>>>>>>

This News Nation App News7on>>>>>>>>>>>>>>

Shopping App ZampKart >>>>>>>>>>>>>>>>>>>

Math Equation Solving App>>>>>>>>>>>>>>>>>>>

Event Basis Picture LovingCaring143 App>>>>>>>>>

Here This Blogger Site App to Explore Your Knowledge Download all this Apps By Google Play Store My Blogger Site App Download And Install Click on Link CrazyCoder>>>>>>>>>>

How To Generate Signed apk File By My YouTube Video Click on >>>>>

How To Publish Android App On Goggle Play Store click on This Link for Publish android app Video>>>>>

// MainActivity.java

package com.deep.mathsolve;

import androidx.appcompat.app.AppCompatActivity;

import android.os.Bundle;
import android.text.Html;
import android.view.View;
import android.widget.Button;
import android.widget.EditText;
import android.widget.TextView;

public class MainActivity extends AppCompatActivity {
    EditText et_input;
    TextView tv_answer;
    Button b_sin, b_cos, b_tan, b_factorial, b_root, b_pow2, b_pow3;

    double input, answer;

    @Override
    protected void onCreate(Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);
        setContentView(R.layout.activity_main);

        et_input = (EditText) findViewById(R.id.et_input);
        tv_answer = (TextView) findViewById(R.id.tv_answer);
        b_sin = (Button) findViewById(R.id.b_sin);
        b_cos = (Button) findViewById(R.id.b_cos);
        b_tan = (Button) findViewById(R.id.b_tan);
        b_factorial = (Button) findViewById(R.id.b_factorial);
        b_root = (Button) findViewById(R.id.b_root);
        b_pow2 = (Button) findViewById(R.id.b_pow2);
        b_pow3 = (Button) findViewById(R.id.b_pow3);

        b_pow2.setText(Html.fromHtml("x<sup>2</sup>"));
        b_pow3.setText(Html.fromHtml("x<sup>3</sup>"));

        b_sin.setOnClickListener(new View.OnClickListener() {
            @Override
            public void onClick(View view) {
                input = Double.parseDouble(et_input.getText().toString());
                answer = Math.sin(input);
                tv_answer.setText("sin:" +answer);
            }
        });

        b_cos.setOnClickListener(new View.OnClickListener() {
            @Override
            public void onClick(View view) {
                input = Double.parseDouble(et_input.getText().toString());
                answer = Math.cos(input);
                tv_answer.setText("cos:" +answer);
            }
        });

        b_tan.setOnClickListener(new View.OnClickListener() {
            @Override
            public void onClick(View view) {
                input = Double.parseDouble(et_input.getText().toString());
                answer = Math.tan(input);
                tv_answer.setText("tan:" +answer);
            }
        });

        b_root.setOnClickListener(new View.OnClickListener() {
            @Override
            public void onClick(View view) {
                input = Double.parseDouble(et_input.getText().toString());
                answer = Math.sqrt(input);
                tv_answer.setText("root:" +answer);
            }
        });

        b_pow2.setOnClickListener(new View.OnClickListener() {
            @Override
            public void onClick(View view) {
                input = Double.parseDouble(et_input.getText().toString());
                answer = Math.pow(input, 2);
                tv_answer.setText("sqare:" +answer);
            }
        });
        b_pow3.setOnClickListener(new View.OnClickListener() {
            @Override
            public void onClick(View view) {
                input = Double.parseDouble(et_input.getText().toString());
                answer = Math.pow(input, 3);
                tv_answer.setText("cubic:" +answer);
            }
        });
        b_factorial.setOnClickListener(new View.OnClickListener() {
            @Override
            public void onClick(View view) {
                input = Double.parseDouble(et_input.getText().toString());
                answer = input;
                for (int i = (int)input - 1; i>1; i++)
                {
                    answer = answer + 1;
                }
                tv_answer.setText("factorial:" +answer);
            }
        });

    }
}

activity_main.xml

<?xml version="1.0" encoding="utf-8"?>
<RelativeLayout 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="#F7F1E9A3"
    android:padding="10dp"
    android:paddingLeft="0dp"
    android:paddingTop="0dp"
    android:paddingRight="0dp"
    android:paddingBottom="0dp"
    tools:context=".MainActivity">

    <EditText
        android:id="@+id/et_input"
        android:layout_width="match_parent"
        android:layout_height="wrap_content"
        android:layout_alignParentTop="true"
        android:layout_marginTop="11dp"
        android:ems="10"
        android:inputType="numberDecimal|numberSigned"
        android:textColor="#009688" />

    <TextView
        android:id="@+id/tv_answer"
        android:layout_width="match_parent"
        android:layout_height="wrap_content"
        android:layout_alignParentBottom="true"
        android:layout_marginBottom="26dp"
        android:gravity="center"
        android:text=""
        android:textColor="#3F51B5"
        android:textSize="24dp" />

    <include
        layout="@layout/buttons"
        android:layout_width="401dp"
        android:layout_height="wrap_content"
        android:layout_marginTop="52dp" />


</RelativeLayout>

buttons.xml

<?xml version="1.0" encoding="utf-8"?>
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
    android:layout_width="match_parent"
    android:layout_height="match_parent"
    android:layout_gravity="center"
    android:background="#F0E8A9"
    android:orientation="vertical">

    <Button
        android:id="@+id/b_sin"
        android:layout_width="match_parent"
        android:layout_height="wrap_content"
        android:layout_marginTop="130dp"
        android:background="#8AE98E"
        android:text="sin"
        android:textAllCaps="false"
        android:textColor="#161515"
        android:textSize="14sp"
        android:textStyle="bold" />

    <Button
        android:id="@+id/b_cos"
        android:layout_width="match_parent"
        android:layout_height="wrap_content"
        android:background="#EC87FD"
        android:text="cos"
        android:textAllCaps="false" />

    <Button
        android:id="@+id/b_tan"
        android:layout_width="match_parent"
        android:layout_height="wrap_content"
        android:background="#EBBB75"
        android:text="tan"
        android:textAllCaps="false" />

    <Button
        android:id="@+id/b_root"
        android:layout_width="match_parent"
        android:layout_height="wrap_content"
        android:background="#99CBF3"
        android:text="@string/root"
        android:textAllCaps="false" />


    <Button
        android:id="@+id/b_pow2"
        android:layout_width="match_parent"
        android:layout_height="wrap_content"
        android:background="#EABBF1"
        android:text="x2"
        android:textAllCaps="false" />

    <Button
        android:id="@+id/b_pow3"
        android:layout_width="match_parent"
        android:layout_height="wrap_content"
        android:background="#8BC34A"
        android:text="x3"
        android:textAllCaps="false" />

    <Button
        android:id="@+id/b_factorial"
        android:layout_width="match_parent"
        android:layout_height="wrap_content"
        android:background="#2196F3"
        android:text="n!"
        android:textAllCaps="false" />

</LinearLayout>

strings.xml

<resources>
    <string name="app_name">Math Solve</string>
    <string name="root">\u221a</string>
</resources>
0Shares

Leave a Reply