# How can I tally users on the Wolfram Challenges leaderboard?

Wolfram Challenges has a leaderboard that features users that have completed the challenges in the 'best' way, according to specified criteria like efficiency or shortness of code.

Can I use Mathematica to see which user appears the most in the leaderboard? Or tally who is the best at for example Memory Efficiency or Speed Score, according to the most times they appear in that criterion for a challenge?

I tried looking at the page source, but was stumped by the HTML and Javascript obfuscation. So, even a hint on how to start would be welcomed.

## 1 Answer

After digging through here: https://challenges.wolfram.com/static/js/main.c80ec588.js I found the data:

challengeData =
Dataset@Import[
"https://www.wolframcloud.com/objects/wolframchallenges/public/site/leaderboard.json",
"RawJSON"];


there's also potentially an API you can query, as this exists:

CloudObjects["user:wolframchallenges/public/api"]

CloudObjects::notperm: Unable to perform the requested operation. Permission denied.

\$Failed


but you need authentication and I didn't want to dig and see what cookies and things I'd need to send to get it to work.

Finally, here's another set of data that provides tracking info like solve counts:

trackData =
Dataset@Import[
"https://www.wolframcloud.com/objects/wolframchallenges/public/site/tracks.json",
"RawJSON"];


Here's some fun stuff to do with that data:

### Histogram of solution times:

InternalStringToDouble@*First /@
StringSplit[
Normal@challengeData[All, "Data", "Timing", "Value"]] // Histogram


you can see that most challenges can be done very quickly according to Wolfram's Timing data

### WordCloud of users

Counts@Flatten@
Normal@Values@
challengeData[All, "Data", All, "User", "UserID"] // WordCloud


and here you see that potentially only a small number of people are really trying to get on the leaderboard, as it's so dominated by a few people

### WordCloud of solution counts

solvedCounts =
AssociationThread @@
Transpose@
Flatten[Normal@
Values@trackData[All, "Data", All, {"Title", "Count"}], 1];

solvedCounts // WordCloud


it seems like there are a few popular challenges, but most are largely ignored. We can also Histogram this:

solvedCounts // Histogram[#, 200, PlotRange -> All] &
`

and it seems that most are barely looked at

• Hi thank you for answer! I thought data for how many times a problem has been solved would be somewhere there because it will help with normalizing the difficulty of a problem, but it seems that is only available on a particular problem's page. But this is still great! – 小早川美可子 Oct 14 '18 at 15:45
• @小早川美可子 if you want the number of solutions I can dig that up too – b3m2a1 Oct 14 '18 at 15:46
• Only if not too much trouble! – 小早川美可子 Oct 14 '18 at 15:48
• @小早川美可子 it's done – b3m2a1 Oct 14 '18 at 16:02