上一页 1 2 3 4 5 6 7 ··· 14 下一页
摘要: 环境: SpringBoot pom依赖了apache.commons.HttpClient: <! httpclient commons httpclient commons httpclient 3.1 问题: 调用httpClient时会输出一堆相关的debug日志。 解决: 官方提供了log 阅读全文
posted @ 2017-08-21 16:07 puyangsky 阅读(3930) 评论(0) 推荐(1)
摘要: 142. Linked List Cycle II Given a linked list, return the node where the cycle begins. If there is no cycle, return null. Note: Do not modify the link 阅读全文
posted @ 2017-06-27 13:27 puyangsky 阅读(360) 评论(0) 推荐(0)
摘要: 数据结构——Trie树 概念 Trie树,又称字典树、前缀树,是一种树形结构,是一种哈希树的变种。典型应用是用于统计,排序和保存大量的字符串(但不仅限于字符串),所以经常被搜索引擎系统用于文本词频统计。它的优点是:利用字符串的公共前缀来减少查询时间,最大限度地减少无谓的字符串比较,查询效率比哈希树高 阅读全文
posted @ 2017-06-19 15:52 puyangsky 阅读(507) 评论(0) 推荐(0)
摘要: 动态规划经典题之最长公共子序列 参考: "最长公共子序列与最长公共子串" 概念 最长公共子序列: 两个字符串中相同的子串序列,可以不连续。 最长公共子串: 两个字符串中相同的连续子串。 这两者的区别就在于子串是否需要连续。 状态转移方程 最长公共子串: 我们记c[i, j]为x和y在长度为i和j时的 阅读全文
posted @ 2017-06-19 14:41 puyangsky 阅读(902) 评论(0) 推荐(0)
摘要: 583. Delete Operation for Two Strings Given two words word1 and word2, find the minimum number of steps required to make word1 and word2 the same, whe 阅读全文
posted @ 2017-06-16 16:47 puyangsky 阅读(767) 评论(0) 推荐(0)
摘要: SpringBoot入门及基本使用 SpringBoot的介绍我就不多说了,核心的就是“约定大于配置”,接下来直接上干货吧! 本文的实例: "github LPCloud" ,欢迎star&fork。 SpringBoot基础配置 web.xml保持原样即可: <! <welcome file li 阅读全文
posted @ 2017-05-09 18:24 puyangsky 阅读(849) 评论(0) 推荐(0)
摘要: 调用ByteBuffer.getInt()方法遇到的奇怪错误 最近在参加阿里的中间件比赛,中间用到了RocketMQ的思想,并且主要集中在使用NIO来读写文件。其中遇到了一个很蛋疼的问题,想了半天想不出来为什么,现已解决并来记录一下。 先上代码: @Test public void test() t 阅读全文
posted @ 2017-05-06 20:48 puyangsky 阅读(8629) 评论(0) 推荐(0)
摘要: 回溯法的应用 原题 Given n pairs of parentheses, write a function to generate all combinations of well formed parentheses. For example, given n = 3, a solution 阅读全文
posted @ 2017-04-27 17:11 puyangsky 阅读(420) 评论(0) 推荐(0)
摘要: JVM学习笔记二之GC GC即垃圾回收,在C++中垃圾回收由程序员自己来做,例如可以用free和delete来回收对象。而在Java中,JVM替程序员来执行垃圾回收的工作,下面看看GC的详细原理和执行过程。 1.对象已死? 1.1 引用计数法 Java GC不采用引用计数法是因为无法解决对象互相引用 阅读全文
posted @ 2017-04-16 21:58 puyangsky 阅读(402) 评论(0) 推荐(0)
摘要: 在K8s中创建StatefulSet 遇到的问题: 使用Deployment创建的Pod是无状态的,当挂在Volume之后,如果该Pod挂了,Replication Controller会再run一个来保证可用性,但是由于是无状态的,Pod挂了的时候与之前的Volume的关系就已经断开了,新起来的P 阅读全文
posted @ 2017-04-07 11:30 puyangsky 阅读(21103) 评论(0) 推荐(0)
上一页 1 2 3 4 5 6 7 ··· 14 下一页