from math import *
def dist(x1, y1, x2, y2):
length = sqrt((int(x1) - int(x2))**2 + ① )
return length
a = input("请输入各点的坐标:") # 如“2,3,4,5”则表示坐标点(2,3)和(4,5)
b = a.split(",")
if len(b) % 2 != 0:
print("输入的坐标有误!")
else:
s = 0
for i in range(0, ② , 2):
s = s + ③
print("折线的长度为:", s)
A.程序输出正确的折线长度
B.输入的坐标有误!
C.程序运行出错!
① ② ③