I am currently using the Numpy
package (version 1.12.1) in Spyder
(Python 3.6
).
For some reason I am unable to remove 'b's
which appear before strings in the IPython
Console.
import numpy as np
student = np.dtype([('name', 'S20'), ('age', 'i1'), ('code', 'i4')])
print (student)
recordsvar = np.array([('Cordelia',28,100),('Cordelia',29,101),
('Cordelia',30,102)], dtype=student)
print (recordsvar)
The output is
[(b'Cordelia', 28, 100) (b'Cordelia', 29, 101) (b'Cordelia', 30, 102)]
How do I remove the 'b' in from of Cordelia?
Thanks in advance