All pastes #928264 Raw Edit

reverse code

public text v1 · immutable
·published 2008-03-04 22:15 UTC
rendered paste body
public class Reverse
{

 
  

  
   
  public String reverseWord(String word)
  
  {
    if (word.length() <= 1)
    return word;
    
    else 
    {
      return  reverseWord(word.subString(1, word.length()-1));  word.charAt(0);;   
    }
  } 
  
  
  
  
}