Run Code
|
API
|
Code Wall
|
Misc
|
Feedback
|
Login
|
Theme
|
Privacy
|
Patreon
Selection Sort
class Rextester { public static void main(String args[]) { int A[] = {12,2,8,6,0,3,7,9,4,1,8,-4,-1,7,6,4,25,11,10,15,14,-9}; int indx; int minval; for(int i =0; i<A.length; i++){ indx = i; for(int j = i + 1; j<A.length; j++) { if(A[j] < A[i]) { indx = j; minval = A[indx]; A[indx] = A[i]; A[i] = minval; } } System.out.print(A[i] + ","); } } }
run
|
edit
|
history
|
help
0
This code is not what it seems...
Fgh
Even Numbers
Multiples of 3 and 5
Iterative Merge sort
Coding Challenge - 01 (Even numbers)
amit
JAVA # Dizi Ortalama
java polymorhism
Odd