1 2 3 4 5 6 7 8 9 10 11 12  | class Reverse{ public static void main(String args[]){ int num = Integer.parseInt(args[0]); //take argument as command line int remainder, result=0; while(num>0){ remainder = num%10; result = result * 10 + remainder; num = num/10; } System.out.println("Reverse number is : "+result); } }  | 
Description :
This is the one stop educational site for all Electronic and Computer students. If you want to learn something new then we are here to help. We work on Microcontroller projects, Basic Electronics, Digital electronics, Computer projects and also in basic c/c++ programs.
#Home #Sitemap #Resources #Terms of Use
Copyright©2012 electrofriends.com All Rights Reserved
Contact:[email protected]
late binding..
 
when compiled sayas “exception in thread “main” java.lang.arrayindexoutofboundsexception:0 at Reverse.main “
sorry to say your source code is not usefull because the adds cover your code its not able to see your code.