![](https://img-blog.csdnimg.cn/20201014180756925.png?x-oss-process=image/resize,m_fixed,h_64,w_64)
c/c++
iteye_18468
这个作者很懒,什么都没留下…
展开
-
eclipse3.5 + mingw 搭建c++ 开发环境
[b]eclipse3.5 + mingw 搭建c++ 开发环境[/b]------[b]步骤:[/b][b]* jdk[/b] 安装 jdk,并配置环境变量[b]* eclipse 安装[/b] 下载 eclipse3.5.1-c++ 版本,自带 cdt, 解压即可[b]* mingw 安装[/b] 下载地址:h...2010-09-28 08:22:56 · 71 阅读 · 0 评论 -
c - word counter (binary-tree)
c - word counter (binary-tree) count ascii word in a file, written by c, using binary-tree, code: word_counter.c:#include <stdio.h>#include <string.h>#include <...2012-05-09 14:17:45 · 115 阅读 · 0 评论 -
c - pointer is also pass by value
c - pointer is also pass by value when pointer as param of function, it is also pass by value:* you can change the value that the pointer point to by the address(the value of pointer),* but...2012-05-09 14:13:26 · 94 阅读 · 0 评论 -
find palindromic-prime in pi
find palindromic-prime in pi question: find the first 7-digit palindromic prime found in consecutive digits of pi. orginal link: http://www.scoopshot.com/hiring-deve...2012-04-26 18:32:06 · 102 阅读 · 0 评论 -
c #define
c #define macro substitution, define alias name for something, include: #define #undef #ifdef / #ifndef / #endif ------#define define an alias name for value / expression / .. ,...2012-04-08 13:29:44 · 95 阅读 · 0 评论 -
c static
c static static external variable/function: only visible in local file, you can define multiple static variable in different source file, and there will be no conflict, static local var...2012-04-04 21:59:31 · 99 阅读 · 0 评论 -
c extern
c extern extern, used to declare variable / function, so that to use them before define them,a external variable / function could only be define once, but could be declare multiple times,exter...2012-04-04 21:53:01 · 89 阅读 · 0 评论 -
int to string by specified base
int to string by specified base convert a int to string, by specified base, support 2 - 16, code:#include <stdio.h>/* * @author kuchaguangjie * @date 2012-04-03 22:10 * @m...2012-04-03 22:15:05 · 82 阅读 · 0 评论 -
linux c udp
linux 下可用 c 进行 udp 通信,使用 server / client, 例子: * server/** * udp server * @date: 2011-4-1 下午03:34:27 * @author: eric */#include <stdio.h>#include <string.h>#includ...2011-04-01 18:02:08 · 102 阅读 · 0 评论 -
linux c tcp
linux 下可用 c 进行 tcp 通信,使用 server / client, 例子: * server/** * tcp server * @date: 2011-4-1 下午03:34:27 * @author: eric */#include <stdio.h>#include <string.h>#include ...2011-04-01 18:00:10 · 75 阅读 · 0 评论 -
gdb 调试工具
gdb 调试工具 gdb 概述 gdb , GNU Debugger ,用于在 linux 上 调试 c/c++ 程序, 参考: ububtu gdb 指南 ------程序的编译 用 gcc 编译时,应加上 -g 参数,以让编译出的文件支持 gdb 调试, 格式: gcc -g source_file ------进入 gdb ...2011-02-21 17:20:45 · 77 阅读 · 0 评论 -
random select
random select problem: select m number from 0 - (n-1) randomly, ------solution 1 for each number in 0 - (n-1), in increasing order, generate a random number x, using "(x%remain) <...2011-08-28 01:00:26 · 331 阅读 · 0 评论 -
sparse data structure - matrix
sparse data structure sparse data structure - means most element are empty(or have a very same value), so we can try to use some better data structure to reduce memory use, ------matrix...2011-08-18 20:03:53 · 186 阅读 · 0 评论 -
max sub_sequence - c
max sub_sequence - c /* problem: there is a sequence of number,could be positive or negative, find out the sub sequence which has max sum, solution: loop the sequence, use max...2011-08-10 01:02:54 · 105 阅读 · 0 评论 -
binary search - c
binary search - c (simple) search - basic: /** @author kuchaguangjie@gmail.com */#include <stdio.h>/** * binary search (simple) * * @param * arr pointer of array * @param...2011-08-06 12:07:47 · 79 阅读 · 0 评论 -
bit_array - simple use
bit array,use less memory to describe a set of int number, example:/** * use bit string to store int numbers,if char[n] = 1,then n is include,else n is not exclude, */#include <stdio....2011-05-28 23:47:06 · 65 阅读 · 0 评论 -
c - linkedlist
c - linkedlist store ordered number in linkedlist, no repeat. code: linkedlist_test.c: #include <stdio.h>#include <stdlib.h>extern struct linkedlist { int num;...2012-05-10 14:52:13 · 91 阅读 · 0 评论