Reference no: EM13941648
This applet program needs an html file to run. You should supply the file along with the program so that the reader can test it.
import java.applet.*;
import java.awt.*;
public class DrawRectangles extends Applet {
int width, height;
public void init() {
width = getSize().width;
height = getSize().height;
setBackground( Color.white );
}
public void paint( Graphics g ) {
//(back, blue, cyan, darkGray, gray, green, lightGray, magenta, orange, pink, red, white and yellow)
drawRectangle(g,Color.black,10,10);
drawRectangle(g,Color.blue,10,40);
drawRectangle(g,Color.cyan,10,70);
drawRectangle(g,Color.darkGray,10,100);
drawRectangle(g,Color.pink,10,130);
drawRectangle(g,Color.green,10,170);
drawRectangle(g,Color.lightGray,10,200);
drawRectangle(g,Color.magenta,10,230);
drawRectangle(g,Color.orange,10,260);
drawRectangle(g,Color.red,10,290);
drawRectangle(g,Color.white,10,320);
drawRectangle(g,Color.yellow,10,350);
drawRectangle(g,Color.gray,10,380);
}
public void drawRectangle(Graphics g,Color c,int x,int y)
{
g.setColor( c );
g.fillRect( x, y, 280, 280 );
}
}
Attachment:- DrawRectangles.zip
What is the manufacturer markup percentage
: What is the manufacturer's markup percentage? _______________________, What is the retailer's markup in dollars?______________________________.
|
Projections given for price-quantity and variable costs
: We are evaluating a project that costs $1059720, has a seven-year life, and has no salvage value. Assume that depreciation is straight-line to zero over the life of the project. Sales are projected at 40776 units per year. What is the NPV of the proj..
|
Differences between the company product
: Identify the key competitor products (top 2 or 3) and describe the differences between the company's product(s) and their closest competitor's products.
|
Discuss the message execution
: Discuss the message execution (slice of life, lifestyle, fantasy, mood/image, musical, personality, technical expertise, scientific evidence, testimonial/endorsement)
|
This applet program needs an html file to run.
: This applet program needs an html file to run. You should supply the file along with the program so that the reader can test it.
|
Effectively manage work related stressors
: A manager's job is varied and hectic and managers will often find themselves under much job-related stress. (Hitt, Black and Porter, 2008) Evaluate critically the strategies that 21st Century businesses could use to effectively manage work related s..
|
What is the expected return for this asset
: Assume that next year, we can have three possible states of world with the following probabilities of occurring: 20%, 45%, and 35%. The returns of an asset in each state are 18%, 5%, and -8%. What is the expected return for this asset?
|
Greatest contributor to competitive advantage
: Use the criteria for making a difference to identify which differences appear to be the greatest contributor to competitive advantage.
|
Evaluating an extra dividend versus share repurchase
: Flashback Corporation is evaluating an extra dividend versus a share repurchase. In either case, $21,060 would be spent. Current earnings are $3.60 per share, and the stock currently sells for $90 per share. What will Flashback’s EPS and PE ratio be ..
|