first push

This commit is contained in:
Ezekiel 2021-05-28 11:59:44 +02:00
parent 263cd92a1e
commit b2de0e105a
1 changed files with 26 additions and 0 deletions

26
poc_hugo.py Normal file
View File

@ -0,0 +1,26 @@
#!/usr/bin/python3
import pathlib
import time
import os
import csv
import random
from collections import Counter
from rich.console import Console
from rich.markdown import Markdown
def _create_dictionnary():
with open(path) as file:
reader = csv.DictReader(file)
data = list(reader)
question = random.choice(data)
return question
if __name__ == "__main__":
path = "./data/list_book1.csv"
_create_dictionnary()
print(get_random_question())
print()