摘要: __syncthreads() acts as a barrier at which all threads in the block must wait before any is allowed to proceed.//计算向量的内积程序#include<stdio.h>#define imin(a,b) (a<b?a:b)//N为输入的向量的规模const int N=33*1024;const int threadsPerBlock=256;const int blocksPerGrid= imin(32,(N+threadsPerBlock-1)/threadsP 阅读全文
posted @ 2012-06-20 15:44 quasi-mathematician 阅读(453) 评论(0) 推荐(0) 编辑
摘要: (http://blog.renren.com/share/294623177/13085317327?from=0101010202&ref=newsfeed&sfet=102&fin=1&ff_id=294623177)需要写的英文邮件多了,就觉得很吃力,尤其是当需要经常写给同一个人时。希望邮件的开头、结尾、一些客套的话能有不同的表达~~邮件的开头 感谢读者是邮件开场白的好办法。感谢您的读者能让对方感到高兴,特别是之后你有事相求的情况下会很有帮助。 &nbsp; Thank you for contacting us.如果有人写信来询问公司的服务,就 阅读全文
posted @ 2012-05-19 19:10 quasi-mathematician 阅读(187) 评论(0) 推荐(0) 编辑
摘要: c/c++ 宏中"#"和"##"的用法2007年05月14日 星期一 上午 10:19一、一般用法我们使用#把宏参数变为一个字符串,用##把两个宏参数贴合在一起.用法:#i nclude<cstdio>#i nclude<climits>using namespace std; #define STR(s) #s#define CONS(a,b) int(a##e##b)int main(){ printf(STR(vck)); // 输出字符串"vck" printf("%d\n", CO 阅读全文
posted @ 2012-05-18 20:47 quasi-mathematician 阅读(111) 评论(0) 推荐(0) 编辑
摘要: dos.h函数详解(1/6)2009-04-13 18:18@函数名称: absread函数原型: int absread(int drive, int nsects, int sectnum, void *buffer)函数功能: 对磁盘扇区读数据函数返回: 0-操作成功,其他-操作失败参数说明: driver-读取的驱动器号 0-表示驱动器A,以此类推 sectnum-读取的扇区号 msects-读取的扇区数所属文件: <dos.h>#include <stdio.h>#include <coni... 阅读全文
posted @ 2012-05-18 20:17 quasi-mathematician 阅读(1090) 评论(0) 推荐(1) 编辑
摘要: c语言 conio.h头文件介绍C语言图形函数(一)2007-04-21 10:53C语言图形编程(一,字符屏幕)一,屏幕操作函数1. clrscr()清除字符窗口函数2. window()字符窗口函数3. gotoxy()光标定位函数4. clreol() 清除光标行尾字符函数5. insline() 插入空行函数6. delline() 删除一行函数7. gettext() 拷进文字函数8. puttext() 拷出文字函数9. movetext() 移动文字函数二,字符属性函数10. textmode() 文本模式函数 11. highvideo()高亮度函数 12. lowvideo( 阅读全文
posted @ 2012-05-18 20:13 quasi-mathematician 阅读(756) 评论(0) 推荐(0) 编辑
摘要: 英文标题大写的规则(附:英文大写规则)乐叶庐转自http://www.kaixin001.com/repaste/21103803_5958197490.html英语写作时标题首字母是否大写,从写作规范来讲,有两种回答。其一,首字母全部大写。这种情况常见于绝大部分的书刊、杂志和报纸。但还有另一种情况:标题只是第一个单词首字母大写,而其他的单词(除非专有名词)一律小写。在新闻报道中,美联社有一本厚厚的Stylebook,专门就很多问题作出规定,其中包括标题,对标题大写情况作了更细致的规定。如关于首字母全部大写,它规定:出现介词,只有四个或以上字母的才大写。比如:I Will Go With Hi 阅读全文
posted @ 2012-03-19 21:58 quasi-mathematician 阅读(790) 评论(0) 推荐(0) 编辑
摘要: 转自http://hi.baidu.com/%B3%E9%B7%E7%B5%C4%BB%DE%C9%AC%C4%A2%B9%BD/blog/item/9f6581082f95880694ca6b2c.html------- test 1 ----5 41 2 401 4 202 4 202 3 303 4 10------- test 2 ----3 31 2 52 2 1002 3 3------- test 3 ----7 61 2 100002 3 100003 6 100001 4 80004 3 80002 5 60005 6 6000------- test 4 ----13 51 阅读全文
posted @ 2012-03-18 20:36 quasi-mathematician 阅读(552) 评论(0) 推荐(0) 编辑
摘要: 1 #include<cstdio> 2 #include<cstdlib> 3 #include<memory> 4 #include<cstring> 5 #define maxn 202 6 #define MAXINT 0x5f5f5f5f 7 using namespace std; 8 int c[maxn][maxn]; 9 int pre[maxn];10 int queue[maxn];11 12 int N,M;13 14 int EK(int,int);15 16 int main(){17 while(scanf(&quo 阅读全文
posted @ 2012-03-18 19:30 quasi-mathematician 阅读(144) 评论(0) 推荐(0) 编辑