for (int i = 0; i < ns.length; i++) { for (int j = 1; j < ns.length - i; j++) { if (ns[j - 1] < ns[j]) { int temp = ns[j]; ns[j] = ns[j - 1]; ns[j - 1] = temp; } }}
Sign in to make a reply
高处不胜寒