Code Monkey home page Code Monkey logo

aoc_table's People

Contributors

loafey avatar typesafety avatar

Stargazers

 avatar

Watchers

 avatar

Forkers

typesafety

aoc_table's Issues

run_day fails if .add is called insufficient amount of times, or out of order

https://github.com/samhamnam/aoc_table/blob/4641a55ac6470c7156adeb4ed9880a8e579eff8c/src/table_gen.rs#L57

Panics

fn main() {
    TableGen::new("AoC 2022 solutions")
        .add(day01::part1, day01::part2)
        .add(day04::part1, day04::part2)
        .run_day(4);
}
hread 'main' panicked at 'removal index (is 3) should be < len (is 2)', /home/typesafety/.cargo/git/checkouts/aoc_table-3e254a7928802429/4641a55/src/table_gen.rs:57:32
stack backtrace:
   0: rust_begin_unwind
             at /rustc/897e37553bba8b42751c67658967889d11ecd120/library/std/src/panicking.rs:584:5
   1: core::panicking::panic_fmt
             at /rustc/897e37553bba8b42751c67658967889d11ecd120/library/core/src/panicking.rs:142:14
   2: alloc::vec::Vec<T,A>::remove::assert_failed
             at /rustc/897e37553bba8b42751c67658967889d11ecd120/library/alloc/src/vec/mod.rs:1441:13
   3: alloc::vec::Vec<T,A>::remove
             at /rustc/897e37553bba8b42751c67658967889d11ecd120/library/alloc/src/vec/mod.rs:1446:13
   4: aoc_table::table_gen::TableGen::run_day
             at /home/typesafety/.cargo/git/checkouts/aoc_table-3e254a7928802429/4641a55/src/table_gen.rs:57:21
   5: aoc2022_rs::main
             at ./src/main.rs:10:5
   6: core::ops::function::FnOnce::call_once
             at /rustc/897e37553bba8b42751c67658967889d11ecd120/library/core/src/ops/function.rs:248:5

Runs the wrong solver (day 1)

fn main() {
    TableGen::new("AoC 2022 solutions")
        .add(day04::part1, day04::part2)
        .add(day03::part1, day03::part2)
        .add(day02::part1, day02::part2)
        .add(day01::part1, day01::part2)
        .run_day(4);
}

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.