pub fn distance(&self, other: &Self) -> f64 {
        let x = self.x - other.x;
        let y = self.y - other.y;
        y.hypot(x)
    }
/// Calculates the distance between two nodes
///
/// Assumes that both nodes have valid x and y coordinates
Calculates the distance between two nodes
Assumes that both nodes have valid x and y coordinates
Calculates the distance between two nodes Assumes that both nodes have valid x and y coordinates
pub fn distance(&self, other: &Self) -> f64 {
        let x = self.x - other.x;
        let y = self.y - other.y;
        y.hypot(x)
    }
pub fn distance ( & self , other : & Self ) -> f64 { let x = self . x - other . x ; let y = self . y - other . y ; y . hypot ( x ) }
Calculates the distance between two nodes
Assumes that both nodes have valid x and y coordinates
Calculates the distance between two nodes Assumes that both nodes have valid x and y coordinates
&self
other
&Self
&self
other
&Self