removed unnecessary .draw()

This commit is contained in:
rasbt 2014-04-17 15:23:29 -04:00
parent 9e3afc5bfb
commit 503b1405ab

View File

@ -1,7 +1,7 @@
{ {
"metadata": { "metadata": {
"name": "", "name": "",
"signature": "sha256:a9475a6f1134f87066829ecff7dab70b1fab2b2cc8ae3ee110b3e719b9626c23" "signature": "sha256:be423e458dd8b1ac6a36f49330311cc1a1741127c5610a636969efddf6d91597"
}, },
"nbformat": 3, "nbformat": 3,
"nbformat_minor": 0, "nbformat_minor": 0,
@ -1299,6 +1299,95 @@
], ],
"prompt_number": 28 "prompt_number": 28
}, },
{
"cell_type": "code",
"collapsed": false,
"input": [
"a = [1, 2, 3, 4, 5]\n",
"for i in a:\n",
" if not i % 2:\n",
" a.remove(i)\n",
"print(a)"
],
"language": "python",
"metadata": {},
"outputs": [
{
"output_type": "stream",
"stream": "stdout",
"text": [
"[1, 3, 5]\n"
]
}
],
"prompt_number": 1
},
{
"cell_type": "code",
"collapsed": false,
"input": [
"b = [2, 4, 5, 6]\n",
"for i in b:\n",
" if not i % 2:\n",
" b.remove(i)\n",
"print(b)"
],
"language": "python",
"metadata": {},
"outputs": [
{
"output_type": "stream",
"stream": "stdout",
"text": [
"[4, 5]\n"
]
}
],
"prompt_number": 7
},
{
"cell_type": "code",
"collapsed": false,
"input": [
"c = [2, 4, 5, 6]\n",
"for i in c:\n",
" if i % 2 != 0:\n",
" c.remove(i)\n",
"print(c)"
],
"language": "python",
"metadata": {},
"outputs": [
{
"output_type": "stream",
"stream": "stdout",
"text": [
"[2, 4, 6]\n"
]
}
],
"prompt_number": 6
},
{
"cell_type": "code",
"collapsed": false,
"input": [
"not 4 % 2"
],
"language": "python",
"metadata": {},
"outputs": [
{
"metadata": {},
"output_type": "pyout",
"prompt_number": 9,
"text": [
"True"
]
}
],
"prompt_number": 9
},
{ {
"cell_type": "code", "cell_type": "code",
"collapsed": false, "collapsed": false,