write a class to input 2 points by the user & check the line
maked by the points is horizontal,vertical or rectangle?
Answer Posted / murli
if (x1,y1) and (x2,y2) are two points..then line made is horizontal if (y1==y2).vertical if(x1==x2).Two points can never form a rectangle.
| Is This Answer Correct ? | 1 Yes | 0 No |
Post New Answer View All Answers
Can a static class have a constructor?
How many days will it take to learn java?
What are conditionals and its types?
Is string a wrapper class?
What is the purpose of tostring() method in java?
Why is it called buffering?
How to split arraylist elements in java?
What is += mean in java?
Which is better ascii or unicode?
EDS (Electronic Data Systems India Pvt Ltd) at Chennai on 16-12-2006.
Explain exception chaining in java?
What happens if an exception is throws from an object's constructor?
Explain about fail fast iterators in java?
How do you override a method?
How do you represent a space in regex java?