码迷,mamicode.com
首页 >  
搜索关键字:d. gukiz and binary    ( 11754个结果
[LeetCode]Binary Tree Level Order Traversal II
[LeetCode]Binary Tree Level Order Traversal II...
分类:其他好文   时间:2014-07-29 14:42:48    阅读次数:145
[LeetCode 题解]: Flatten Binary Tree to Linked List
Given a binary tree, flatten it to a linked list in-place.For example,Given 1 / \ 2 5 / \ \ 3 4 6The flattened t...
分类:其他好文   时间:2014-07-29 14:07:58    阅读次数:163
二叉堆
实现:#ifndef BINARY_HEAP_H#define BINARY_HEAP_H#include "dsexceptions.h"#include using namespace std;// BinaryHeap class//// CONSTRUCTION: with an optio...
分类:其他好文   时间:2014-07-29 14:04:18    阅读次数:230
LeetCode "Divide Two Integers"
A very interesting numeric problem. It involves a lot tricks.Linear search (by +\-) is not feasible - too slow. So binary search is a good idea. Also ...
分类:其他好文   时间:2014-07-29 14:02:08    阅读次数:187
sql命令查看,清楚mysql bin日志
查看二进制日志文件mysql> SHOW BINLOG EVENTS \G;mysql> SHOW MASTER LOGS;清除二进制日志文件mysql> PURGE { MASTER|BINARY } LOGS TO 'log_name';mysql> PURGE { MASTER|BINARY ...
分类:数据库   时间:2014-07-29 13:55:28    阅读次数:318
[LeetCode 题解]:Convert Sorted List to Binary Search Tree
Given a singly linked list where elements are sorted in ascending order, convert it to a height balanced BST.题意:给定一个有序的链表,将其转换成平衡二叉搜索树思路: 二分法要构建一个平衡二叉...
分类:其他好文   时间:2014-07-29 13:40:48    阅读次数:601
URAL 1081 Binary Lexicographic Sequence
第13个位置第5个Bit :13>num[4] =>1 第四个bit 13-num[4]=5 :50 ,3-1 第三个Bit 5>num[2](3) 5-num[2]=2 ...#includeint num[45];void init(){ num[0]=1; num[1]=2; ...
分类:其他好文   时间:2014-07-29 11:50:46    阅读次数:169
Linux中rpm和yum
RPM是RedHatPackageManager(RedHat软件包管理工具)类似Windows里面的“添加/删除程序”1rpm执行安装包二进制包(Binary)以及源代码包(Source)两种。二进制包可以直接安装在计算机中,而源代码包将会由RPM自动编译、安装。源代码包经常以src.rpm作为后缀名。yum=YellowdogU..
分类:系统相关   时间:2014-07-28 03:05:30    阅读次数:316
linux-RPM包使用小结
一)什么是RPM?RedhatPackageManager的简称,就是包管理工具,它是linux中使用安装最简便的一种包管理工具。rpm执行安装包有两种:二进制包(Binary):二进制包可以直接安装在计算机中源代码包(Source):源代码包将会由RPM自动编译、安装。源代码包经常以src.rpm作为后缀rp..
分类:系统相关   时间:2014-07-28 00:37:10    阅读次数:278
折半插入排序
之间介绍插入排序时漏掉一种插入方式,那就是折半插入。 这种方式是采用二分查找法去查找插入点,可以减少元素比较次数,但是并不能减少移动次数,复杂度跟直接插入一样,都为O(n^2). 直接上代码: //二分插入排序 void binary_insert_sort(int arr[],int len) { if(arr == NULL || len <= 1) { return; }...
分类:其他好文   时间:2014-07-28 00:27:19    阅读次数:292
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!