My second week of Rust (only a few hours a day though: I am on vacation after all) has me reproducing and enhancing a tool I wrote in C. It takes multiple lines and runs stats on the numbers in it.

This is useful for quick benchmarks: `for i in $(seq 10); do /usr/bin/time myprog; done | linestats`. Each line with the same literal parts is combined, with numbers replaced by "min-max(mean+/-stddev)".

The C one wasn't very clever about decimals, so it needed a good rewrite. The new code works, but needs polish, more options, optimization, tests and documentation before I release it.

The good thing about these small projects is they don't get hamstrung by Rust's glacial build times!

Reply to this note

Please Login to reply.

Discussion

Love it. Big data telemetry kinda killed the use case a bit, but I still use the C one the other day! Percentile mode support would be neat.

Hmm, I did a histogram mode, but it sucked if one value dominated. Percentiles a good idea though!

Rust ist the future. For AI with Frameworks Like Burn, for Databases with Frameworks Like SurrealDB for web and App Developement with de Framework Dioxus and Leptos. It is a all in one language. Check Out by Videos and you See more :) ๐Ÿฆ€๐Ÿงก

malxte.de

ByteMalte.de

#Rust #RustLang #AI