updated code to use strings

faster processing and calculations using strings instead of arrays