Loops are very important terms in programming. The loops are use for the repeation of a instruction in a programming . Condition can also be apply in loops according to the problems.
Source Code
package com.ancodingpoint.www; import java.util.Scanner; public class Arrays_sorting{ public static void main(String[] args) { Scanner input = new Scanner (System.in); int num [] = new int [5]; for( int i =0; i<5;i++ ) { System.out.println(" Enter Your Number Here......!"); num[i] = input.nextInt(); } System.out.println(" These Number are Taken with using for Loop !"); for (int i =0; i <5; i++) { System.out.println(num[i]); } } }
0 comments:
Post a Comment