Reverse a string without using built in fuctions.