diff --git a/03-arrays/tf-03.py b/03-arrays/tf-03.py index 130f216..e220035 100644 --- a/03-arrays/tf-03.py +++ b/03-arrays/tf-03.py @@ -1,25 +1,24 @@ import sys, string import numpy as np -# Get an array of characters from the file, make sure it starts and ends with a space -# Example input: "Hello World! " -characters = np.array([' '] + list(open(sys.argv[1]).read()) + [' ']) +# Example input: "Hello World!!" +characters = np.array([' ']+list(open(sys.argv[1]).read())+[' ']) # Result: array([' ', 'H', 'e', 'l', 'l', 'o', ' ', ' ', -# 'W', 'o', 'r', 'l', 'd', '!', ' ', ' '], dtype=' 1] # Result: [array([' ', 'h', 'e', 'l', 'l', 'o'], dtype='