3 ms·
It can really depend how you write it. In some instances you can just throw things together and it can look a fair bit like you might write it in what many woul
by Measter 6y ago
It can really depend how you write it. In some instances you can just throw things together and it can look a fair bit like you might write it in what many would consider high level languages.
On the other hand, there are times when you really need to get into the nitty gritty of things for performance reasons, and it ends up feeling quite low level.
For example, here's a Rust program which does the same as fqcnt_py1_4l.py: https://gist.github.com/Measter/d31abe88b5e318ba98856bf6f047ef19 https://gist.github.com/Measter/d31abe88b5e318ba98856bf6f047...
It's longer than the Python version[0], I'm going out of my way to not allocate for every string. But, and maybe I'm biased here, it doesn't really feel like it's low-level code.
[0] https://github.com/lh3/biofast/blob/master/fqcnt/fqcnt_py1_4l.py https://github.com/lh3/biofast/blob/master/fqcnt/fqcnt_py1_4...