use std::{fmt::Debug, marker::PhantomData, ops::Rem};
use crate::utils::num_traits::Zero;
#[derive(Debug)]
pub struct Min<T>(PhantomData<T>);
#[derive(Debug, Clone)]
pub struct Max<T>(PhantomData<T>);
#[derive(Debug, Clone)]
pub struct MinMax<T>(PhantomData<T>);
#[derive(Debug, Clone)]
pub struct Add<T>(PhantomData<T>);
#[derive(Debug, Clone)]
pub struct Mul<T>(PhantomData<T>);
#[derive(Debug, Clone)]
pub struct Xor;
#[derive(Debug)]
pub struct GCD<T>(PhantomData<T>);
impl<T: Clone + PartialEq + Zero + Rem<T, Output = T>> GCD<T> {
pub fn gcd(a: &T, b: &T) -> T {
if b.is_zero() {
a.clone()
} else {
Self::gcd(b, &a.clone().rem(b.clone()))
}
}
}