string to integer

added code to convert string to integer