sparsh khandelwal wrote:what i try to do that if i give input "abcd" , then variable a will be = to d ,varibale b=c ,c=b and d=a (according to the input , but face a run time error)
First: when asking a question about an error, you should always specify what the error is, including providing the exact message. I have to admit to never having used findInLine(), but from what I see, I'd care to bet that yours is an IndexOutOfBoundsException.
Second: Your statement above is definitely NOT what I get from reading the API docs for findInLine(). Maybe you could explain why you think it works that way.
"Leadership is nature's way of removing morons from the productive flow" - Dogbert
Articles by Winston can be found here