Write an android phone program that has six rows of widgets

Assignment Help JAVA Programming
Reference no: EM131704523

Programming Assignment

1. Write an Android phone program such that an instance of each class: TextView, Button, EditText, CheckBox, RadioGroup with two RadioButtons, ImageView, ImageButton, and Spinner with three items will be displayed on an AVD. A sample run of your program is as follows.

2. Write an Android phone program such that one instance of EditText, one instances of Button, one instance of TextView, and another instance of EditText are displayed vertically on the AVD. The users of your program will be asked to input a positive integer in the first instance of EditText. When the users click the button instance, the product of integers from 1 to n will be displayed in the second instance of TextView and a triangular pattern consisting of s will be displayed in the second instance of the EditText. For instance, if n = 3, the product should be 6 and the pattern should be

$ $ $
$ $
$.

The beginning of the program run is as follows.

A sample run of the program is as follows.

3. Write an Android phone program such that one instance of Button with text "Fahrenheit -> Celsius", one instance of EditText with text "Input a value in Fahrenheit:", one instances of TextView with text "The corresponding value in Celsius is :", another instance of Button with text "Celsius -> Fahrenheit", another instance of EditText with text "Input a value in Celsius:", and another instances of TextView with text "The corresponding value in Fahrenheit is :" are displayed vertically on the AVD. The users of your program will be asked to input a number for a value in Fahrenheit in the first instance of EditText. When the users click the first instance of Button, the corresponding value in Celsius will be displayed on the first instance of TextView. The users of your program will be also asked to input a number for a value in Celsius in the second instance of EditText. When the users click the second instance of Button, the corresponding value in Fahrenheit will be displayed on the second instance of TextView. Notice that Celsius = 5*(Fahrenheit - 32)/9 or Fahrenheit = 9*Celsius/5 + 32.

The beginning of the program run is as follows.

A sample run of the program is as follows.

4. Write an Android phone program such that three instances of EditText with respective texts "Input the first positive integer", "Input the second positive integer", and "Input the third positive integer", one instances of Button with text "Right Triangle?", and one instance of TextView are displayed vertically on the AVD. The users of your program will be asked to input a positive integer in the first instance of EditText, a positive integer in the second instance of EditText, and a positive integer in the third instance of EditText. When the users click the button instance, the answer (either "yes" or "no") for the question that the three input integers can the lengths of three edges of a right triangle will be displayed in the instance of TextView. In addition, if the answer is "yes", the area of the right triangle should also be displayed.
The beginning of the program run is as follows.

A sample run of the program is as follows.

Another sample run of the program is as follows.

5. Write an Android phone program such that one instance of EditText with text "Input a positive integer", one instances of Button with text "Click here to get outputs", and four instances of TextView with respective texts "Decide if the input number is a prime: ", The number of digits in the input number is: ", "The sum of the digits in the input number is: ", and "The product of the digits in the input number is: "are displayed vertically on the AVD. The users of your program will input a positive integer. After the users click the button, the information for the input integer will be displayed in the corresponding four instances of TextView.

The beginning of the program run is as follows.

A sample run of the program is as follows.

Another sample run of the program is as follows.

6. Write an Android phone program that has six rows of widgets.

The first row has one instance of EditText with text "Num 1", one instance of TextView with text "/" (representing division operation), one instance of TextView with text "Num 2", one instance of TextView with text "=", and one instance of EditText with text "Quotient".

The second row has one instance of EditText with text "Num 1", one instance of TextView with text "%" (representing remainder operation), one instance of TextView with text "Num 2", one instance of TextView with text "=", and one instance of EditText with text "Remainder".

The third row has an instance of Button with text "Start or Restart".

The fourth row has an instance of Button with text "Check Your Answers".

The fifth row has an instance of TextView with text "Quotient is correct or incorrect".

The sixth row has an instance of TextView with text "Remainder is correct or incorrect".

The users of your program will click the button with text "Start or Restart" in the third row.

Then a random integer i with 0 ≤ i ≤ 99 will be set into the two instances of EditText with text "Num 1" in the first and second rows and a random integer j with 1 ≤ j ≤ 99 will be set into the two instances of EditText with text "Num 2" in the first and second rows.

The users of your program will input his or her answers for the integer division and remainder operations for the two randomly generated numbers.

The users of your program will click the button with text "Check Your Answers" in the fourth row. Depending the correctness (or incorrectness) of the answers from the users, the corresponding information will be displayed in the two instances of TextView in the fifth and sixth rows.

Also, during the program run, when the users click the button with text "Start or Restart" in the fourth row, a new pair of integers should be generated and set into the corresponding instances of EditText in the first and second rows.

The beginning of the program run is as follows.

A sample run of the program is as follows.

Another sample run of the program is as follows.

A sample run of the program is as follows.

The last sample run of the program is as follows.

A sample run of the program showing another pair of integers is generated is as follows.

Reference no: EM131704523

Questions Cloud

Meaning the price-intercept of the demand curve : If there is an increase in market demand for the good (X increases, meaning the price-intercept of the demand curve moves up), then:
Discuss advantages of issuing preferred stock versus bonds : The following is an excerpt from a conversation between the chief executive officer, Discuss advantages and disadvantages of issuing preferred stock versus bond
Impacts of cutting social security benefits : Discuss the impacts of cutting social security benefits on U.S. National Debt and social security beneficiaries. Who is helped, who is hurt?
Incentive of students to study and learn : As a result, the A students end up with Bs and the F students get Ds . How would this redistribution affect the incentive of students to study and learn?
Write an android phone program that has six rows of widgets : Write an Android phone program such that an instance of each class. Write an Android phone program that has six rows of widgets.
Describe a real-life example of a sweezy : Describe a real-life example of a Sweezy, Cournot, Stackelbery. or Betrand Oligopoly and offer reasons that you believe that industry fits that conditions.
Why is the adjustment to long run equilibrium : Why is the adjustment to long run equilibrium shown as a shift of demand in monopolistic competition but as a shift of supply in perfect competition.
Comprehensive set of journal entries and financial statement : Cort Hospital was established as a not-for-profit organization on January 1, 2013, to take over the assets of an existing hospital.
Calculate the weighted-average contribution margin : A small drink sells for $1.00 with a variable cost of $0.50. The weighted-average contribution margin is

Reviews

Write a Review

JAVA Programming Questions & Answers

  Write a program called gf2java to implement the finite

write a program called gf2.java to implement the finite field gfpn where p is a prime number and n is a positive

  Splitting a linked list into two sublists in equal sizes

Write the definition of the method splitMid. Also write a program to test your method. (Use either the class UnorderedLinkedList or the class OrderedLinkedList to test your method)

  How do you create a class in java to enable its object

How do you create a class in Java to enable its object to be persistent and what are Java data streams and how are they used to facilitate storage and retrieval of persistent objects?

  Example of a problematic programming situation or scenario

Suggest one (1) example of a problematic programming situation or scenario that the use or implementation of a sequence structure could resolve

  Develop a gui based java program

Designing and developing a College Registration program

  Write a method for the purse class

Write a method for the Purse class public boolean sameContents(Purse other) that checks whether the other purse has the same coins in the same order.

  Create a driver class with a main method

Create a driver class with a main method that creates a course, adds several students, prints a roll, and prints the overall course test average

  Survey conductor application

Survey Conductor Application: You have been asked by your manager to create a user-friendly application that will present a survey to your customers

  Computing the time complexity using the big-o notation

You are required to calculate the time complexity using the big-O notation of the Algorithm_2 given by the following methods defined by the following Java code.

  Use a variables of type double for the calculations

Write a program that takes a value x as input and outputs this sum for n taken to be each of the values 1 to 10, 50, and 100

  Create an overloaded constructor that provides values

Create a class named BloodData that includes fields that hold a blood type (the four blood types are O, A, B, and AB) and an Rh factor (the factors are + and -).

  Compute the total annual compensation of a salesperson

Create a Java application using NetBeans Integrated Development Environment (IDE) that Computes the total annual compensation of a salesperson.

Free Assignment Quote

Assured A++ Grade

Get guaranteed satisfaction & time on delivery in every assignment order you paid with us! We ensure premium quality solution document along with free turntin report!

All rights reserved! Copyrights ©2019-2020 ExpertsMind IT Educational Pvt Ltd