Function aoc_driver::post_answer
source · pub fn post_answer<SolOutput>(
session: &str,
year: i32,
day: i32,
part: i32,
cache_path: Option<impl AsRef<Path>>,
answer: SolOutput
) -> Result<()>where
SolOutput: Display,
Expand description
Post an answer to the AoC website.
Will also cache the result / submission at the given path if provided
Returns Ok(())
if answer was correct or has already been given
Returns Err(Error::Incorrect)
if the answer was wrong
Returns Err(Error::RateLimit(String))
if you are being rate-limited