Arrays_bubble-sort Codeing ruuning but TCs are getting failed

import java.util.*;
public class Main {

public static void Bubble_sort (int[] arr) { // bubble sort

	int counter = 0;
	while (counter < arr.length) {
		for (int i = 0; i < arr.length - 1; i++) {
			if (arr[i] > arr[i + 1]) {
				int temp = arr[i];
				arr[i] = arr[i + 1];
				arr[i + 1] = temp;
			}
		}
		counter++;
	}
}

public static void display(int[] arr) {
	for (int i = 0; i < arr.length; i++) {
		System.out.print(arr[i] + ", ");
	}
}

static Scanner scn = new Scanner(System.in);

public static int[] takeInput() {

	// System.out.println("size ?");
	int N = scn.nextInt();
	int[] Array = new int[N];
	for (int i = 0; i < Array.length; i++) {
		// System.out.println("Enter the vaue for " + i + " index ? ");
		Array[i] = scn.nextInt();
	}
	return Array;
}
public static void main(String args[]) {
	// int arr[] = {1,4,2,99,5,105,0,6};
	int[] Array = takeInput();
	Bubble_sort(Array);
	display(Array);
}

}

please check the format of output here: https://hack.codingblocks.com/app/contests/1309/190/problem
the output is supposed to be new line separated not comma separated.
Thanks

I hope I’ve cleared your doubt. I ask you to please rate your experience here
Your feedback is very important. It helps us improve our platform and hence provide you
the learning experience you deserve.

On the off chance, you still have some questions or not find the answers satisfactory, you may reopen
the doubt.