![](https://img-blog.csdnimg.cn/20201014180756928.png?x-oss-process=image/resize,m_fixed,h_64,w_64)
java
Alex_houjie
从事6年互联网+物联网通 2年软件编程(java)
展开
-
贪心算法(背包问题)
1.有一个背包,容量是c,有若干物品,价值各不相同,重量也各不相同。选择一部分物品装入背包,要保证不超过背包容量的前提下,背包的物品总价值最大。补充一点:允许选择一份物品的一部分,比如 0.2份 A物品,0.5份 C物品。public class TanXin { public static void main(String[] args) { int capacity = 10; int[] weights = {4,6,3,2,5}; i原创 2021-11-20 14:54:31 · 1349 阅读 · 0 评论 -
java的快速排序法
public class TestQickSort { public static void main(String[] args) { int array[] = {11, 77,22, 1, 2, 3, 12, 2,88, 103,21, 32,99,102, 12,99,44,33,22,11,333,444,3332,12}; int[] ints = quickSort(array, 0, array.length - 1); for (i.原创 2020-07-16 01:17:16 · 141 阅读 · 1 评论 -
AOP的三种开发方式 bean.xml 配置 、注解+配置 、全注解
第一章 Aop 切面编程的三种配置使用aop切面编程的准配的jarcom.springsource.net.sf.cglib-2.1.3.jarcom.springsource.org.aopalliance-1.0.0.jarcom.springsource.org.aspectj.weaver-1.6.8.RELEASE.jarcommons-logging-1.2.jarspring-aop-5.2.7.RELEASE.jarjunit-4.12.jarhamcrest-core原创 2020-07-16 01:15:14 · 544 阅读 · 0 评论