Deloitte Interview Question

do string reversal in java? and swapping numbers