From 229fd49182000255f92a58e8622243bbd27fceaa Mon Sep 17 00:00:00 2001 From: cyfraeviolae Date: Sun, 4 Jul 2021 21:37:11 -0400 Subject: credit --- Untitled.ipynb | 43 +++++++++++++++++++++++++++++-------------- 1 file changed, 29 insertions(+), 14 deletions(-) (limited to 'Untitled.ipynb') diff --git a/Untitled.ipynb b/Untitled.ipynb index 40be1aa..5352cf4 100644 --- a/Untitled.ipynb +++ b/Untitled.ipynb @@ -2,14 +2,14 @@ "cells": [ { "cell_type": "code", - "execution_count": 208, + "execution_count": 212, "metadata": {}, "outputs": [ { "name": "stdout", "output_type": "stream", "text": [ - "['Dark rum', 'Dry white wine', 'Créme de Menthe', 'Peach bitters', 'Maraschino', 'Galliano', 'Raspberry syrup', 'Campari', 'Tequila', 'Créme de Cassis', 'DOM Bénédictine', 'Lillet Blonde', 'Sweet vermouth', 'Kirsch', 'Cream liqueur', 'Grenadine', 'Cherry liqueur', 'Calvados', 'Bourbon', 'Aperol', 'Créme de Cacao', 'Triple Sec', 'Absinthe', 'DiSaronno', 'Peach schnapps', 'Rye', 'Coffee liqueur', 'Drambuie', 'Strawberry syrup', 'Irish whiskey', \"Peychaud's bitters\", 'Raspberry liqueur', 'Scotch', 'Dry vermouth', 'Peach puree', 'Apricot brandy', 'White rum', 'Pisco', 'Orange flower water', 'Prosecco', 'Orange bitters', 'Cognac', 'Angostura bitters', 'Gin', 'Vodka', 'Orgeat', 'Cachaca', 'Blackberry liqueur', 'Champagne', 'Red Port']\n" + "['Grenadine', 'Bourbon', 'White rum', 'Campari', 'Strawberry syrup', 'Angostura bitters', 'Gin', 'Lime juice', 'Vodka', 'Lillet Blonde', 'Sweet vermouth', 'Dry vermouth', 'Kirsch']\n" ] } ], @@ -34,6 +34,7 @@ " 'Olive juice',\n", " 'Ginger Ale',\n", "]\n", + "skip = []\n", "recipesj = json.load(open('recipes-fix.json'))\n", "ingredients = set()\n", "for recipe in recipesj:\n", @@ -62,10 +63,23 @@ }, { "cell_type": "code", - "execution_count": null, + "execution_count": 213, "metadata": {}, - "outputs": [], - "source": [] + "outputs": [ + { + "data": { + "text/plain": [ + "13" + ] + }, + "execution_count": 213, + "metadata": {}, + "output_type": "execute_result" + } + ], + "source": [ + "n_ingredients" + ] }, { "cell_type": "code", @@ -83,18 +97,19 @@ }, { "cell_type": "code", - "execution_count": 192, + "execution_count": 214, "metadata": {}, "outputs": [ { - "data": { - "text/plain": [ - "(50, 50)" - ] - }, - "execution_count": 192, - "metadata": {}, - "output_type": "execute_result" + "ename": "FileNotFoundError", + "evalue": "[Errno 2] No such file or directory: 'sol.2'", + "output_type": "error", + "traceback": [ + "\u001b[0;31m---------------------------------------------------------------------------\u001b[0m", + "\u001b[0;31mFileNotFoundError\u001b[0m Traceback (most recent call last)", + "\u001b[0;32m\u001b[0m in \u001b[0;36m\u001b[0;34m\u001b[0m\n\u001b[0;32m----> 1\u001b[0;31m \u001b[0mlinesf\u001b[0m \u001b[0;34m=\u001b[0m \u001b[0mopen\u001b[0m\u001b[0;34m(\u001b[0m\u001b[0;34m'sol.2'\u001b[0m\u001b[0;34m)\u001b[0m\u001b[0;34m\u001b[0m\u001b[0;34m\u001b[0m\u001b[0m\n\u001b[0m\u001b[1;32m 2\u001b[0m \u001b[0mlines\u001b[0m \u001b[0;34m=\u001b[0m \u001b[0mlinesf\u001b[0m\u001b[0;34m.\u001b[0m\u001b[0mread\u001b[0m\u001b[0;34m(\u001b[0m\u001b[0;34m)\u001b[0m\u001b[0;34m.\u001b[0m\u001b[0msplitlines\u001b[0m\u001b[0;34m(\u001b[0m\u001b[0;34m)\u001b[0m\u001b[0;34m\u001b[0m\u001b[0;34m\u001b[0m\u001b[0m\n\u001b[1;32m 3\u001b[0m \u001b[0mlinesf\u001b[0m\u001b[0;34m.\u001b[0m\u001b[0mclose\u001b[0m\u001b[0;34m(\u001b[0m\u001b[0;34m)\u001b[0m\u001b[0;34m\u001b[0m\u001b[0;34m\u001b[0m\u001b[0m\n\u001b[1;32m 4\u001b[0m \u001b[0msol\u001b[0m \u001b[0;34m=\u001b[0m \u001b[0;34m[\u001b[0m\u001b[0;34m]\u001b[0m\u001b[0;34m\u001b[0m\u001b[0;34m\u001b[0m\u001b[0m\n\u001b[1;32m 5\u001b[0m \u001b[0mseen\u001b[0m \u001b[0;34m=\u001b[0m \u001b[0mset\u001b[0m\u001b[0;34m(\u001b[0m\u001b[0;34m)\u001b[0m\u001b[0;34m\u001b[0m\u001b[0;34m\u001b[0m\u001b[0m\n", + "\u001b[0;31mFileNotFoundError\u001b[0m: [Errno 2] No such file or directory: 'sol.2'" + ] } ], "source": [ -- cgit v1.2.3