+5
@@ -0,0 +1,5 @@
|
||||
export function lineLength(line) {
|
||||
const p1 = line[0];
|
||||
const p2 = line[1];
|
||||
return Math.sqrt(Math.pow(p1[0] - p2[0], 2) + Math.pow(p1[1] - p2[1], 2));
|
||||
}
|
||||
Reference in New Issue
Block a user