Skip to content

Instantly share code, notes, and snippets.

@jjhelmus
Created November 13, 2025 20:59
Show Gist options
  • Select an option

  • Save jjhelmus/7bf9a5149f89ba850e1d706bd6533f05 to your computer and use it in GitHub Desktop.

Select an option

Save jjhelmus/7bf9a5149f89ba850e1d706bd6533f05 to your computer and use it in GitHub Desktop.
Display the source blob
Display the rendered blob
Raw
{
"cells": [
{
"cell_type": "code",
"execution_count": 1,
"id": "aaa8a7ef-0a2d-489d-a222-903fae50d186",
"metadata": {},
"outputs": [
{
"name": "stdout",
"output_type": "stream",
"text": [
" % Total % Received % Xferd Average Speed Time Time Time Current\n",
" Dload Upload Total Spent Left Speed\n",
" 0 0 0 0 0 0 0 0 --:--:-- --:--:-- --:--:-- 0\n",
"100 1040k 100 1040k 0 0 3176k 0 --:--:-- --:--:-- --:--:-- 3176k\n"
]
}
],
"source": [
"!curl -SLO https://github.com/jjhelmus/the-file/releases/download/v2/results.csv.zip"
]
},
{
"cell_type": "code",
"execution_count": 2,
"id": "13b82765-747b-4b17-a171-e66011fe1bef",
"metadata": {},
"outputs": [
{
"name": "stdout",
"output_type": "stream",
"text": [
"-rw-r--r--@ 1 jjhelmus staff 1.0M Nov 13 14:42 results.csv.zip\n"
]
}
],
"source": [
"!ls -lh results.csv.zip"
]
},
{
"cell_type": "code",
"execution_count": 3,
"id": "1738b44d-2742-473e-b309-31e38637b6e6",
"metadata": {},
"outputs": [
{
"name": "stdout",
"output_type": "stream",
"text": [
"6953346b3a253de3669cfd43518a3e5897332fb6d7648a3946dce2334553d6f1 results.csv.zip\n"
]
}
],
"source": [
"!sha256sum results.csv.zip"
]
},
{
"cell_type": "markdown",
"id": "f3416918-8df0-482e-b480-b59e46dd25b0",
"metadata": {},
"source": [
"---\n",
"## User 1 (The Sales Manager)"
]
},
{
"cell_type": "code",
"execution_count": 8,
"id": "8478e538-9fc5-431c-8b87-eb5f2b5a616f",
"metadata": {},
"outputs": [
{
"name": "stdout",
"output_type": "stream",
"text": [
"Archive: results.csv.zip\n",
"warning [results.csv.zip]: 1065784 extra bytes at beginning or within zipfile\n",
" (attempting to process anyway)\n",
" extracting: data.csv \n"
]
}
],
"source": [
"!rm -f data.csv\n",
"!unzip results.csv.zip"
]
},
{
"cell_type": "code",
"execution_count": 9,
"id": "8ed7b3e7-3a2c-4393-98de-80166adf3ffe",
"metadata": {},
"outputs": [
{
"name": "stdout",
"output_type": "stream",
"text": [
"name,score\n",
" Mario,267\n",
" Luigi,187\n",
" Bowser,304\n",
" "
]
}
],
"source": [
"!cat data.csv"
]
},
{
"cell_type": "code",
"execution_count": 10,
"id": "00e7018d-0e1c-4b3e-9209-97a9e2d3b6ad",
"metadata": {},
"outputs": [],
"source": [
"import pandas"
]
},
{
"cell_type": "code",
"execution_count": 11,
"id": "8362ecc2-6ea7-4358-89c6-2f597b6b574e",
"metadata": {},
"outputs": [
{
"data": {
"text/html": [
"<div>\n",
"<style scoped>\n",
" .dataframe tbody tr th:only-of-type {\n",
" vertical-align: middle;\n",
" }\n",
"\n",
" .dataframe tbody tr th {\n",
" vertical-align: top;\n",
" }\n",
"\n",
" .dataframe thead th {\n",
" text-align: right;\n",
" }\n",
"</style>\n",
"<table border=\"1\" class=\"dataframe\">\n",
" <thead>\n",
" <tr style=\"text-align: right;\">\n",
" <th></th>\n",
" <th>name</th>\n",
" <th>score</th>\n",
" </tr>\n",
" </thead>\n",
" <tbody>\n",
" <tr>\n",
" <th>0</th>\n",
" <td>Mario</td>\n",
" <td>267</td>\n",
" </tr>\n",
" <tr>\n",
" <th>1</th>\n",
" <td>Luigi</td>\n",
" <td>187</td>\n",
" </tr>\n",
" <tr>\n",
" <th>2</th>\n",
" <td>Bowser</td>\n",
" <td>304</td>\n",
" </tr>\n",
" </tbody>\n",
"</table>\n",
"</div>"
],
"text/plain": [
" name score\n",
"0 Mario 267\n",
"1 Luigi 187\n",
"2 Bowser 304"
]
},
"execution_count": 11,
"metadata": {},
"output_type": "execute_result"
}
],
"source": [
"df = pandas.read_csv(\"./results.csv.zip\")\n",
"df"
]
},
{
"cell_type": "markdown",
"id": "aa1f08b2-dc87-4045-bfb3-686e74f147c0",
"metadata": {},
"source": [
"----\n",
"## (The Front End Developer)"
]
},
{
"cell_type": "code",
"execution_count": 13,
"id": "d7a5b2df-2ad0-40df-931f-ec75e842e2d2",
"metadata": {},
"outputs": [
{
"name": "stdout",
"output_type": "stream",
"text": [
"<table border=\"1\" class=\"dataframe\">\n",
" <thead>\n",
" <tr style=\"text-align: right;\">\n",
" <th></th>\n",
" <th>name</th>\n",
" <th>score</th>\n",
" </tr>\n",
" </thead>\n",
" <tbody>\n",
" <tr>\n",
" <th>0</th>\n",
" <td>Mario</td>\n",
" <td>125</td>\n",
" </tr>\n",
" <tr>\n",
" <th>1</th>\n",
" <td>Luigi</td>\n",
" <td>987</td>\n",
" </tr>\n",
" <tr>\n",
" <th>2</th>\n",
" <td>Peach</td>\n",
" <td>212</td>\n",
" </tr>\n",
" </tbody>\n",
"</table><!--\n",
"\n",
"\n",
"\n",
"\n"
]
}
],
"source": [
"!head -30 results.csv.zip"
]
},
{
"cell_type": "code",
"execution_count": 14,
"id": "9a754397-2d66-44f5-8367-c27a31aea010",
"metadata": {},
"outputs": [],
"source": [
"!cp results.csv.zip results.html"
]
},
{
"cell_type": "code",
"execution_count": 18,
"id": "552afa29-bae9-4ae8-956f-3c836f9a2710",
"metadata": {},
"outputs": [
{
"data": {
"text/html": [
"<div>\n",
"<style scoped>\n",
" .dataframe tbody tr th:only-of-type {\n",
" vertical-align: middle;\n",
" }\n",
"\n",
" .dataframe tbody tr th {\n",
" vertical-align: top;\n",
" }\n",
"\n",
" .dataframe thead th {\n",
" text-align: right;\n",
" }\n",
"</style>\n",
"<table border=\"1\" class=\"dataframe\">\n",
" <thead>\n",
" <tr style=\"text-align: right;\">\n",
" <th></th>\n",
" <th>Unnamed: 0</th>\n",
" <th>name</th>\n",
" <th>score</th>\n",
" </tr>\n",
" </thead>\n",
" <tbody>\n",
" <tr>\n",
" <th>0</th>\n",
" <td>0</td>\n",
" <td>Mario</td>\n",
" <td>125</td>\n",
" </tr>\n",
" <tr>\n",
" <th>1</th>\n",
" <td>1</td>\n",
" <td>Luigi</td>\n",
" <td>987</td>\n",
" </tr>\n",
" <tr>\n",
" <th>2</th>\n",
" <td>2</td>\n",
" <td>Peach</td>\n",
" <td>212</td>\n",
" </tr>\n",
" </tbody>\n",
"</table>\n",
"</div>"
],
"text/plain": [
" Unnamed: 0 name score\n",
"0 0 Mario 125\n",
"1 1 Luigi 987\n",
"2 2 Peach 212"
]
},
"execution_count": 18,
"metadata": {},
"output_type": "execute_result"
}
],
"source": [
"df = pandas.read_html(\"./results.csv.zip\")[0]\n",
"df"
]
},
{
"cell_type": "markdown",
"id": "46e23580-a672-427c-be5d-696afa35881c",
"metadata": {},
"source": [
"---\n",
"## User 3 : Backend Developer"
]
},
{
"cell_type": "code",
"execution_count": 19,
"id": "bd0bd5ce-9a5f-4fa2-859d-486a54431e52",
"metadata": {},
"outputs": [
{
"name": "stdout",
"output_type": "stream",
"text": [
"results.csv.zip: Hierarchical Data Format (version 5) with 512 bytes user block\n"
]
}
],
"source": [
"!file results.csv.zip"
]
},
{
"cell_type": "code",
"execution_count": 20,
"id": "a25f2119-cd44-451d-9326-db8ff088a9a0",
"metadata": {},
"outputs": [
{
"data": {
"text/html": [
"<div>\n",
"<style scoped>\n",
" .dataframe tbody tr th:only-of-type {\n",
" vertical-align: middle;\n",
" }\n",
"\n",
" .dataframe tbody tr th {\n",
" vertical-align: top;\n",
" }\n",
"\n",
" .dataframe thead th {\n",
" text-align: right;\n",
" }\n",
"</style>\n",
"<table border=\"1\" class=\"dataframe\">\n",
" <thead>\n",
" <tr style=\"text-align: right;\">\n",
" <th></th>\n",
" <th>name</th>\n",
" <th>score</th>\n",
" </tr>\n",
" </thead>\n",
" <tbody>\n",
" <tr>\n",
" <th>0</th>\n",
" <td>Mario</td>\n",
" <td>519</td>\n",
" </tr>\n",
" <tr>\n",
" <th>1</th>\n",
" <td>Luigi</td>\n",
" <td>202</td>\n",
" </tr>\n",
" <tr>\n",
" <th>2</th>\n",
" <td>Toad</td>\n",
" <td>308</td>\n",
" </tr>\n",
" </tbody>\n",
"</table>\n",
"</div>"
],
"text/plain": [
" name score\n",
"0 Mario 519\n",
"1 Luigi 202\n",
"2 Toad 308"
]
},
"execution_count": 20,
"metadata": {},
"output_type": "execute_result"
}
],
"source": [
"df = pandas.read_hdf(\"./results.csv.zip\")\n",
"df"
]
},
{
"cell_type": "code",
"execution_count": null,
"id": "23f3e2d4-32e2-4f0e-8c2f-8422bf2ffdc7",
"metadata": {},
"outputs": [],
"source": []
}
],
"metadata": {
"kernelspec": {
"display_name": "Python 3 (ipykernel)",
"language": "python",
"name": "python3"
},
"language_info": {
"codemirror_mode": {
"name": "ipython",
"version": 3
},
"file_extension": ".py",
"mimetype": "text/x-python",
"name": "python",
"nbconvert_exporter": "python",
"pygments_lexer": "ipython3",
"version": "3.13.9"
}
},
"nbformat": 4,
"nbformat_minor": 5
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment