pub trait UnsupervisedLearn<T, U>
{
fn train(self: &mut Self, input: &T);
fn predict(self: &Self, input: &T) -> U;
}
pub trait SupervisedLearn<T, U>
{
fn predict(self: &Self, input: &T) -> Result<U, ()>;
fn train<'a, 'b>(self: &'a mut Self, input: &'b T, target: &'b U); }