added reversal of strings