a 'c' program to tell that the set of three coordinates lie
on a same line
Answer Posted / chetan kole
m1=(y2-y1)/(x2-x1);
m2=(y3-y2)/(x3-x2);
if(m1==m2)
{
printf("3 points are on same line")
}
else
{
printf("not on same line");
}
Is This Answer Correct ? | 19 Yes | 5 No |
Post New Answer View All Answers
What will the preprocessor do for a program?
code for replace tabs with equivalent number of blanks
How can I find out how much free space is available on disk?
Explain what is the benefit of using enum to declare a constant?
Why functions are used in c?
How can I read data from data files with particular formats?
What is enumerated data type in c?
What is the -> in c?
Differentiate between declaring a variable and defining a variable?
a sequence of bytes with one to one corrspondence to those in the external device a) sequential addressing b) address c) byte code d) none
what are # pragma staments?
What is anagram in c?
What is a global variable in c?
What is the difference between void main and main in c?
How do I create a directory? How do I remove a directory (and its contents)?