Explore BrainMass

Explore BrainMass

    Java

    BrainMass Solutions Available for Instant Download

    Writing a Program Using the Paint Component Method

    Write a program that uses the paint component method to draw the current value of a JSlider on a subclass of JPanel. In addition, provide a JTextField where a specific value can be entered. The JTextField should display the current value of the JSlider at all times. A JLabel should be used to identify the JTextField. The JSli

    Java Clock: Writing a Digital Clock in a Window Using an Applet

    Write a program that displays a digital clock in a window using an applet. The clock should show, day of week, date, time, time zone and year. The two following classes should help get some of the information needed. import java.util.Date; import javax.swing.Timer;

    Java applet, converting character to integer(vice versa) - ASCII

    I guess my biggest issue is actually to draw a functionable applet. Design an applet Conversion.java that converts a character to a corresponding integer, and vice versa. The integer corresponding to a character is its ASCII code. The design should look as the attached picture. The applet has to have the following functio

    Define a class called fraction, embed class in a test program.

    Define a class called Fraction, used to represent a ratio of two integers. 1. Include mutator functions that allow the user to set the numerator and the denominator. 2. Also include a METHOD that displays the fraction on the screen as a ratio (e.g., 5/9). This method does not need to reduce the fraction to lowest terms. 3.

    Java Tree manipulation

    Tree manipulation I need to write a program that allows the user to enter a line of text. I then need to use the stringTokenizer to break the input into words. I have to Put these words into a link list and then print them out in alphabetical order. Even though the words may appear multiple times in the entered text , it o

    Java pair selection.

    I need to write a generic class Pair which has two type parameters F and S (first and second) each representing the first and second elements of the pair. Add get and set elements so that the values of the pair can be changed. This is an example of the code of the test class that calls for the pair class. public class Pai

    Create a class named MyRectangle to represent rectangles

    Create a class named MyRectangle to represent rectangles. The required data fields are width, height, and color. Use double data type for width and height, and a String for color. Suppose that all rectangles are the same color. Use a static variable for color. You will need to provide the accessor methods for the properties and

    Java solution to verify records are in alphabetical order

    Dear OTA, I need a Java solution that can verify if records are in alphabetical order based on last name then first name. I need this solution in 2 classes: 1. One with the main method that prompts the user for the input filename (merchants.txt). If the input file cannot be opened, the method should continue to reprompt

    Java Beginner - Fundamental Java

    In plain fundamental Java how would I use an array to come up with the following. Please show how this is done in Java format. Not C++ or anything like that. ?Modify the Inventory Program so the application can handle multiple items. Use an array to store the items. The output should display the information one product at a

    Array class member methods

    Visit the http://java.sun.com/j2se/1.5.0/docs/api/ web documentation for J2SE 1.5.0 API Specification. Briefly explain one of the Array class member methods. Include a simple program example demonstrating its use. Write the program as if you were explaining it to someone new to arrays. Fully document your code in such a way n

    Creating a Java application that uses an int array

    Create a Java application that implements an int array. Use for loops to iterate through the array using the array's length variable to stay within the array bounds. Fill the array with random numbers and print the array. Continue to properly document your source code. Write this program as if you were explaining it to someo

    Java Employee Payroll Problem

    The file must be called <Payroll.java> (driver program) Employee.java Hourly.java (which extends employee) Salaried.java (which extends employee) SalariedPlusCommission.java (which extends Salaried) Overall Requirements Write an employee payroll program that uses polymorphism to calculate and print the weekly payroll for y

    Modifying Inventory Programs

    Modify the Inventory Program to include an Add button, a Delete button, and a Modify button on the GUI. These buttons should allow the user to perform the corresponding actions on the item name, the number of units in stock, and the price of each unit. An item added to the inventory should have an item number one more than the p

    Overloaded Java Methods

    Write overloaded Java methods that return the difference of two parameters. Your methods should contain the logic to return the difference of the larger parameter ?smaller parameter, regardless of parameter order. Provide enough test code to ensure your methods are logically correct. The following table displays the required met

    JAVA Program and Calculating a Mortgage

    Write the program in Java (with a graphical user interface) so that it will allow the user to select which way they want to calculate a mortgage: by input of the amount of the mortgage, the term of the mortgage, and the interest rate of the mortgage payment or by input of the amount of a mortgage and then select from a menu of m

    Mortgage Payment Calculator

    Change Request#1: Write the program in Java (without a graphical user interface) using a loan amount of $200,000 with an interest rate of 5.75% and a 30 year term. Display the mortgage payment amount and then list the loan balance and interest paid for each payment over the term of the loan. If the list would scroll off the s

    Modification of an inventory program: Java example

    Modify the Inventory Program by creating a subclass (12 oz bottle or 12 oz can) of the product class that uses one additional unique feature of the product you chose. In the subclass, create a method to calculate the value of the inventory of a product with the same name as the method previously created for the product class

    Writing a Java Application

    Write a JAVA application that finds the total and average of odd numbers from 1 to 15. Your JAVA program must use a counted loop to accomplish this task. Compile and run your program until it works and the output looks nice

    JavaScripts, DHTML and HTML

    1) Discuss the open source nature of JavaScript scripts. 2) Describe examples of JavaScript script usage in a commercial setting. 3) Explain the difference between DHTML and HTML.

    Java Applications for Inventory

    The product will be Gold soda, there are 50 units in stock, and they hold a price of $1.10 per unit. Create a product class that holds the item number, the name of the product, the number of units in stock, and the price of each unit. Create a Java application that displays the product number, the name of the product, the

    Payroll Program Modification.

    Modify the Payroll Program so that it uses a class to store and retrieve the employee's name, the hourly rate, and the number of hours worked. Use a constructor to initialize the employee information, and a method within that class to calculate the weekly pay. Once stop is entered as the employee name, the application should ter

    JAVA

    Write the program in Java (with a graphical user interface) and have it calculate and display the mortgage payment amount from user input of the amount of the mortgage, the term of the mortgage, and the interest rate of the mortgage. Allow the user to loop back and enter new data or quit. Please insert comments in the program to

    JAVA Computer Language

    Write a program that reads three integer inputs into variables. Display the input values in both the ordered entered and in sorted order. This program should sort the numbers so that value1 <= value2 <= value3.

    JAVA

    Write the program in Java (without a graphical user interface) and have it calculate the payment amount for 3 mortgage loans: - 7 year at 5.35% - 15 year at 5.5% - 30 year at 5.75% Use an array for the different loans. Display the mortgage payment amount for each loan and then list the loan balance and interest paid for

    JAVA

    1. Explain when you would use a while loop rather than a for loop and vice versa. Provide an example of one such instance. 2. How are looping statements different from selection statements?

    JAVA

    1. Why is top down design beneficial. Compare this type of design to another type of design you known. 2. This and that is a powerful keyword used in Java. How is it used and why is it so beneficial? Give an example in your explanation.

    Java Recursion Problem

    Design a Java application that accepts a positive integer n > 1 as a command line parameter and outputs all strictly increasing integer sequences starting with 1 and ending with n. For example, for n=5 the following sequences should be output (not necessarily in the shown order): 1 5 1 2 5 1 3 5 1 2 3 5 1 4 5 1 2 4 5

    Java Inventory Button issue

    1. Modify the Program to include an Add button, a Delete button, and a Modify (buttons have been added!!) button on the GUI. These buttons should allow the user to perform the corresponding actions on the item name, the number of units in stock, and the price of each unit. An item added to the inventory should have an item numbe

    Develop a Java search

    You are working on a custom Web application to create a document library for a client. The main function of the document library is allowing the user to locate documents based on keywords within the document. Because of licensing considerations, the client does not want to use a commercial search engine, so you need to develop o