码迷,mamicode.com
首页 >  
搜索关键字:reverse bits    ( 8842个结果
自变量的变换
自变量的变换涉及到三个基本变换方式:伸缩(scale)、时移(shift)、反转(reverse)。变换通用的形式:x(t)->x(at+b)两种方法:可变对称抽和固定对称抽。1、可变对称抽:在三种基本变换中, 反转是相对于对称轴 t = 0 进行的, 而尺度变换中无论a为何值,t = 0的信号 x...
分类:其他好文   时间:2014-09-17 14:56:12    阅读次数:289
Reverse Nodes in k-Group[leetcode]递归和非递归的解法
题目不难,但是容易出错,需要考虑各种边界情况 非递归代码如下: ListNode *reverseKGroup(ListNode *head, int k) { if (head == NULL || k <= 1) return head; ListNode * start = NULL, * end = NULL, *newHead = NULL, *p...
分类:其他好文   时间:2014-09-16 19:00:54    阅读次数:201
Next Permutation[leetcode]
基本思路是从后往前找到第一个递减的数num[index],并与之前的第一个大于num[index]的数交换位置。 注意交换后[index+1...n-1]仍是非递减的,所以只需要reverse一下,使其变成非递增的 void nextPermutation(vector &num) { int index = num.size() - 2; int rI...
分类:其他好文   时间:2014-09-16 17:23:40    阅读次数:116
redis info 各信息意义
redis_version:2.4.16 # Redis 的版本redis_git_sha1:00000000redis_git_dirty:0arch_bits:64multiplexing_api:epollgcc_version:4.1.2 #gcc版本号process_id:10629 # ...
分类:其他好文   时间:2014-09-15 21:08:59    阅读次数:204
Add Two Numbers
You are given two linked lists representing two non-negative numbers. The digits are stored in reverse order and each of their nodes contain a single ...
分类:其他好文   时间:2014-09-15 12:41:48    阅读次数:133
数组排序
一直都对数组排序有点混淆不清,今天闲下来硬是找了些资料好好补课一下,感觉如下这篇还不错,于是转过来了。 reverse()、sort() 和 sortOn() reverse() 倒序排列sort() 按照多种预定义的方式对数组进行排序,甚至可用来创建自定义排序算法。sortOn() 方法可用来对对...
分类:其他好文   时间:2014-09-15 12:35:08    阅读次数:155
[LeetCode] Reverse Linked List II @ Python
原题地址:https://oj.leetcode.com/problems/reverse-linked-list-ii/题意:Reverse a linked list from positionmton. Do it in-place and in one-pass.For example:Gi...
分类:编程语言   时间:2014-09-14 23:38:47    阅读次数:239
数组与字符串 1.2
用C或C++实现void reverse( char* str )函数,即反转一个null结尾的字符串。分析:先确定字符串的长度,然后从两端往中间遍历,同时交换两端的元素。 1 #include 2 #include 3 #include 4 5 using namespace std; 6...
分类:其他好文   时间:2014-09-14 20:31:47    阅读次数:209
[Java][MAT] Shallow Heap大小计算释疑
查看Mat文档时里面是这么描述Shallow Heap的:Shallowheap is the memory consumed by one object. An object needs 32 or 64 bits(depending on the OS architecture) per reference, 4 bytes per Integer, 8 bytesper Long, etc....
分类:编程语言   时间:2014-09-14 16:45:47    阅读次数:204
【leetcode】Gray Code
题目: The gray code is a binary numeral system where two successive values differ in only one bit. Given a non-negative integer n representing the total number of bits in the code, print the...
分类:其他好文   时间:2014-09-14 11:22:47    阅读次数:181
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!