Implementint sqrt(int x).Compute and return the
square root
ofx.classSolution{public:intsqrt(intx){inti=0;intstep=1;while(step>0){while((i+step)>1);}r...
分类:
其他好文 时间:
2014-06-04 19:54:17
阅读次数:
214
初次接触到javascript的单线程。 1 计算器 2 3 4
测试结果是:正在计算这几个字根本就没显示,直接显示计算完成。后来分析原因,当点击事件发生时,浏览器事件触发线程 向Event Loop
中添加了点击事件,javascript引擎线程 在处理完点击事件后,继...
分类:
编程语言 时间:
2014-06-04 18:14:15
阅读次数:
329
VOIDKiAdjustIrpCredits ( VOID )其中 Number =
KeNumberProcessors;Prcb = KiProcessorBlock[Index];多核情况下调整每个CPU的IRP对象配额。在while
(Index Lookaside...
分类:
其他好文 时间:
2014-06-03 11:35:52
阅读次数:
254
关于指令精简,这方面的事是由于loop,je,ja老报错,说越界多少字节。搜索了这方面信息才知道mov,dx,0,与sub
dx,dx的区别。这个看来是以后的学习内容 。另外想找份工作, 本人linux开发3年,主要用c,pro*c,自动编译用的是大伙都知道
的make与架子。对计算机底层技术特别感...
分类:
其他好文 时间:
2014-06-03 06:28:13
阅读次数:
291
逆序数的性质。1. 暴力解 1 #include 2 3 #define MAXNUM 5005 4
5 int a[MAXNUM]; 6 7 int main() { 8 int n; 9 int i, j, sum, min;10 11 while
(scanf(...
分类:
其他好文 时间:
2014-05-31 07:50:50
阅读次数:
170
水题,不过要想0ms过还是有个技巧的:#include #include using
namespace std;int main(){ int score[101]; int t,t1,temp; while(cin>>t) {
//memset(score,...
分类:
其他好文 时间:
2014-05-30 16:53:11
阅读次数:
268
做法1: List list = new List(); Random rand = new
Random(); while (list.Count =1,=0,<100 之间的随机数m、n,颠倒arr[m]和arr[n]的数。 int[] arr
= new int[100]; //把100个数顺...
分类:
其他好文 时间:
2014-05-30 04:27:12
阅读次数:
208
解决SQL Server管理器无法连接远程数据库Error: 1326错误我们在在使用SQL
Server时都会遇到使用SQL Server Management Studio无法连接远程数据库实例的问题,错误描述信息摘录如下:An error has
occurred while establis...
分类:
数据库 时间:
2014-05-29 20:50:49
阅读次数:
404
My original thought was to calculate all the
possible transactions by using nested loop. But got time limit excess error.I
knew it can be done in O(n)...
分类:
其他好文 时间:
2014-05-29 20:44:37
阅读次数:
271
http://ubuntuforums.org/archive/index.php/t-1771058.htmlI
accidentally discovered a fix for this while trying to solve a different
problem.edit~/.conf...
分类:
其他好文 时间:
2014-05-29 15:00:26
阅读次数:
623