2015年6月30日

摘要: cudaPrintfInit和cudaPrintfEnd在你整个工程的使用中只需调用一次。显示结果不会自动显示在屏幕上,而是存储在缓存中,当调用cudaPrintfDisplay时被清除和显示。这个缓存的大小可以通过函数cudaPrintfInit(size_tbufferLen)的可选参数来指定。... 阅读全文
posted @ 2015-06-30 09:32 lz亢龙有悔 阅读(1630) 评论(0) 推荐(0) 编辑

2015年2月12日

摘要: hypot已知三角形两边,求第三边长度。。。参见:http://blog.csdn.net/ammana_babi/article/details/1435454例题 4-1 组合数 阅读全文
posted @ 2015-02-12 10:44 lz亢龙有悔 阅读(96) 评论(0) 推荐(0) 编辑

2014年12月29日

摘要: 程序 3-5程序 3-6 阅读全文
posted @ 2014-12-29 19:07 lz亢龙有悔 阅读(104) 评论(0) 推荐(0) 编辑
摘要: 程序 3-5程序 3-6 阅读全文
posted @ 2014-12-29 19:06 lz亢龙有悔 阅读(76) 评论(0) 推荐(0) 编辑
摘要: 程序3-4 阅读全文
posted @ 2014-12-29 19:04 lz亢龙有悔 阅读(67) 评论(0) 推荐(0) 编辑
摘要: 程序 3-1 1 #include 2 #define MAXN 100 + 10 3 int a[MAXN]; 4 int main() 5 { 6 int i, x, n = 0; 7 while(scanf("%d", &x) == 1) 8 a[n++] = ... 阅读全文
posted @ 2014-12-29 13:46 lz亢龙有悔 阅读(122) 评论(0) 推荐(0) 编辑

2014年12月28日

摘要: 程序2-7 略去程序2-8 1 #define LOCAL 2 #include 3 #define INF 100000000 4 int main() 5 { 6 #ifdef LOCAL 7 freopen("data.in","r",stdin); 8 freope... 阅读全文
posted @ 2014-12-28 13:00 lz亢龙有悔 阅读(110) 评论(0) 推荐(0) 编辑
摘要: 任务1: 1 #include 2 int main() 3 { 4 int i, n; 5 scanf("%d",&n); 6 for(i = 1; i 2 int main() 3 { 4 int i, n; 5 scanf("%d",&n); 6 ... 阅读全文
posted @ 2014-12-28 12:52 lz亢龙有悔 阅读(159) 评论(0) 推荐(0) 编辑
摘要: 程序2-4 1 #include 2 #include 3 int main() 4 { 5 int n, count = 0; 6 scanf("%d",&n); 7 while(n>1) 8 { 9 if(n % 2 ==1) n = 3*n +1... 阅读全文
posted @ 2014-12-28 00:17 lz亢龙有悔 阅读(126) 评论(0) 推荐(0) 编辑

2014年12月27日

摘要: 程序2-1 1 #include 2 #include 3 int main() 4 { 5 int n; 6 scanf("%d",&n); 7 for(int i=1;i 2 #include 3 int main() 4 { 5 int a, b, n; 6 ... 阅读全文
posted @ 2014-12-27 23:47 lz亢龙有悔 阅读(167) 评论(0) 推荐(0) 编辑

导航