1answer.
Ask question
Login Signup
Ask question
All categories
  • English
  • Mathematics
  • Social Studies
  • Business
  • History
  • Health
  • Geography
  • Biology
  • Physics
  • Chemistry
  • Computers and Technology
  • Arts
  • World Languages
  • Spanish
  • French
  • German
  • Advanced Placement (AP)
  • SAT
  • Medicine
  • Law
  • Engineering
labwork [276]
3 years ago
7

. Complete the code, drawing a line between points (100, 200) and (34, 67)

Computers and Technology
1 answer:
Galina-37 [17]3 years ago
8 0

Answer:

The answer for the given question is given below:

public void paint( Graphics g )

{

g.drawLine(100, 200 ,34, 67);

}

Explanation:

In this code we are using “drawLine” method to draw the line between the points

The graphics object “g” is to call the drawLine method .

The syntax of drawline method is given below

drawLine(int X1, int Y1, int X2, int Y2)

Where  X1,  Y1,  X2,  Y2 are the points in the x and y coordinate

Following are the full code of that program  

import java.applet.Applet; // package of applet

import java.awt.Graphics; // package of awt  

public class line1 extends Applet  //inherit applet class

{

public void paint( Graphics g ) // paint method

{

g.drawLine(100, 200 ,34, 67); // drawline

}

}

It draw the corresponding line between the coordinate

You might be interested in
It took her 9 more months but Marina has managed to save the full $725 plus more to cover fees to pay off the pay-day loan compa
Marianna [84]

Answer:

she loaned 750 dollars.

it took her 9 months to repay it.

it was 275 days since she took out the loan.

the interest rate was 47% per year compounded daily.

the daily interest rate would be 47% / 365 / 100 = .0012876712 per day.

this assumes 365 days in a year, which is the standard assumption that i know of.

the future value of 750 for 275 days would be based on the formula of f = p * (1 + r) ^ n

f is the future value

p is the present value

r is the interest rate per time period (days in this case)

 

n is the number of time periods (days in this case).

the formula becomes:

f = 750 * (1 + .0012876712) ^ 275

solve for f to get:

f = 1068.440089.

that's the future value of the loan.

it's what she owes.

the interest rate on the loan is that value minus 750 = 318.440089.

that's how much extra she needs to pay in addition to whatever fees she was charged.

6 0
3 years ago
Fill in the blank with the correct response.
SCORPION-xisa [38]
Higher Resolution i guess it depends on what it’s requiring
3 0
3 years ago
A location in memory used for storing data and given a name in a computer program is called a because the data in the location c
Gekata [30.6K]
Variable

----------------------------------
6 0
4 years ago
(10 points) 5.12. Discuss how the following pairs of scheduling criteria conflict in certain settings. a. CPU utilization (effic
Novosadov [1.4K]

Answer:

Check the explanation

Explanation:

  1. CPU utilization and response time: CPU utilization is amplified if the overheads that are connected with context switching or alternating are minimized. The context switching outlay can be reduced by performing context switches occasionally. This could on the other hand lead to increasing the response time for processes.
  2. The Average turnaround time and maximum waiting time: Average turnaround time is reduced by implementing the shortest or simple tasks first. Such a scheduling and arrangement strategy could nevertheless starve long-running tasks and in so doing boost their overall waiting time.
  3. I/O device utilization and CPU utilization: CPU utilization is maximized by executing a list of long-running CPU-bound tasks not including the performing context switches. This is maximized by setting up I/O-bound tasks as early as they become ready to run, thus sustaining the overheads of context switches.

3 0
4 years ago
An alien from planet Tao has descended onto Earth.
DochEvi [55]

An alien from planet Tao has descended onto Earth. The Internet is a massive network of networks, a networking infrastructure. It connects millions of computers together globally, forming a network in which any computer can communicate with any other computer as long as they are both connected to the Internet.

Explanation:

  • A packet is the unit of data that is routed between an origin and a destination on the Internet or any other packet-switched network.
  • Network packets are small amounts of data passed over TCP/IP networks.
  • Latency measures the time it takes between your actions and the response between your computer, the internet, and everything in between.
  • An IP address is a label which is used to identify one or more devices on a computer network. It is comparable to a postal address.
  • The Domain Name System (DNS) is vital to the Internet, providing a mechanism for resolving host names into Internet Protocol addresses. Insecure underlying protocols and lack of authentication and integrity checking of the information within the DNS threaten the proper functionality of the DNS.
  • Transmission Control Protocol is a standard that defines how to establish and maintain a network conversation through which application programs can exchange data. TCP works with the Internet Protocol which defines how computers send packets of data to each other.

3 0
4 years ago
Other questions:
  • Create the Following Menu in a loop so the menu will continually show until the user chooses to exit.AddMultiplyExitAdd a value
    10·1 answer
  • The first idea for a communications network was called
    14·2 answers
  • What is an Apple Pen?
    5·2 answers
  • Define Indentation
    8·1 answer
  • Public class Student {
    14·1 answer
  • Hai<br> ill give 100 point if some won answers dis
    14·2 answers
  • Importance of computer​
    15·1 answer
  • Explain different types of networking-based attacks
    5·1 answer
  • Explain the different type of shift register counter ​
    14·1 answer
  • Write a program that accepts the lengths of three sides of a triangle as inputs. the program output should indicate whether or n
    15·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!