Java | JSP | JSF Answers

Questions answered by Experts: 3 611

Need a fast expert's response?

Submit order

and get a quick answer at the best price

for any assignment or question with DETAILED EXPLANATIONS!

Search

What will be the output of the following code snippets.

<script>
    var num1 = 50;
    num1++;
    console.log(--num1);
</script>





A company dealing with marketing wants to manage the data of its employees. Each employee has a full name, unique employee number (2019000 to 2019999) and the number of hours he worked and her hourly wage (price).


Write a method “calculateSalary” that calculates the weekly salary of an employee

Write a method “calculateAverage” that calculates the average of weekly salaries

Write a method “calculateAmount” that calculates the total amount of salaries

Write a java program that uses the above method to meets the needs of this company. it performs the following tasks:

Read from the standard input the number n of employees

Read from the standard input the employee characteristics. Use arrays to store the full names, worked hours and hour prices of the n employees read from the console.

Uses the above methods to calculate salaries of employees, calculate the average and the sum of the salaries.

Print each employee with its salary on a separate line.

Print the average and the sum of salaries


Write a Java GUI application that will keep track of a company’s products. The application must


contain the product id, product name and the product price.



Q.3.1 On the form, create three text fields to capture the product details and a non‐


editable text area to display the product details. Create a submit button that


when clicked will save the product details to a Products.txt file. Also include a


search button that will allow a user to search for a product based on the product


id.



Q.3.2 Create a sequential file (products.txt) that contains data for the following fields:


 The product id


 The product name


 The product price



Q.3.3 Load the product details from the Products.txt file. Populate the text area on


form load and whenever a new product is saved


Write a Java application and use a Two dimensional array to store five Dutch, French and Italian


translated words. Use a single array to store the English words.


Your program must:


Q.2.1 Contain a single array to contain the following five English words and a Two


dimensional array to store the following Dutch, French and Italian translated words.


ENGLISH WORD DUTCH WORD FRENCH WORD ITALIAN WORD


sky hemel ciel cielo


run rennen courir correre


study studie etude studia


music muziek musique musica


dog hond chien cane





Q.2.2 Print out each English word with the translated Dutch, French and Italian word.

Develop a Java GUI application that will display the ink cartridge usage of three different printers with a time span of three years.

Q.1.1 On the form, create two combo boxes, to allow a user to select between three different printers and years. When a user has selected a printer and year and clicked the submit button, display the amount of ink cartridges used for that year. Use the following table for the printers and yearly cartridges used:


2019 Epson K750 15 22 12

2020 HP Deskjesk 650 10 35 20 Epson K750 15 22 12


Q.1.2 You are also required to create a menu system which will allow the user to exit the application under the file menu. Under the tool’s menu, allow the form submission and an option to display the yearly ink cartridges used for each printer. The layout of the form is left to your discretion. Marks will be allocated to the presentation and effectiveness of the layout, but the following layout is displayed for your convenience


CS 1102 - Unit 3 Programming Assignment In this assignment, you will modify your Quiz class from the previous assignment. You will create a method that asks a quiz question and a method that checks the answer, and you will use those methods to ask multiple questions. Your program will then report how many questions the user got correct. This program will be the basis for future Programming Assignments in this course. These instructions assume that you are using the Eclipse IDE on your own computer or you may use a different Java environment as long as you can provide Java code and screen shots for your assignment submission. First open your previous Programming Assignment in Ecli


Write a complete Java program that do the following:

a.   Read your student’s ID number, store it in an array named myStudentNO and print it.

b.   find the number of even and odd integers in myStudentNO array


In this assignment, you will modify your Quiz class from the previous assignment. You will create a method that asks a quiz question and a method that checks the answer, and you will use those methods to ask multiple questions. Your program will then report how many questions the user got correct. This program will be the basis for future Programming Assignments in this course.


Write a Java GUI application that will keep track of a user's contact list. The application must contain the contact mobile number, work number and email address








Q.3.1




On the form, create a list box that will allow the user to select a contact name, which is populated from a text file. Also create a search button that when clicked will display the mobile number, work number and email address.






Create a sequential file (contacts.txt) that contains data for the following fields






Q.3.2






The contact name;






The contact mobile number,






The contact work number:






The contact email address






Q.33






Load the data from the contacts txt file and populate the list bax with the contact names Include a feature to inform the user on the amount of contacts






Sample Screenshot:






Contacts Application






Select Contact






Joe Bloggs






Jeff Jones






Mobile






072 157 1545






Work






021 5555555






Email






@gmail.com






Number of contacts: 2






SEARCH

Write a program that will accept a number n and display the sum of all even numbers and

the sum of all odd numbers from 1 to n and the number of rows.


LATEST TUTORIALS
APPROVED BY CLIENTS