SHOWING ERROR. THERE IS SOME ERROR IN PRINT STATEMENT

I AM NOT ABLE TO UNDERSTAND WHY THIS IS SHOWING ERROR.

package coding;

public class selection {

public static void main(String[] args) {

	int a[]= {23,56,78,94,55,24};
	bubbleSort(a);
	for(int i : a)
	{
		System.out.print(a[i] + " ");
	}

}

public static void bubbleSort(int b[])
{
	for(int i=0;i<b.length-1;i++)
	{
		for(int j=0;j<b.length-1-i;j++)
		{
			if(b[j]>b[j+1])
			{
				int temp=b[j];
				b[j]=b[j+1];
				b[j+1]=temp;
			}
		}
	}
}

}

Instead of System.out.println(bubblesort(arr)); use bubblesort(arr);

Because bubblesort has void type and will not be returning anything, we cannot use System.out.println(bubblesort(arr)); to call the function