Welcome to Assignments Writing

Your Trusted Partner in Term Paper Writing

At Assignments Writing, we’re a team of passionate educators and skilled writers committed to supporting students in their academic journey.

Mobile Application

Mobile Application

ANSWER

java
package com.example.tickethub;

import androidx.appcompat.app.AppCompatActivity;
import android.os.Bundle;
import android.view.View;
import android.widget.AdapterView;
import android.widget.ArrayAdapter;
import android.widget.Button;
import android.widget.EditText;
import android.widget.ImageView;
import android.widget.Spinner;
import android.widget.TextView;

public class MainActivity extends AppCompatActivity {

// Declare UI components
private ImageView imageView;
private TextView titleTextView, totalCostTextView;
private EditText numTicketsEditText;
private Spinner eventSpinner;
private Button calculateButton;

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

// Initialize UI components
imageView = findViewById(R.id.imageView);
titleTextView = findViewById(R.id.titleTextView);
totalCostTextView = findViewById(R.id.totalCostTextView);
numTicketsEditText = findViewById(R.id.numTicketsEditText);
eventSpinner = findViewById(R.id.eventSpinner);
calculateButton = findViewById(R.id.calculateButton);

// Set up the spinner with event options
ArrayAdapter<CharSequence> adapter = ArrayAdapter.createFromResource(
this, R.array.event_array, android.R.layout.simple_spinner_item);
adapter.setDropDownViewResource(android.R.layout.simple_spinner_dropdown_item);
eventSpinner.setAdapter(adapter);

// Set an item selected listener for the spinner
eventSpinner.setOnItemSelectedListener(new AdapterView.OnItemSelectedListener() {
@Override
public void onItemSelected(AdapterView<?> parentView, View selectedItemView, int position, long id) {
// Handle spinner item selection if needed
}

@Override
public void onNothingSelected(AdapterView<?> parentView) {
// Do nothing here
}
});

// Set a click listener for the calculate button
calculateButton.setOnClickListener(new View.OnClickListener() {
@Override
public void onClick(View v) {
calculateTotalCost();
}
});
}

private void calculateTotalCost() {
// Get the number of tickets entered by the user
String numTicketsStr = numTicketsEditText.getText().toString();
int numTickets = Integer.parseInt(numTicketsStr);

// Fixed ticket cost per ticket
double ticketCost = 59.99;

// Calculate the total cost
double totalCost = numTickets * ticketCost;

// Display the total cost
totalCostTextView.setText("Total Cost: $" + totalCost);
}
}

In this code, we have defined the necessary UI components and set up the spinner with event options as specified in your requirements. The calculateTotalCost method calculates the total cost based on the number of tickets entered by the user and displays it in the totalCostTextView.

You will need to create the layout XML file (e.g., activity_main.xml) that corresponds to this code and includes the required UI components.

Additionally, you’ll need to create the appropriate resource files, such as strings, and add them to your project as needed. Please adapt this code to your specific project and make sure to add your custom icon and theme to your Android app accordingly.

Mobile Application

QUESTION

Description

 

 

In this app, the user will select an event, enter data, and the mobile app will conduct data processing by performing mathematical calculations. The mobile app details are below: Using Android Studio

  • Mobile Application Title: “Ticket Hub”
  • Overview: Provide an app that will calculate the total cost of concert tickets for the user. The user will select the event name, enter the number of tickets, and find the cost via a button.
  • Requirements:
    • The app will include a single screen – create your own layout
    • App must have a custom icon – use an icon of your choosing
    • Apply a theme to the app screen
    • The opening screen contains the following:
      • Large title named Concert Ticket Hub using a TextView.
      • Image using an ImageView
      • Button control to calculate the cost (concert tickets are $59.99 each, regardless of the event)
      • A Number Text Field control to allow the user to enter the number of tickets.
      • A Spinner control that includes three events:
        • Pop Music Festival
        • Jazz Music Festival
        • Country Music Festival.
      • A TextView to display the total cost for the tickets
    • When the calculate button is clicked, the total cost for the tickets is displayed
  • Conditions/Instructions: Use a theme, a title, an image, a spinner prompt, a string array, a custom icon, and a hint property.

Submit screen captures of the mobile app being emulated and the code of the ActivityMain.java file (be sure to include a comment in your code with your name and date).

Save your file as Week2_PA1_your name. Submit your assignment using the Submission instructions below. Screen captures must include:

  • App running in an emulator showing all required components
  • App running in an emulator showing spinner control open showing all events listed
  • App running in an emulator showing total cost calculated
  • Emulator app screen showing custom app launcher icon
  • java code (including comment with your name and date at the top of the file)
Place Your Order Here

Our Service Charter


1. Professional & Expert Writers: We only hire the best. Our writers are specially selected and recruited, after which they undergo further training to perfect their skills for specialization purposes. Moreover, our writers are holders of master’s and Ph.D. degrees. They have impressive academic records, besides being native English speakers.

2. Top Quality Papers: Our customers are always guaranteed papers that exceed their expectations. All our writers have +5 years of experience. This implies that all papers are written by individuals who are experts in their fields. In addition, the quality team reviews all the papers before sending them to the customers.

3. Plagiarism-Free Papers: All papers provided are written from scratch. Appropriate referencing and citation of key information are followed. Plagiarism checkers are used by the Quality assurance team and our editors just to double-check that there are no instances of plagiarism.

4. Timely Delivery: Time wasted is equivalent to a failed dedication and commitment. We are known for timely delivery of any pending customer orders. Customers are well informed of the progress of their papers to ensure they keep track of what the writer is providing before the final draft is sent for grading.

5. Affordable Prices: Our prices are fairly structured to fit all groups. Any customer willing to place their assignments with us can do so at very affordable prices. In addition, our customers enjoy regular discounts and bonuses.

6. 24/7 Customer Support: We have put in place a team of experts who answer all customer inquiries promptly. The best part is the ever-availability of the team. Customers can make inquiries anytime.

Format & Features

Our Advantages

How It Works

1. Fill Order Form
2. Make payment
3. Writing process
4. Download paper

Fill in the order form and submit all your files, including instructions, rubrics, and other information given to you by your instructor.

Once you complete filling the forms, complete your payment. We will get the order and assign it to a writer.

When your order is completed, it’s assigned to an editor for approval. The editor approves the order.

Once approved, we will upload the order to your account for you to download.  You can rate your writer or give your customer review.

What Clients Said

{

I am very satisfied! thank you for the quick turnaround. I am very satisfied! thank you for the quick turnaround.I am very satisfied! thank you for the quick turnaround.

5
Mercy M
{

I am very satisfied! thank you for the quick turnaround. I am very satisfied! thank you for the quick turnaround.I am very satisfied! thank you for the quick turnaround.

5
Jane L
{

I am very satisfied! thank you for the quick turnaround. I am very satisfied! thank you for the quick turnaround.I am very satisfied! thank you for the quick turnaround.

4.5
Rayan M

LET US DELIVER YOUR ACADEMIC PAPER ON TIME!

We are a freelance academic writing company geared towards provision of high quality academic papers to students worldwide.

Open chat
1
Scan the code
Hello
Can we help you?