自定义博客皮肤VIP专享

*博客头图:

格式为PNG、JPG,宽度*高度大于1920*100像素,不超过2MB,主视觉建议放在右侧,请参照线上博客头图

请上传大于1920*100像素的图片!

博客底图:

图片格式为PNG、JPG,不超过1MB,可上下左右平铺至整个背景

栏目图:

图片格式为PNG、JPG,图片宽度*高度为300*38像素,不超过0.5MB

主标题颜色:

RGB颜色,例如:#AFAFAF

Hover:

RGB颜色,例如:#AFAFAF

副标题颜色:

RGB颜色,例如:#AFAFAF

自定义博客皮肤

-+

link98

水呀水,浪呀浪,自己站在沙滩上

  • 博客(129)
  • 资源 (3)
  • 收藏
  • 关注

原创 Linux-管道符、重定向与环境变量

Linux 管道符、重定向与环境变量管道命令符管道命令符 | 的作用是将前一个目录的标准输出当做后一个命令的标准输入,格式为命令A | 命令B例如grep命令(文件搜索命令),通过关键词匹配”/sbin/nologin”找出了所有被限制登录系统个的用户。如果要统计所欲不允许登录的系统的个数,怎么办呢? 首先,grep "/sbin/nologin" /etc/passwd 找出了

2018-01-06 14:13:24 1141

原创 Linux用户身份与文件权限

Linux用户身份与文件权限用户的身份与能力root 为超级用户,但是真正让他成为超级用户的是UID UID:每个用户都有对应的UID值 类型 UID 解释 超级用户 0 即root用户为0 系统用户 1-999 系统服务用户,被限制登录 普通用户 1000- 即普通用户帐户名称与UID保存在/etc/passwd文件中,而帐户密码则保存在/etc/

2018-01-06 10:56:43 444

原创 leetcode-628. Maximum Product of Three Numbers

628. Maximum Product of Three NumbersGiven an integer array, find three numbers whose product is maximum and output the maximum product.Example 1:Input: [1,2,3]Output: 6Example

2018-01-05 11:09:23 332

原创 leetcode-160. Intersection of Two Linked Lists

160. Intersection of Two Linked ListsWrite a program to find the node at which the intersection of two singly linked lists begins.For example, the following two linked lists:A:

2018-01-03 19:08:08 496

原创 《算法图解》示例代码的实现

这几天看了《算法图解》,把里面的示例代码都实现了一边,在 github 上找到了一位朋友的仓库,fork 了他的。里面有我们添加的 Python,Java,C++的实现,欢迎大家 fork!!!附上网址:https://github.com/lynxux/AlgorithmDiagram

2018-01-02 22:05:35 2411 1

原创 leetcode-142. Linked List Cycle II

142. Linked List Cycle IIGiven a linked list, return the node where the cycle begins. If there is no cycle, return null.Note: Do not modify the linked list.Follow up:Can you solve it without using ext

2018-01-01 20:00:36 276

原创 leetcode-141. Linked List Cycle

141. Linked List CycleGiven a linked list, determine if it has a cycle in it.Follow up:Can you solve it without using extra space?题意:判断一个链表是否为一个环?(能否使用O(1)的空间复杂度?)思路:在做过之前的题:287. Find the Duplicate Nu

2018-01-01 19:23:22 269

原创 leetcode-287. Find the Duplicate Number

287. Find the Duplicate NumberGiven an array nums containing n + 1 integers where each integer is between 1 and n (inclusive), prove that at least one duplicate number must exist. Assume that there is

2017-12-27 22:17:38 461

原创 图解HTTP笔记-4(HTTP首部)

HTTP首部HTTP的首部字段根据实际使用用途分为四种:通用首部字段:请求和响应报文都会使用的首部请求首部字段:请求报文的首部响应首部字段:响应报文的首部实体首部字段:实体部分的首部通用首部字段: 首部字段名 说明 Cache-Control 控制缓存的行为 Connection 逐跳首部,连接的管理 Date 创建报文的时间 Pragma 报文指令

2017-12-25 19:55:04 211

原创 leetcode-752. Open the Lock

752. Open the LockYou have a lock in front of you with 4 circular wheels. Each wheel has 10 slots: '0', '1', '2', '3', '4', '5', '6', '7', '8', '9'. The wheels can rotate freely and wrap aro

2017-12-25 12:31:44 1657

原创 leetcode-751. IP to CIDR

751. IP to CIDRGiven a start IP address ip and a number of ips we need to cover n, return a representation of the range as a list (of smallest possible length) of CIDR blocks.A CIDR bloc

2017-12-25 12:28:41 4881

原创 leetcode-747. Largest Number Greater Than Twice of Others

747. Largest Number Greater Than Twice of OthersIn a given integer array nums, there is always exactly one largest element.Find whether the largest element in the array is at least twice as

2017-12-25 12:26:17 829 2

原创 leetcode-565. Array Nesting

565. Array NestingA zero-indexed array A of length N contains all integers from 0 to N-1. Find and return the longest length of set S, where S[i] = {A[i], A[A[i]], A[A[A[i]]], ... } subjected to t

2017-12-23 10:18:31 335

原创 图解http笔记-3(HTTP状态码)

返回结果的HTTP状态码状态码告知了从服务端返回的请求的结果如 200 ok 以 3 位数字 和 原因短语 组成样式类别原因短语1xxInfomational(信息性状态码)接收的请求正在处理2xxSuccess(成功状态码)请求正常处理完毕3xx

2017-12-22 21:41:11 234

原创 Effective Java读书笔记1

一. 考虑用静态工厂方法代替构造方法1. 什么是静态工厂方法注意与设计模式中的工厂模式是不同的,它是用通过专门定义一个类来负责创建其他类的实例,其实例通常拥有共同的父类,其实现主要是靠Java的反射机制。2. 静态工厂方法的优点1.有名称对于一个对象的实例化来说,如果使用构造方法的话,可以使用构造函数的重载来实现不同情况下的实例化,但是由于构造函数的名称都是

2017-12-21 11:58:54 206

原创 leetcode-121. Best Time to Buy and Sell Stock

121. Best Time to Buy and Sell StockSay you have an array for which the ith element is the price of a given stock on day i.If you were only permitted to complete at most one transaction (ie, b

2017-12-21 09:58:24 293

原创 图解http笔记-2

持久连接http的初始版本中,没进行一次http通信就要断开连接。以前传输的内容都是很小的,但是现在,当一个浏览器请求一个有很图片的html网页时,要请求html文档,也要请求图片等资源,就要进行很多次TCP的断开和连接,增加通信的开销。所以就有了HTTP keep-alive的方法:只要一端没有明确提出断开连接,就保持TCP的连接。'Connection': 'keep-

2017-12-21 09:00:26 241

原创 图解http笔记-1

图解http笔记-1http中可使用的方法:Get:获取资源用来请求访问已被URI识别的资源。指定的资源经服务器解析后返回响应内容。Post:传输实体主体和Get很类似,但是一般使用PostPut:传输文件要求在请求报文的主体中包含文件的内容,然后保存在请求URI指定的位置 但是由于http1.1的put方法不带验证机制,所以一般不使用Head:获取报文首部head方法和get方法一样,不过不返回

2017-12-18 23:40:26 236

原创 vim下某些词着色,怎么取消?

后来发现是一不小心按到搜索,变成了搜索着色,取消着色只需要:以下两种都可以::noh:set nohls

2017-12-18 16:02:52 520 1

原创 centOS 下yum安装Python3教程

用yum方式安装python3:sudo yum install epel-releasesudo yum install python34测试:[root@VM_221_21_centos ~]# vim helloworld.py[root@VM_221_21_centos ~]# python helloworld.pyhelloworld

2017-12-17 20:48:06 13435 1

原创 centOS yum出问题解决办法

今天用CentOS的时候,yum安装 python 的时候,提示:error: rpmdb: BDB0113 Thread/process 21814/140288630364160 failed: BDB1507 Thread died in Berkeley DB library,需要用下面两个命令:就可以了[root@VM_221_21_centos ~]# rpm --rebuil

2017-12-17 20:44:54 570

原创 HTTP method POST is not supported by this URL解决方案

在学习慕课网的 servlet 教程的过程中,使用post的转跳页面会提示这个错误后来百度了才知道是重写的 doPost() 方法中的 super() 导致的只需要把这个 super.doPost(req,resp) 注释掉就好了

2017-12-17 19:24:30 1167

原创 leetcode-216. Combination Sum III

216. Combination Sum IIIFind all possible combinations of k numbers that add up to a number n, given that only numbers from 1 to 9 can be used and each combination should be a unique set of nu

2017-12-14 21:13:00 360

原创 idea-jsp out.println方法未找到(cannot be resolve)解决办法

去项目设置里配置tomcat服务器,添加一下   jsp-api.jar也可以把tomcat安装文件夹lib里的所有的库都添加进来

2017-12-11 21:07:01 1985

原创 leeetcode-40. Combination Sum II

40. Combination Sum IIGiven a collection of candidate numbers (C) and a target number (T), find all unique combinations in C where the candidate numbers sums to T.Each number in C may only

2017-12-11 18:50:27 345

原创 leetcode- 39. Combination Sum

39. Combination Sumiven a set of candidate numbers (C) (without duplicates) and a target number (T), find all unique combinations in C where the candidate numbers sums to T.The same repe

2017-12-08 18:29:08 277

原创 leetcode-90. Subsets II

90. Subsets IIGiven a collection of integers that might contain duplicates, nums, return all possible subsets (the power set).Note: The solution set must not contain duplicate subsets.For ex

2017-12-07 21:37:39 161

原创 正则表达式总结(持续更新。。)

正则表达式总结:1. 用\d可以匹配一个数字,\w可以匹配一个字母或数字2. 用*表示任意个字符(包括0个),用+表示至少一个字符,用?表示0个或1个字符,用{n}表示n个字符,用{n,m}表示n-m个字符:3. []表示一个字符的限定4. ^表示行的开头,^\d表示必须以数字开头。$表示行的结束,\d$表示必须以数字结束5. 用()表示的就

2017-12-06 22:26:04 163

原创 JavaScript == 和 ===

js == === !!!对于string,number等基础类型,==和===是有区别的1)不同类型间比较,==之比较“转化成同一类型后的值”看“值”是否相等,===如果类型不同,其结果就是不等,因为js 也是有包装类的,例如 String,Number,Boolean2)同类型比较,直接进行“值”比较,两者结果一样

2017-12-06 21:13:46 165

原创 leetcode-78. Subsets

78. SubsetsGiven a set of distinct integers, nums, return all possible subsets (the power set).Note: The solution set must not contain duplicate subsets.For example,If nums = [1,2,3],

2017-12-06 15:27:23 374

原创 Linux常用命令总结

# Linux常用命令[TOC]常用系统工作命令man命令man命令用于查看各种命令的帮助格式: 命令名称 [命令参数] [命令对象]命令对象一般是指要处理的目标(普通文件/目录文件/用户等等),命令参数会比较麻烦,需要长时间的经验积累才能比较好的把握。[root@host Desktop]# man man[root@host Desktop

2017-12-06 11:16:38 178

原创 Java Socket编程实例

Java Socket编程笔记(注:需要 Java IO相关的知识)1.使用 TCP 连接的demo需要用到 java.net.Socket  和 java.net.ServerSocket ,具体可以查询 API 文档创建 Sever 类和 Client 类作为 demoServer类的实现:import java.io.*;import java.ne

2017-12-03 20:33:31 2956

原创 信息安全概论总结-7

第七章-虚拟专用网技术2017年11月29日 星期三 14:59VPN:virtual private network 两层含义: a. 虚拟的网,只在用户需要时在建立连接 b. 利用公共网络基础设施构成的专用网 1. 优点: 安全性高,成本低,覆盖性好,可扩展性强 2. 分类方式: a. 接入方式分类

2017-12-02 10:46:10 314

原创 信息安全概论总结-6

第六章-入侵检测技术2017年11月29日 星期三 9:04入侵检测技术定义“通过对行为,安全日志,审计数据或者其他网络上可以获取的信息进行分析,对系统的闯入或者闯出的企图进行检测”的安全技术入侵检测系统定义:对网络传输进行即时检测,对发现的可疑传输行为发出警报或者主动采取措施的网络安全设施入侵检测的局限和优点:a. 局限:有效性差,适应性差,扩展性差b. 优点:使现有的安全体系更加完整

2017-12-02 10:41:30 438

原创 信息安全概论总结-5

第五章-防火墙技术2017年11月28日 星期二 10:09防火墙:指一种确保信息安全的设施,会按照特定的规则,允许或者禁止传输的数据通过a. 特点: i. 内,外部之间的流量必须经过防火墙 ii. 只有符合安全策略的流量才能通过 iii. 自身具有很强的抗攻击免疫能力b. 功能: i. 控制在计算机网络中不同信任域之间传送的数据流c. 缺陷: i. 传

2017-12-02 10:37:26 363

原创 信息安全概论总结-4

第四章-PKI技术2017年11月15日 星期三 15:41PKI: Public Key Infrastructure 公共密钥基础设施目的:可以使用户安心在从事商业活动,而不用担心数据传输在网络上的安全性基础设施的特点:普适性,透明性,易用性典型的PKI系统包括:a. 认证中心CAb. 证书库c. 密钥备份和恢复系统d. 证书撤销处理系统e. PKI应用接口PKI提供的服务有:

2017-12-02 10:33:18 361

原创 信息安全概论总结-3

第三章-数字签名与身份认证2017年11月13日 星期一 10:33计算机安全的四大原则:机密性,完整性,可认证性,不可抵赖性• 机密性:既保护消息内容不会泄露给非授权的的人,即使攻击者观测者看到了消息的格式,也无法从中提取出任何有效的信息。• 认证性:是最重要的性质之一,认证是对主体进行身份识别非过程。• 完整性:是指保证消息的内容没有收到篡改• 不可抵赖性:用户不能否认敏感的文件认证分

2017-12-02 10:29:02 489

原创 信息安全概论总结-2

第二章-密码学概论2017年10月30日 星期一 11:11将明文转为密文的两种方法:替换法、变换法密码系统的由哪几部分构成:密码算法+密文空间+明文空间+密钥密码分析方法有几类?唯密文攻击:(只有一部分密文,都是相同的加密算法,尽可能恢复明文)已知明文攻击:(有些消息的密文和对应的明文,推导出密钥/算法)选择明文攻击+选择密文攻击什么是主动攻击?什么是被动攻击?被动攻击:攻击者被动截获

2017-12-02 10:23:33 990

原创 信息安全概论总结-1

第一章-概论2017年10月25日 星期三 14:00P²DR模型的主要内容:• Policy 安全策略• Protection 防护• Detection 检测• Response 响应PDRR模型的主要内容:• Protection 防御• Detection 检测• Response 响应• Recovery 恢复IOS开放系统互连安全体系定义的五大安全服务和八类安全机制:A

2017-12-02 09:51:05 718

原创 leetcode-238. Product of Array Except Self

238. Product of Array Except SelfGiven an array of n integers where n > 1, nums, return an array output such that output[i] is equal to the product of all the elements of nums except nums[

2017-11-29 20:38:29 319

gns3-windows版

一种图形化的网络虚拟化软件,可以模拟很多种网络拓扑结构。

2017-11-24

Github for Windows desktop

github 的 windows桌面客户端,由于官方网站的下载链接不能访问,就下载了这个文件共享

2017-11-20

Qt 小程序-记事本

Qt 小程序-记事本

2017-03-13

空空如也

TA创建的收藏夹 TA关注的收藏夹

TA关注的人

提示
确定要删除当前文章?
取消 删除