jarv / cmdchallenge

This repo is mirror of https://gitlab.com/jarv/cmdchallenge
https://about.cmdchallenge.com
MIT License
721 stars 71 forks source link

Score board #117

Open jcubic opened 7 years ago

jcubic commented 7 years ago

I would be nice if you get some kind of score board where you can put your name and it will show your score along with others that complete the challenges, it can be calculated by summing lengths of all user commands, or taking average of the length (so it will work when new challenge is added). So first place will be for the person that use commands with smaller number of characters.

It probably will be complicated to do because right now completed challenges are saved in localStorage (it will be needed to save commands on the server) and the commands used are not saved.

One more thing when user complete the challenge he could be able to see other people commands, the shortest at the top.

Something to consider.

0ki commented 7 years ago

Why do you think I scoreboard would be nice? I think It'd attract the wrong kind of attention.

jarv commented 7 years ago

I've been thinking about how to best show correct solutions that other people have submitted, maybe a link next to each challenge that displays them? Or maybe a special console command that does the same though it may be a little trickier to display them in a nice way in the terminal. Unfortunately it won't be easy to distinguish the best answers from the weird/cheating ones that just happen to be correct. For the leaderboard I think it would be nice if there were more things in place to prevent cheating like running against random input (similar to hackerrank).

rawiriblundell commented 7 years ago

How about something a bit like commandlinefu where solutions are voteable? For extra usefulness, it might be good to be able to mark answers as duplicates, that way very similar answers that may differ in a subtle way such as variable quoting style (e.g. $file vs "$file" vs "${file}") can be grouped. The most 'correct' of these duplicates can then be voted to where it belongs.

Another factor that would be great to grade answers on would be portability. An answer that is totally correct in a Linux sense may be full of GNUisms and useless on non-GNU, likewise an OSX-safe answer may be full of BSDisms and so on. Being able to tag answers as correct for POSIX, GNU and/or BSD could be useful...

OR you could just do what shellcheck does and pass that work over to a wiki and let "the community" deal with it?

jarv commented 7 years ago

Great ideas, I think the first thing I will do is create a way to browse all accepted solutions and I like the suggestion to vote on them.