问题 解答题

编写一个程序,判断直线l1:A1x+B1y+C1=0和直线l2:A2x+B2y+C2=0的位置关系.

答案

A1=input(“A1=”);

B1=input(“B1=”);

C1=input(“C1=”);

A2=input(“A2=”);

B2=input(“B2=”);

C2=input(“C2=”);

if  A1*B2—=A2*B1

disp(“相交”);

else

if  A1*C2—=A2*C1

disp(“平行”);

else

disp(“重合”);

end

end

解答题
单项选择题