Waiting for answer This question has not been answered yet. You can hire a professional tutor to get the answer.

QUESTION

Questionl: 1] Three lines can Form a triangle If the sum of any two lines is greater than the third. Using this informatiom create three Java classes...

So I'm trying to figure out how to do this question, it's for my assignment. I can't really figure out how to do it, it will be highly appreciated if it can be explained to me. Thanks!

Questionl: 1] Three lines can Form a triangle If the sum of any two lines is greater than the third. Using thisinformatiom create three Java classes {see below] with at least one method to determine ifthree lines can form a triangle. Use the code below. and note that you may add Instancevariables. at least one constructor, and other methods. Class lsTrlangle: Used to test the other two classes and contains the method mom. class Una: A line is defined be two points [oil and p21. This class contains two constructors: noargument and argument. Also It contains a method called getLength to return the length of a"he. Class Point: Used to define a point. A point Is defined by two variables of double datatype. Thisclass contains two constructors one to in itialize the instance variables to zero. while the other one to set the Instance variables with specific values. public class IsTricngle { public static void maintstriogil areal [ f’build line 1 mp1 =nw Min to.gfiiig p2 = new lfiiflttfl lfil:Line linel = not Linetpl p23; f’build line 2 figifit P3 = not lfifintlfir fll:Point: p4 = m memo o}-Line lincz = new Lineipi p4]: f_.’build line 3riifit c5 = new Efi1§ttfl lfll:refit 96 = new Mitotic Bi:Line line3 = new Linetp5,p61;If get the length and check if the three linee form a trianglerrwrite your code hereilpublic class LineiErurite your code herei public class Pointl Irwrite your code here
Show more
LEARN MORE EFFECTIVELY AND GET BETTER GRADES!
Ask a Question