Vulkan

2014年4月18日

Cracking The Coding Interview 5.7

摘要: //An array A[1…n] contains all the integers from 0 to n except for one number which is missing. In this problem, //we cannot access an entire integer ... 阅读全文

posted @ 2014-04-18 14:30 Vulkan 阅读(136) 评论(0) 推荐(0) 编辑

Cracking The Coding Interview 5.6

摘要: //Write a program to swap odd and even bits in an integer with as few instructions as possible (e.g., bit 0 and bit 1 are swapped, bit 2 and bit 3 are... 阅读全文

posted @ 2014-04-18 12:59 Vulkan 阅读(150) 评论(0) 推荐(0) 编辑

Cracking The Coding Interview 5.5

摘要: #include #include using namespace std;int getNum1(int N){ int num=0; for (int i=0; i>1; } return num;}void print(int p) { vector v; for (int k = 0;k>... 阅读全文

posted @ 2014-04-18 12:12 Vulkan 阅读(111) 评论(0) 推荐(0) 编辑

Cracking The Coding Interview5.3 暂存

摘要: 的 阅读全文

posted @ 2014-04-18 12:12 Vulkan 阅读(82) 评论(0) 推荐(0) 编辑

Cracking The Coding Interview5.2

摘要: //Given a (decimal - e.g. 3.72) number that is passed in as a string, print the binary representation.If the number can not be represented accurately ... 阅读全文

posted @ 2014-04-18 01:48 Vulkan 阅读(92) 评论(0) 推荐(0) 编辑

Cracking The Coding Interview5.1

摘要: //You are given two 32-bit numbers, N and M, and two bit positions, i and j. Write a method to set all bits between i and j in N equal to M (e.g., M b... 阅读全文

posted @ 2014-04-18 01:17 Vulkan 阅读(149) 评论(0) 推荐(0) 编辑

导航