pub use rand_core::RngCore as Rng;
pub trait Deck {
type Card;
fn left(&self) -> usize;
fn draw(&mut self) -> Self::Card;
fn refill(&mut self);
fn try_draw(&mut self) -> Option<Self::Card> {
if self.left() > 0 { Some(self.draw()) } else { None }
}
}
pub trait ToDeck<R: Rng> {
type Out: Deck;
fn to_deck(self, r: R) -> Self::Out;
}