This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import java.util.Scanner; | |
public class CountingSort | |
{ | |
//method to get the maximum element from the array | |
private int getMax(int a[],int size) | |
{ | |
int max=a[0]; | |
for (int i = 1; i < size; i++) | |
{ |