" Life is not a problem to be solved but a reality to be experienced! "
© Copyright 2013 - 2024 KUDO.TIPS - All rights reserved.
public static void main(String[] nazwa)
{
int pom, tablica[]={9,6,7};
for (int i=0 ; i<tablica.length;i++)
{
for(int j=0; j<tablica.length;j++)
{
if(tablica[j]<tablica[i])
{
pom=tablica[i];
tablica[i]=tablica[j];
tablica[j]=pom;
}
}
}
for(int i = 0 ; i<tablica.length;i++)
{
System.out.print(tablica[i]+" ");
}
}
}