自定义博客皮肤VIP专享

*博客头图:

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

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

博客底图:

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

栏目图:

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

主标题颜色:

RGB颜色,例如:#AFAFAF

Hover:

RGB颜色,例如:#AFAFAF

副标题颜色:

RGB颜色,例如:#AFAFAF

自定义博客皮肤

-+

夏天的风

业精于勤,荒于嬉;行成于思,毁于随。

  • 博客(26)
  • 资源 (4)
  • 收藏
  • 关注

原创 排序算法总结

好记性不如烂笔头o(^▽^)o前言   记得之前毕业找工作的时候好好总结过,但是,工作中基本不怎么用到这些排序算法,所以久而久之就忘了。以前写的文章链接(包括详细的思路、图和完整代码): 《直接选择排序》 《冒泡排序算法》 《希尔排序算法》 《快速排序算法》 《直接插入排序》  其实每种看了后很容易混淆和记不住,所以这里就对这些排序算法进行归类和总结,主要涉及十大排序算法。

2016-09-23 14:41:30 703

原创 Ceph浅接触

cephceph定义特性架构Ceph和对象存储系统定义原始论文:《Ceph: Reliable, Scalable, and High-Performance Distributed Storage》Ceph的官方网站Ceph.com定义:“Ceph is a unified, distributed storage system designed for excellent perform

2016-09-20 08:28:06 1094

原创 CDN

好记性不如烂笔头o(^▽^)o此文主要作为初步接触CDN的学习和了解,查阅了一些资料,并按照自己的阅读习惯进行语言整理、分段和整合,参考资料见文末1,2。CDNCDN一定义二CDN网络结构三CDN工作原理四具体实例五关键技术一、定义背景: 当下的互联网应用都包含大量的静态内容,但静态内容以及一些准动态内容又是最耗费带宽的,特别是针对全国甚至全世界的大型网站,如果这些请求都指向主站的服务

2016-09-20 07:55:41 3054

原创 C语言的艺术之——函数

好记性不如烂笔头o(^▽^)oC语言的艺术之函数C语言的艺术之函数1一个函数仅完成一件功能2重复代码应该尽可能提炼成函数3避免函数过长新增函数尽量不超过50行非空非注释行4避免函数的代码块嵌套过深新增函数的代码块嵌套不超过4层5可重入函数应避免使用共享变量若需要使用则应通过互斥手段关中断信号量对其加以保护6对参数的合法性检查由调用者负责还是由接口函数负责应在项目组模块内应统一规定缺省由调

2016-09-20 07:32:32 2536 2

原创 C语言的艺术之——头文件

好记性不如烂笔头o(^▽^)o  刚工作的时候,对于强调编程规范、编程理念,总是不以为然,等经历了一两个项目以后才发现其重要性,不禁感慨,C语言真是一门艺术。这里计划写一个系列的文章: 《C语言的艺术之——头文件》 C语言的艺术之——函数 C语言的艺术之——标识符命令与定义 C语言的艺术之——变量、常量和宏 C语言的艺术之——质量保证 C语言的艺术之——程序效率 C语言的艺术之——注释

2016-09-19 08:14:28 6448 1

原创 认识SSD

认识SSD认识SSD定义FLASH颗粒定义和分类SLC和MLCSSD的内部逻辑划分SSD的表项管理垃圾回收SSD的磨损均衡SSD使用寿命计算举例未完待续,先上班去了……定义固态硬盘(Solid State Disk)用固态电子存储芯片阵列而制成的硬盘,由控制单元和存储单元(FLASH芯片、DRAM芯片)组成。 一块SSD,核心部件是一颗控制器和多颗Flash颗粒,一般还会有一些

2016-09-18 08:26:16 4593 1

原创 382. Linked List Random Node

Given a singly linked list, return a random node’s value from the linked list. Each node must have the same probability of being chosen.Follow up: What if the linked list is extremely large and its le

2016-09-16 11:50:56 379

原创 86. Partition List

Given a linked list and a value x, partition it such that all nodes less than x come before nodes greater than or equal to x.You should preserve the original relative order of the nodes in each of the

2016-09-16 11:35:35 382

原创 328. Odd Even Linked List

Given a singly linked list, group all odd nodes together followed by the even nodes. Please note here we are talking about the node number and not the value in the nodes.You should try to do it in plac

2016-09-16 11:16:55 369

原创 237. Delete Node in a Linked List

Write a function to delete a node (except the tail) in a singly linked list, given only access to that node.Supposed the linked list is 1 -> 2 -> 3 -> 4 and you are given the third node with value 3, t

2016-09-16 11:06:54 338

原创 24. Swap Nodes in Pairs

Given a linked list, swap every two adjacent nodes and return its head.For example,Given 1->2->3->4, you should return the list as 2->1->4->3.Your algorithm should use only constant space. You may not

2016-09-16 11:01:48 282

原创 21. Merge Two Sorted Lists

Merge two sorted linked lists and return it as a new list. The new list should be made by splicing together the nodes of the first two lists.原题链接:https://leetcode.com/problems/merge-two-sorted-lists/思路

2016-09-16 09:20:48 304

原创 19. Remove Nth Node From End of List

Given a linked list, remove the nth node from the end of list and return its head.For example, Given linked list: 1->2->3->4->5, and n = 2. After removing the second node from the end, the linked

2016-09-16 09:14:37 392

原创 零碎知识点总结

这里总结一些关于语言、数据结构的一些基础知识。好记性不如烂笔头o(^▽^)o零碎知识点总结零碎知识点总结数组和指针的区别指针数组和数组指针hashmap 和 hashtable 的区别链表和数组的区别内存字节怎么对齐为什么要对齐new和malloc的区别抽象类和接口的区别桥接模式和适配器模式的区别数组和指针的区别1、计算内存容量上的差别 当数组作为函数的形参的时候,该数组自动退化为

2016-09-15 17:57:13 774

原创 B树、B+树、红黑树、AVL树

B树、B+树、红黑树B树B树红黑树定义及概念B树B树红黑树AVL树B树和B树的区别红黑树的应用及和B树区别AVL树和红黑树B树M阶的插入和删除插入删除定义及概念B树二叉树的深度较大,在查找时会造成I/O读写频繁,查询效率低下,所以引入了多叉树的结构,也就是B树。关于B树的由来,这里阐述了B-tree名字来源以及相关的开源地址。 阶为M的B树具有以下性质: 1、根节点在不为

2016-09-15 15:33:48 3367

原创 141、142 Linked List Cycle & II

Given a linked list, determine if it has a cycle in it.Follow up: Can you solve it without using extra space?思路 非常简单的一道题,如果链表有环,则在遍历的时候永远不会结束,一直在环内转圈。 所以,设置快慢指针,如果相遇,则说明有环。代码(C++)/** * Definition f

2016-09-11 22:32:38 376

原创 206. Reverse Linked List

Reverse a singly linked list.思路 链表反转。有递归和非递归两种方法。在前面一篇文章《链表操作》中已经有介绍,这里就不多说了。代码(C++) * struct ListNode { * int val; * ListNode *next; * ListNode(int x) : val(x), next(NULL) {} * }; */

2016-09-11 21:40:26 370

原创 C中各关键字总结

这里主要就平常中用到的常用关键字进行总结,便于更全面的理解其在代码中的意图。static关键字const关键字C语言static关键字static可以用来修饰局部变量、全局变量、函数 1、局部变量:原先存在栈中,生命周期语句执行完毕便结束了。现在存放到静态数据区,生命周期持续到整个程序执行结束。但并没有改变作用域,还是仅限于该语句块。并且只在初次运行的时候进行初始

2016-09-11 18:33:29 1528 1

原创 61. Rotate List

Given a list, rotate the list to the right by k places, where k is non-negative.For example:Given 1->2->3->4->5->NULL and k = 2,return 4->5->1->2->3->NULL.思路 两种方法:1、先组成环,再断开;2、先断开,再链接。代码(方法1 C)/** *

2016-09-07 08:35:37 378

原创 一些存储基本概念

存储基础知识存储基础知识存储技术存储方式iSCSI协议scale up 和 scale outwrite back和write throughRAIDRAID 5 和 RAID 10 对比LUN的概念块设备buffer_headbio存储技术网络存储设备根据存储技术的不同,主要分为三类:DAS(Direct Attached Storage)、NAS(Network Attac

2016-09-07 08:25:04 5425

原创 82. Remove Duplicates from Sorted List II

Given a sorted linked list, delete all nodes that have duplicate numbers, leaving only distinct numbers from the original list.For example,Given 1->2->3->3->4->4->5, return 1->2->5.Given 1->1->1->2->3

2016-09-05 23:37:30 387

原创 83. Remove Duplicates from Sorted List

Given a sorted linked list, delete all duplicates such that each element appear only once.For example,Given 1->1->2, return 1->2.Given 1->1->2->3->3, return 1->2->3.思路if cur->val == cur->next->valdel

2016-09-05 23:30:30 339

原创 344. Reverse String

Write a function that takes a string as input and returns the string reversed.Example:Given s = "hello", return "olleh".思路 太简单了吧,没啥好说的代码(C语言)class Solution {public: string reverseString(string s)

2016-09-05 23:21:56 321

原创 367. Valid Perfect Square

Given a positive integer num, write a function which returns True if num is a perfect square else False.Note: Do not use any built-in library function such as sqrt.Example 1:Input: 16Returns: TrueExam

2016-09-05 23:09:45 418

原创 387. First Unique Character in a String

Given a string, find the first non-repeating character in it and return it’s index. If it doesn’t exist, return -1. examples:s = "leetcode"return 0.s = "loveleetcode",return 2.Note: You may assume t

2016-09-02 08:31:40 413

原创 389. Find the Difference

Given two strings s and t which consist of only lowercase letters.String t is generated by random shuffling string s and then add one more letter at a random position.Find the letter that was added in

2016-09-02 07:37:00 681

直接通过ADO操作Access数据库

直接通过ADO操作Access数据库,亲测可用!简单的代码实例

2014-06-03

leetcode刷题指南

这个刷题指南按照难度、出现频率、所属数据结构类型、算法类型进行了分类,在刚开始写leetcode的时候是一个不错的指南。

2014-05-12

AVL树的实现

包含AVL树的创建、插入、删除和搜索四个部分的功能。 C++代码实现

2014-04-19

DS18B20温度检测及报警

用DS18B20温度传感器检测温度并显示在数码管上,当温度超过32度时自动报警(蜂鸣器响)

2010-08-06

空空如也

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

TA关注的人

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