pub struct Satellite {
pub name: &'static str,
pub mass_kg: f64,
pub radius_m: f64,
}
impl Default for Satellite {
fn default() -> Self {
Self::new()
}
}
impl Satellite {
pub fn new() -> Self {
Self {
name: "ganymede",
mass_kg: 0.0,
radius_m: 0.0,
}
}
}
pub fn info() -> (&'static str, f64, f64) {
("ganymede", 0.0, 0.0)
}