java Sum using Array October 10, 2017 Java No comments public class sumArray { public static void main(String args[]) { int array[]={12,13,141,11,12,21}; int sum=0; for(int i=0;i<=5;i++) { sum+=array[i]; } System.out.println("The sum of number is :"+sum); }} Share This: Facebook Twitter Google+ Stumble Digg Email ThisBlogThis!Share to XShare to Facebook
0 comments:
Post a Comment