diff --git a/Sorting/Bubble.java b/Sorting/Bubble.java index d22fea6..4ef4720 100644 --- a/Sorting/Bubble.java +++ b/Sorting/Bubble.java @@ -1,9 +1,26 @@ + + +import java.util.Scanner; + public class Bubble { + public static void main(String[] args) { + -public static void main(String[] args) { - - - int a[]= {9,8,7,6,5,4,3,2,1}; + Scanner sc=new Scanner(System.in); + System.out.print("Enter Number of Elements: "); + int n=sc.nextInt(); + int a[]=new int[n]; + for(int i=0;i