11 "[-16, 12, -18, -1, 5]"
16 "output_type": "execute_result"
20 "changes = [int(l.strip()) for l in open('../../data/advent01.txt')]\n",
37 "output_type": "execute_result"
57 "output_type": "execute_result"
61 "frequencies = set()\n",
63 "current_frequency = 0\n",
65 "while current_frequency not in frequencies:\n",
66 " frequencies.add(current_frequency)\n",
67 " current_frequency += changes[i]\n",
69 " i %= len(changes)\n",
76 "execution_count": null,
84 "display_name": "Python 3",
93 "file_extension": ".py",
94 "mimetype": "text/x-python",
96 "nbconvert_exporter": "python",
97 "pygments_lexer": "ipython3",