better code

convert string to char[]