- 博客(7)
- 资源 (1)
- 收藏
- 关注
原创 快速排序练习
package com.company.test3;public class MyQuiteSortDemo { public static void main(String[] args) { int[] arr={6,1,2,7,9,3,1,4,5,10,18}; quiteSOrt(arr,0,arr.length-1); for (int i = 0; i < arr.length; i++) { Syste.
2022-01-15 16:37:50
98
原创 java递归练习
package com.company.test3;public class MyFactoralDemo { public static void main(String[] args) { int result = getJc(5); System.out.println(result); } private static int getJc(int i) { //一定要有出口 if(i==1){ .
2022-01-15 15:44:40
56
原创 java冒泡排序法 练习
package com.company.test3;import org.w3c.dom.ls.LSOutput;public class MyBubbleSortDemo { public static void main(String[] args) { int[] arr = {5, 2, 4, 8, 6, 1, 3}; int temp; int a=1; bubble(arr, a); } p.
2022-01-15 15:09:06
116
原创 二分查找法练习
package com.company.test3;import org.w3c.dom.ls.LSOutput;public class MyBinarySearchDemo { public static void main(String[] args) { int [] arr = {1,2,3,4,5,6,7,8,9}; int number = 3; int index =binarySearchForIndex(arr,numb.
2022-01-14 19:43:03
90
原创 Integer数据类型转换
package com.company.test;public class test3 { public static void main(String[] args) { String s = "97 78 52 14 12"; //split字符串切割 String[] strArr = s.split(" "); int[] numberArr = new int[strArr.length]; //把s.
2022-01-12 21:42:27
197
空空如也
TA创建的收藏夹 TA关注的收藏夹
TA关注的人