% % Input a string and print it in reversed order. % str=input('Give a string'); n=length(str); % The length of the string. for i=n:-1:1 % the loop from the end to the begining. disp(str(i)); end