Struct advent_of_code_2023::day_4::Scratchcard
source · struct Scratchcard {
winning_numbers: HashSet<i32>,
numbers_you_have: HashSet<i32>,
}
Expand description
Represents a scratchcard (one line of input)
Fields§
§winning_numbers: HashSet<i32>
§numbers_you_have: HashSet<i32>
Implementations§
source§impl Scratchcard
impl Scratchcard
Trait Implementations§
source§impl Debug for Scratchcard
impl Debug for Scratchcard
source§impl From<&str> for Scratchcard
impl From<&str> for Scratchcard
source§impl PartialEq<Scratchcard> for Scratchcard
impl PartialEq<Scratchcard> for Scratchcard
source§fn eq(&self, other: &Scratchcard) -> bool
fn eq(&self, other: &Scratchcard) -> bool
This method tests for
self
and other
values to be equal, and is used
by ==
.impl Eq for Scratchcard
impl StructuralEq for Scratchcard
impl StructuralPartialEq for Scratchcard
Auto Trait Implementations§
impl RefUnwindSafe for Scratchcard
impl Send for Scratchcard
impl Sync for Scratchcard
impl Unpin for Scratchcard
impl UnwindSafe for Scratchcard
Blanket Implementations§
source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere T: ?Sized,
source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
source§impl<Q, K> Equivalent<K> for Qwhere
Q: Eq + ?Sized,
K: Borrow<Q> + ?Sized,
impl<Q, K> Equivalent<K> for Qwhere Q: Eq + ?Sized, K: Borrow<Q> + ?Sized,
source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key
and return true
if they are equal.