diff options
Diffstat (limited to 'C++_from_the_Ground')
-rw-r--r-- | C++_from_the_Ground/Chapter_10(1).ipynb | 3 | ||||
-rw-r--r-- | C++_from_the_Ground/Chapter_12(1).ipynb | 7 | ||||
-rw-r--r-- | C++_from_the_Ground/Chapter_16(1).ipynb | 8 | ||||
-rw-r--r-- | C++_from_the_Ground/Chapter_18(1).ipynb | 50 | ||||
-rw-r--r-- | C++_from_the_Ground/Chapter_19(1).ipynb | 5 | ||||
-rw-r--r-- | C++_from_the_Ground/Chapter_2(1).ipynb | 32 | ||||
-rw-r--r-- | C++_from_the_Ground/Chapter_20(2).ipynb | 7 | ||||
-rw-r--r-- | C++_from_the_Ground/Chapter_21(1).ipynb | 34 | ||||
-rw-r--r-- | C++_from_the_Ground/Chapter_22(1).ipynb | 5 | ||||
-rw-r--r-- | C++_from_the_Ground/Chapter_3(1).ipynb | 9 | ||||
-rw-r--r-- | C++_from_the_Ground/Chapter_4(1).ipynb | 10 | ||||
-rw-r--r-- | C++_from_the_Ground/Chapter_5(1).ipynb | 4 | ||||
-rw-r--r-- | C++_from_the_Ground/Chapter_7(1).ipynb | 37 | ||||
-rw-r--r-- | C++_from_the_Ground/Chapter_8(1).ipynb | 5 | ||||
-rw-r--r-- | C++_from_the_Ground/Chapter_9(1).ipynb | 17 |
15 files changed, 77 insertions, 156 deletions
diff --git a/C++_from_the_Ground/Chapter_10(1).ipynb b/C++_from_the_Ground/Chapter_10(1).ipynb index 77fa05ce..b19c3a4c 100644 --- a/C++_from_the_Ground/Chapter_10(1).ipynb +++ b/C++_from_the_Ground/Chapter_10(1).ipynb @@ -1,7 +1,7 @@ { "metadata": { "name": "", - "signature": "sha256:369d1716e7a65538ad06381f5a1cdafc97ddfbad9ccd970d060ca5c894a6593b" + "signature": "sha256:73c04e2c14bfab695e4acf07dc7752334b6372d624570a4e051fd91aeeb761f7" }, "nbformat": 3, "nbformat_minor": 0, @@ -329,7 +329,6 @@ " a=None\n", " b=None\n", "\n", - "#Recieve and return by reference\n", "def f(var):\n", " var[0].a=var[0].a*var[0].a\n", " var[0].b=var[0].b/var[0].b\n", diff --git a/C++_from_the_Ground/Chapter_12(1).ipynb b/C++_from_the_Ground/Chapter_12(1).ipynb index f92ff06c..a29c9b4d 100644 --- a/C++_from_the_Ground/Chapter_12(1).ipynb +++ b/C++_from_the_Ground/Chapter_12(1).ipynb @@ -1,7 +1,7 @@ { "metadata": { "name": "", - "signature": "sha256:16b30eb675083837fc31b76aa8f3c6bd5549baef25d739f4f8bead7d865cbcbf" + "signature": "sha256:0b4a52abc3f3246965d1e59241352e867e78e448510ae25e91b7d38dc4dcc202" }, "nbformat": 3, "nbformat_minor": 0, @@ -555,8 +555,7 @@ "cell_type": "code", "collapsed": false, "input": [ - "'''Passing objects by reference'''\n", - "\n", + " \n", "from ctypes import *\n", "class myclass:\n", " def __init__(self,i):\n", @@ -653,7 +652,7 @@ "collapsed": false, "input": [ "\n", - "#\n", + "\n", "class sample:\n", " __s=None\n", " def __init__(self):\n", diff --git a/C++_from_the_Ground/Chapter_16(1).ipynb b/C++_from_the_Ground/Chapter_16(1).ipynb index 941febba..98e3dc8a 100644 --- a/C++_from_the_Ground/Chapter_16(1).ipynb +++ b/C++_from_the_Ground/Chapter_16(1).ipynb @@ -1,7 +1,7 @@ { "metadata": { "name": "", - "signature": "sha256:bbf24dca4298d6f4bb5217612c0027ad0473157ec0c530ae82f2e0944bb06ddf" + "signature": "sha256:60d976a21b55caeaa47bb2c8586e986eed54234a29f15a816e7270f74ad2660e" }, "nbformat": 3, "nbformat_minor": 0, @@ -215,8 +215,7 @@ "cell_type": "code", "collapsed": false, "input": [ - "\n", - "#Display data specified number of times.\n", + " \n", "def repeat(data,times):\n", " while times:\n", " print data\n", @@ -415,8 +414,7 @@ "cell_type": "code", "collapsed": false, "input": [ - "\n", - "#Defining constant\n", + " \n", "def SIZE():\n", " return 10\n", "\n", diff --git a/C++_from_the_Ground/Chapter_18(1).ipynb b/C++_from_the_Ground/Chapter_18(1).ipynb index e2cae07f..df4cabc2 100644 --- a/C++_from_the_Ground/Chapter_18(1).ipynb +++ b/C++_from_the_Ground/Chapter_18(1).ipynb @@ -1,7 +1,7 @@ { "metadata": { "name": "", - "signature": "sha256:3dbb4b61b32533eb72607c7c790e9f8f91b9c2e123ddbd5190ffe13a1b2b7647" + "signature": "sha256:85eae8322c208f1f26e859bb0f4dac6f86b35c3ac105ed98ac2d0fbf05287f0e" }, "nbformat": 3, "nbformat_minor": 0, @@ -410,11 +410,10 @@ "cell_type": "code", "collapsed": false, "input": [ - "\n", - "#Open a file, creating one if it does not already exist\n", + " \n", "out=open(\"test\",'w')\n", "\n", - "#In case file cannot open\n", + "\n", "if(not(out)):\n", " print \"Cannot open file.\"\n", "else:\n", @@ -441,10 +440,9 @@ "collapsed": false, "input": [ "\n", - "#Open a file, creating one if it does not already exist\n", + " \n", "In=open(\"test\",'r')\n", - "\n", - "#In case file cannot open\n", + " \n", "if(not(In)):\n", " print \"Cannot open file.\"\n", "else:\n", @@ -668,27 +666,24 @@ "cell_type": "code", "collapsed": false, "input": [ - "\n", - "#creating test1\n", + " \n", "out=open(\"test1\",'w')\n", "out.write(\"Hello\")\n", "out.close()\n", - "\n", - "#creating test2\n", + " \n", "out=open(\"test2\",'w')\n", "out.write(\"There\")\n", "out.close()\n", "\n", - "\n", - "#Open test1\n", + " \n", "f1=open(\"test1\",'r')\n", - "#In case file cannot open\n", + " \n", "if(not(In)):\n", " print \"Cannot open file.\"\n", "\n", - "#Open test2\n", + " \n", "f2=open(\"test2\",'r')\n", - "#In case file cannot open\n", + " \n", "if(not(In)):\n", " print \"Cannot open file.\"\n", " \n", @@ -703,7 +698,7 @@ " f1.close()\n", " f2.close()\n", "else:\n", - " #compare contents of buffers\n", + " \n", " flag=1\n", " for i in range(len(buf1)):\n", " if not(buf1[i]==buf2[i]):\n", @@ -745,8 +740,7 @@ "input": [ "\n", "print \"Enter your name:\"\n", - "\n", - "#User imput\n", + " \n", "str=\"hello world\"\n", "\n", "print str" @@ -776,13 +770,10 @@ "cell_type": "code", "collapsed": false, "input": [ - "\n", - "#Open test\n", - "out=open(\"test\",'r+b')\n", + " out=open(\"test\",'r+b')\n", "out.write(\"Hello\")\n", "\n", - "\n", - "#In case file cannot open\n", + " \n", "if(not(out)):\n", " print \"Cannot open file.\"\n", "else:\n", @@ -808,13 +799,13 @@ "collapsed": false, "input": [ "\n", - "#Open test\n", + " \n", "out=open(\"test\",'r+b')\n", "out.write(\"Hello\")\n", "out.close()\n", "\n", "In=open(\"test\",'r')\n", - "#In case file cannot open\n", + " \n", "if(not(In)):\n", " print \"Cannot open file.\"\n", "else:\n", @@ -857,14 +848,13 @@ " c=(\"%d\"%self.__x)+\", \"+(\"%d\"%self.__y)+\", \"+(\"%d\"%self.__z)+\"\\n\"\n", " return c \n", "\n", - "#Variable declaration\n", + " \n", "a=three_d(1,2,3)\n", "b=three_d(3,4,5)\n", "c=three_d(5,6,7)\n", - "\n", - "#Open threed\n", + " \n", "out=open(\"threed\",'w')\n", - "#In case file cannot open\n", + " \n", "if(not(out)):\n", " print \"Cannot open file.\"\n", "else:\n", diff --git a/C++_from_the_Ground/Chapter_19(1).ipynb b/C++_from_the_Ground/Chapter_19(1).ipynb index 3c9ecd17..7f04b7ea 100644 --- a/C++_from_the_Ground/Chapter_19(1).ipynb +++ b/C++_from_the_Ground/Chapter_19(1).ipynb @@ -1,7 +1,7 @@ { "metadata": { "name": "", - "signature": "sha256:d2c5aefc81786f6e7a83b5f07eeb250789c73d2ab2ad23662758aa0cdec50617" + "signature": "sha256:20d38d92a3a25bc02f8bf5fb1b35ef1503e1987dff61d43c4881deab4561fe2c" }, "nbformat": 3, "nbformat_minor": 0, @@ -273,8 +273,7 @@ "cell_type": "code", "collapsed": false, "input": [ - "\n", - "#Template class\n", + " \n", "class myclass:\n", " def __init__(self,i):\n", " self.__a=i\n", diff --git a/C++_from_the_Ground/Chapter_2(1).ipynb b/C++_from_the_Ground/Chapter_2(1).ipynb index 603f2bab..b3976867 100644 --- a/C++_from_the_Ground/Chapter_2(1).ipynb +++ b/C++_from_the_Ground/Chapter_2(1).ipynb @@ -1,7 +1,7 @@ { "metadata": { "name": "", - "signature": "sha256:2822ffa73df44943f6be3bedb4cf89d60d9228e7b719790e40dca7bc4236f0b9" + "signature": "sha256:05876b24f412fcea817693bad944dc90f3dae4fb5142aeb7d9c2c98569067083" }, "nbformat": 3, "nbformat_minor": 0, @@ -27,7 +27,6 @@ "collapsed": false, "input": [ "\n", - "#Result\n", "print \"This is my first C++ program.\"" ], "language": "python", @@ -54,10 +53,7 @@ "cell_type": "code", "collapsed": false, "input": [ - "'\n", - "\n", - "\n", - "#Variable Declaration\n", + " \n", "x=None \n", "\n", "x=1023 #this assigns 1023 to x\n", @@ -160,10 +156,7 @@ "cell_type": "code", "collapsed": false, "input": [ - "\n", - "\n", - "\n", - "#myfunc's definition\n", + " \n", "def myfunc():\n", " print \"Inside myfunc() \"\n", " \n", @@ -197,10 +190,7 @@ "cell_type": "code", "collapsed": false, "input": [ - "\n", - "\n", - "\n", - "#Result\n", + " \n", "print abs(-10)" ], "language": "python", @@ -227,9 +217,7 @@ "cell_type": "code", "collapsed": false, "input": [ - "\n", - "\n", - "#mul's definition\n", + " \n", "def mul(x,y):\n", " print x*y,\n", "\n", @@ -262,9 +250,7 @@ "cell_type": "code", "collapsed": false, "input": [ - "\n", - "\n", - "#mul()'s definition; this function returns a value\n", + " \n", "def mul(x,y):\n", " return x*y #return product of x and y\n", "\n", @@ -330,8 +316,7 @@ "cell_type": "code", "collapsed": false, "input": [ - "'''This program illustrates the if statement'''\n", - "\n", + " \n", "#Variable declaration\n", "a=10 #user input for two numbers\n", "b=20\n", @@ -393,8 +378,7 @@ "cell_type": "code", "collapsed": false, "input": [ - "\n", - "#Variable declaration\n", + " \n", "a=10 #User input for two numbers\n", "b=20\n", "\n", diff --git a/C++_from_the_Ground/Chapter_20(2).ipynb b/C++_from_the_Ground/Chapter_20(2).ipynb index e56ad6fd..8771c6cd 100644 --- a/C++_from_the_Ground/Chapter_20(2).ipynb +++ b/C++_from_the_Ground/Chapter_20(2).ipynb @@ -1,7 +1,7 @@ { "metadata": { "name": "", - "signature": "sha256:c2dea3221dd29327bd680c1c48d2d9bcb943c373644635507698dc8145b7a0c6" + "signature": "sha256:aed4cbb1750b5cf45152f9d0ded2a9f36978f3177285c38b159fb79a8b0d35e4" }, "nbformat": 3, "nbformat_minor": 0, @@ -104,7 +104,7 @@ "cell_type": "code", "collapsed": false, "input": [ - "'\n", + " \n", "class CounterNameSpace:\n", " upperbound=None\n", " lowerbound=None\n", @@ -290,8 +290,7 @@ "cell_type": "code", "collapsed": false, "input": [ - "\n", - "#functions\n", + " \n", "def vline(i):\n", " for j in xrange(i,0,-1):\n", " print \"|\"\n", diff --git a/C++_from_the_Ground/Chapter_21(1).ipynb b/C++_from_the_Ground/Chapter_21(1).ipynb index 023fd126..76345922 100644 --- a/C++_from_the_Ground/Chapter_21(1).ipynb +++ b/C++_from_the_Ground/Chapter_21(1).ipynb @@ -1,7 +1,7 @@ { "metadata": { "name": "", - "signature": "sha256:0975c16101ec7adc0b19a0a24a31504acce776790d976f2710d7048c660d7882" + "signature": "sha256:1f6065242a1ea235eb4712b9ec147fb29625df8861301b52ad6c880a94467811" }, "nbformat": 3, "nbformat_minor": 0, @@ -26,16 +26,11 @@ "cell_type": "code", "collapsed": false, "input": [ - "\n", - "\n", - "#Variable declaratio\n", + " \n", "v=[] #Create a zero length vector\n", - "\n", - "#display original size of v\n", + " \n", "print \"Size =\",len(v)\n", - "\n", - "#put values onto end of vector\n", - "#vector will grow as needed\n", + " \n", "\n", "for i in range(10):\n", " v.append(i)\n", @@ -304,9 +299,7 @@ "cell_type": "code", "collapsed": false, "input": [ - "\n", - " \n", - "#Variable declaration\n", + " \n", "v=[]\n", "v2=[]\n", "\n", @@ -699,8 +692,7 @@ "cell_type": "code", "collapsed": false, "input": [ - "\n", - "#define the function find\n", + " \n", "def find(x,ch):\n", " for p in x:\n", " if p[0].get()==ch.get():\n", @@ -766,9 +758,6 @@ "cell_type": "code", "collapsed": false, "input": [ - "\n", - "\n", - "#This is a unary precdate that determines if character is a vowel\n", "def isvowel(ch):\n", " ch=ch.lower()\n", " if (ch=='a' or ch=='e'or ch=='i' or ch=='o' or ch=='u'):\n", @@ -886,9 +875,7 @@ "cell_type": "code", "collapsed": false, "input": [ - "\n", - "\n", - "#Variable declaration\n", + " \n", "v=[]\n", "\n", "for i in range(10):\n", @@ -933,9 +920,7 @@ "cell_type": "code", "collapsed": false, "input": [ - "\n", - "\n", - "#A simple transformaton function\n", + " \n", "def xform(i):\n", " return i*i #square original value\n", "\n", @@ -1147,8 +1132,7 @@ "cell_type": "code", "collapsed": false, "input": [ - "\n", - "#define the function find\n", + " \n", "def find(x,ch):\n", " for p in x:\n", " if p[0]==ch:\n", diff --git a/C++_from_the_Ground/Chapter_22(1).ipynb b/C++_from_the_Ground/Chapter_22(1).ipynb index 8c26974a..39b8cb88 100644 --- a/C++_from_the_Ground/Chapter_22(1).ipynb +++ b/C++_from_the_Ground/Chapter_22(1).ipynb @@ -1,7 +1,7 @@ { "metadata": { "name": "", - "signature": "sha256:53f00d75f5adfa37af0d8067426691c881e1b4ea1e38045c3a67a88230ca00f5" + "signature": "sha256:2d1838d005f866ea4e20c93ff6de54ebfd0d0c26c2e3055fc05467a06502c1dc" }, "nbformat": 3, "nbformat_minor": 0, @@ -248,8 +248,7 @@ "input": [ "\n", "import inspect\n", - "\n", - "#Returns the current line number in our program.\n", + " \n", "def lineno():\n", " return inspect.currentframe().f_back.f_lineno\n", " \n", diff --git a/C++_from_the_Ground/Chapter_3(1).ipynb b/C++_from_the_Ground/Chapter_3(1).ipynb index 19f2cea0..9d0cf326 100644 --- a/C++_from_the_Ground/Chapter_3(1).ipynb +++ b/C++_from_the_Ground/Chapter_3(1).ipynb @@ -1,7 +1,7 @@ { "metadata": { "name": "", - "signature": "sha256:a048620e2c0a121c8dd48d68bd57c4172e8820ecd9345c7b4ca01d8f4f4621a3" + "signature": "sha256:13095677f4efa0909d9aeb25aa7b8b57bea864fd1d9a0a797f9e06000e52dc18" }, "nbformat": 3, "nbformat_minor": 0, @@ -179,9 +179,7 @@ "cell_type": "code", "collapsed": false, "input": [ - "\n", - "\n", - "#prints a newline, a backslash and a backspace\n", + " \n", "print \"\\n\\\\\\b\"\n" ], "language": "python", @@ -300,8 +298,7 @@ "cell_type": "code", "collapsed": false, "input": [ - "\n", - "#the xor function\n", + " \n", "def xor(a,b):\n", " return (a or b)and(not(a and b))\n", "\n", diff --git a/C++_from_the_Ground/Chapter_4(1).ipynb b/C++_from_the_Ground/Chapter_4(1).ipynb index ebd72abc..ca8e76db 100644 --- a/C++_from_the_Ground/Chapter_4(1).ipynb +++ b/C++_from_the_Ground/Chapter_4(1).ipynb @@ -1,7 +1,7 @@ { "metadata": { "name": "", - "signature": "sha256:7a7e07f5e71ec203dfa93cc13b4ce9de80c80af3b59f8d7d6bebe41c247db83e" + "signature": "sha256:f944500666c92742656b5a25638e93a82042acafb19b205aac684e2d9ac2df51" }, "nbformat": 3, "nbformat_minor": 0, @@ -425,9 +425,7 @@ "cell_type": "code", "collapsed": false, "input": [ - "\n", - "\n", - "#Displaying the menu\n", + " \n", "print \"Help on:\"\n", "print \"1. for\"\n", "print \"2. if\"\n", @@ -517,9 +515,7 @@ "cell_type": "code", "collapsed": false, "input": [ - "\n", - "'''Displays all printable characters.'''\n", - "\n", + " \n", "#Variable decleration\n", "ch = 32\n", "\n", diff --git a/C++_from_the_Ground/Chapter_5(1).ipynb b/C++_from_the_Ground/Chapter_5(1).ipynb index adbe1235..13085f5e 100644 --- a/C++_from_the_Ground/Chapter_5(1).ipynb +++ b/C++_from_the_Ground/Chapter_5(1).ipynb @@ -1,7 +1,7 @@ { "metadata": { "name": "", - "signature": "sha256:daa9c054e3b743c745cfe62599d80f03d625b2ef5131489390410210f502a5cb" + "signature": "sha256:f41d93d043c68dcb6af847a40af38d47fc3a3d45c60675afb574707e38d804d9" }, "nbformat": 3, "nbformat_minor": 0, @@ -206,7 +206,7 @@ "\n", "print \"Enter a string: \"\n", "\n", - "#user input\n", + " \n", "str = \"Hello\"\n", "\n", "#Result\n", diff --git a/C++_from_the_Ground/Chapter_7(1).ipynb b/C++_from_the_Ground/Chapter_7(1).ipynb index 28829c6d..027b30f5 100644 --- a/C++_from_the_Ground/Chapter_7(1).ipynb +++ b/C++_from_the_Ground/Chapter_7(1).ipynb @@ -1,7 +1,7 @@ { "metadata": { "name": "", - "signature": "sha256:9a6978851f88c0c91bde88465299d72777f3dae7854964b1cadad7b80092df72" + "signature": "sha256:ab47bb393809bc88589e7e92320813b90077813594dc417229af49780e24b53b" }, "nbformat": 3, "nbformat_minor": 0, @@ -254,8 +254,7 @@ "input": [ "\n", "from ctypes import *\n", - "\n", - "#Function to change the reference value\n", + " \n", "def f(j):\n", " j[0]=100 #j is assigned 100\n", "\n", @@ -295,7 +294,7 @@ "\n", "from ctypes import *\n", "\n", - "#Function to change the reference value\n", + " \n", "def f(j):\n", " j[0]=100 #j is assigned 100\n", "\n", @@ -332,8 +331,7 @@ "cell_type": "code", "collapsed": false, "input": [ - "\n", - "#function to print some nos.\n", + " \n", "def display(num):\n", " for i in range(10):\n", " print num[i],\n", @@ -370,9 +368,7 @@ "cell_type": "code", "collapsed": false, "input": [ - "\n", - "\n", - "#Print some nos.\n", + " \n", "def display(num):\n", " print num,\n", "\n", @@ -410,9 +406,7 @@ "cell_type": "code", "collapsed": false, "input": [ - "\n", - "\n", - "#Function to convert into cubes\n", + " \n", "def cube(n,num):\n", " num-=1\n", " while num:\n", @@ -502,8 +496,7 @@ "cell_type": "code", "collapsed": false, "input": [ - "\n", - "#Function to fond length\n", + " \n", "def mystrlen(str):\n", " l=len(str)\n", " return l\n", @@ -572,7 +565,6 @@ "cell_type": "code", "collapsed": false, "input": [ - "'''The program prints all command line arguments '''\n", "import sys\n", "\n", "#Result\n", @@ -721,9 +713,7 @@ "cell_type": "code", "collapsed": false, "input": [ - "\n", - "\n", - "#Return index of substring or -1 if not found.\n", + " \n", "def find_substr(sub,str):\n", " l=str.find(sub)\n", " return l\n", @@ -794,8 +784,7 @@ "cell_type": "code", "collapsed": false, "input": [ - "\n", - "#Return position of substring\n", + " \n", "def find_substr(sub,str):\n", " return str.find(sub)\n", "\n", @@ -831,9 +820,7 @@ "cell_type": "code", "collapsed": false, "input": [ - "\n", - "\n", - "#Recursive version\n", + " \n", "def factr(n):\n", " if n==1:\n", " return 1\n", @@ -880,9 +867,7 @@ "cell_type": "code", "collapsed": false, "input": [ - "\n", - "\n", - "#Reversing a string\n", + " \n", "def reverse(s):\n", " r = \"\"\n", " for c in s:\n", diff --git a/C++_from_the_Ground/Chapter_8(1).ipynb b/C++_from_the_Ground/Chapter_8(1).ipynb index 3092696e..4684861e 100644 --- a/C++_from_the_Ground/Chapter_8(1).ipynb +++ b/C++_from_the_Ground/Chapter_8(1).ipynb @@ -1,7 +1,7 @@ { "metadata": { "name": "", - "signature": "sha256:cea79a35a095750f932030d193b34f2136c703d7c2c54113f8e7917863a4322a" + "signature": "sha256:cb32b4e80623f372b375323b458cf1a594dc5626da9cbe9346e1ec33417221d4" }, "nbformat": 3, "nbformat_minor": 0, @@ -427,8 +427,7 @@ "cell_type": "code", "collapsed": false, "input": [ - "\n", - "#myabs() in three ways\n", + " \n", "def myabs(i):\n", " if isinstance(i,int): #first instance\n", " print \"Using integer myabs(): \",\n", diff --git a/C++_from_the_Ground/Chapter_9(1).ipynb b/C++_from_the_Ground/Chapter_9(1).ipynb index 9e6e1729..0f30e9a8 100644 --- a/C++_from_the_Ground/Chapter_9(1).ipynb +++ b/C++_from_the_Ground/Chapter_9(1).ipynb @@ -1,7 +1,7 @@ { "metadata": { "name": "", - "signature": "sha256:9ff1f12edc348acd1b1c3b16cc9a9556459332fb35a1337252165631b4cd82af" + "signature": "sha256:441f69a4dc3d0bee097a6151c42e10920892966ba4b3b82086ec3feb521e7da7" }, "nbformat": 3, "nbformat_minor": 0, @@ -257,8 +257,7 @@ "cell_type": "code", "collapsed": false, "input": [ - "\n", - "#Array of strings that correspond to the enumeration\n", + " \n", "name=[\"Jonathan\",\"Golden Delicious\",\"Red Delicious\",\"Winesap\",\n", " \"Cortland\",\"McIntosh\"]\n", "\n", @@ -300,9 +299,7 @@ "cell_type": "code", "collapsed": false, "input": [ - "\n", - "\n", - "#Variable declaration\n", + " \n", "ch='j' #User input\n", "while True:\n", " #This statement turns off the 6th but.\n", @@ -391,9 +388,7 @@ "cell_type": "code", "collapsed": false, "input": [ - "\n", - "\n", - "#function to display the bits\n", + " \n", "def disp_binary(u):\n", " t=128\n", " while t:\n", @@ -438,9 +433,7 @@ "cell_type": "code", "collapsed": false, "input": [ - "\n", - "\n", - "#unction to display the bits within a byte\n", + " \n", "def disp_binary(u):\n", " t=128\n", " while t:\n", |