Java | JSP | JSF Answers

Questions: 4 418

Answers by our Experts: 3 943

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 & Filtering

Write a Java statement to initialize a variable square with a rectangle object whose top left corner is (10, 20) and whose sides all have length 40. Then write a statement that replaces square with a rectangle of the same size and top left corner (20, 20).
java programme which will print the current time on the console every two seconds after doing this activity for 20 seconds the program quits.
Word Game
Write a program that plays a word game with the user. The program should ask the user to enter the following:

His or her name
His or her age
The name of a city
The name of a college
A profession
A type of animal
A pet’s name


After the user has entered these items, the program should display the following story, inserting the user’s input into the appropriate locations:

There once was a person named NAME who lived in CITY. At the age of AGE, NAME went to college at COLLEGE. NAME graduated and went to work as a PROFESSION. Then, NAME adopted a(n) ANIMAL named PETNAME They both lived happily ever after!

Prompts And Output Labels: There are no labels here but the prompts should simply be (respectively) "Enter your name : ", "Enter your age: ", "Enter the name of a city: ", "Enter the name of a college: ", "Enter profession: ", "Enter a type of animal: ", "Enter a pet name : ". Note that each prompt ends with a ":" followed by one space and is displayed so that the response will appear on the same line as the prompt itself.
Input: Keep in mind that the input responses to the prompts may consist of multiple words. For example, name might be "John Jinkleheimer Schmidt".

CLASS NAMES. Your program class should be called WordGame
Hi experts!

I have a program the i need to write...

i need to write a program that meets the following requirements:


• Define a class named Point with two data fields, x and y, to represent a point's x and y coordinates. Implement the Comparable interface for comparing the points on x-coordinates and on y-coordinates if x-coordinates are identical.
• Define a class named CompareY that implements Comparator<Point>. Implement the compare method to compare two points on their y-coordinates and on their x-coordinates if y-coordinates are identical.
• Randomly create 100 points and apply the Array.sorts method to display the points in increasing order of their x-coordinates and in increasing order of their y-coordinates, respectively.

it has to have a Minimum of three classes, Array.sorts method, collections, selections and methods...

can anyone help me?
Java programming.
square root.

X = -b± √b2 – 4ac
2a
Find x
Java programming.

Given that a Pythagoras theorem is

H2 =b2 +L2

Find h
Java programming.

Find the area of a triangle

Area =1/2base x height
Java programming question
.
Write a program to take an order for a computer system. The basic system costs 375.99. the user then has to choose from a 38 cm screen(costing 75.99) or a 43 cm screen (costing 99.99).

the following extras are optional.

Item Price
DVD/CD writer 65.99
printer 125.00

The program should allow the user to select from these extras and then display the final cost of the order.
how to write jsp program for grade calculating of a sudent marrk using if else
Code a program to calculate the time in minutes for someone to cut a yard. Input the length and width of the yard in feet. Input the length and width of the house in feet. Subtract the area of the house from the area of the yard to determine the amount of grass to be cut. Using 2 square feet per second as the rate at which you can cut the grass (set this up as a constant), determine how long it will take someone to mow the lawn, in minutes.
The program should print:
Length and width of yard
Length and width of house
Area to be cut in square feet
Time to mow the yard in minutes

Input data: (run three times)
Yard - 1500 X 1600 feet
House - 500 X 700 feet

Yard – 4850 X 6000
House – 1000 X 2000
LATEST TUTORIALS
APPROVED BY CLIENTS