//升序、降序算法
import java.io.BufferedReader;
import java.io.IOException;
import java.io.InputStreamReader;
public class Bub
{
int arr[];
String a[];
int temp;
public Bub()
{}
void sort1(String[] a)
{
arr = new int[a.length];
for (int i = 0; i <a.length; i++)
{
arr[i] = Integer.parseInt(a[i]);
}
for (int i = 0; i <= 9; i++)
{
for (int j = 9; j > i; j--)
{
if (arr[i] > arr[j])
{
temp = arr[i];
arr[i] = arr[j];
arr[j] = temp;
}
}
}
System.out.print("the first sorting is" + "\n");
for (int i = 0; i < 10; i++)
{
System.out.print(" " + arr[i]);
}
System.out.print("\n" + "**************************" + "\n");
}
/**
* @param args
* @throws IOException
*/
public static void main(String[] args) throws IOException
{
// InputStream obj = new InputStream();
BufferedReader obj = new BufferedReader(new InputStreamReader(System.in));
String[] text = new String[10];
for (int i = 0; i < text.length; i++)
{
text[i] = obj.readLine();
if ("quit".equals(obj))
{
break;
}
}
obj.close();
Bub obj1 = new Bub();
// obj1.sort1(args);
obj1.sort1(text);
}
}