gscaler

Crates.iogscaler
lib.rsgscaler
version1.3.0
sourcesrc
created_at2024-05-15 01:37:52.045914
updated_at2024-05-19 21:00:56.324539
descriptionDisplays point-based grades on a 100-point scale
homepage
repositoryhttps://git.sr.ht/~sramsay/gscaler
max_upload_size
id1240518
size54,997
Stephen Ramsay (sramsay)

documentation

README

builds.sr.ht status License: GPL v3

gscaler

Version 1.3.0

What does this program do?

Suppose you are grading some assignment and it's worth a certain number of points (10, 16, 20, 200, or whatever). You'd like to know how those points would look on a 100-point scale.

This a command-line program for UNIX-like systems that shows you every corresponding 100-point-scale value for every possible whole-number value on an arbitrary point scale up to a maximum number points. So if you are looking at a 16-point assignment, you can type:

$ gscaler 16

And it will display:

16: 100.0
15: 93.8
14: 87.5
13: 81.2
12: 75.0
11: 68.8
10: 62.5
9: 56.2
8: 50.0
7: 43.8
6: 37.5
5: 31.2
4: 25.0
3: 18.8
2: 12.5
1: 6.2

It's not a particularly complicated computation; you could write a quick-and-dirty script in any language that will take care of it in short order. But I've already done it for you.

How do I install this program?

This program is written in Rust, so you need a Rust compiler installed on your machine.

Assuming you have that taken care of, it'll be something like this:

$ cargo install gscaler

Exactly where that installs the binary depends on your local configuration, but cargo is pretty clever, and can probably put it anywhere you like.

So let me get this straight. You wrote over fifty lines of code in Rust to do something this trivial?

Yes. Like I said, you could write a quick-and-dirty shell script to get the job done, and it will probably work. I wrote a meticulous-and-clean version that is probably provably correct for all positive integers representable on your OS, and which is undoubtedly faster than anything any "scripting language" could ever do. Not that any of that matters very much, but again, now you don't have to care.

This thing doesn't have an actual license, does it?

Of course it does! Who knows what you people will get up to.

gscaler is written and maintained by Stephen Ramsay (sramsay{at}protonmail{dot}com).

This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version.

This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.

Last Modified: 2024-05-19T16:00:19:-0500

Commit count: 0

cargo fmt