1 WinMain(hInst,hPrev,……) 2 { 3 MSG msg; 4
RegisterClass(……); 5 CreateWindow(……); 6 ShowWindow(……); 7 UpdateWindow(……); 8
while(GetMessage(……)) 9 {10....
我的memcmp: 1 int memcmp(void *buf1, void *buf2,
unsigned int count){ 2 int reval; 3 while(count && !(reval = (*(unsigned
char *)buf1) - (*(unsi...
分类:
其他好文 时间:
2014-05-01 11:16:49
阅读次数:
387
//判断value是小于等于max的数字function isNumberMax(value,
max){ if(!isNumber(value) || !isNumber(max)){ return false; } if(parseInt(value)
= min){ return true; ...
分类:
编程语言 时间:
2014-05-01 10:53:41
阅读次数:
426
我的strcat: 1 char *strcat(char *dest,char *src)
2 { 3 char * reval = dest; 4 while(*dest) 5 dest++; 6 while(*src) 7 *dest++...
分类:
其他好文 时间:
2014-05-01 08:59:02
阅读次数:
484
#include#include#includeusing namespace std;int
main(){ int n,i; char a[100000]; cin>>a; sort(a,a+strlen(a)); do{
cout<<a<<endl; }while(next_permut...
分类:
其他好文 时间:
2014-05-01 06:20:37
阅读次数:
368
1 保留小数点后两位#include cout const char * spilt="/";char
*p;p=strtok(str,spilt);while(p!=NULL){ //cout
#includesort(Rs.begin(),Rs.end());sort(Rs.begin(),Rs...
分类:
编程语言 时间:
2014-05-01 05:05:45
阅读次数:
409
用c语言实现
#include
#include
#include
using namespace std;
typedef struct node
{
char x;
struct node *next;
}chan;
chan *root = new chan;
char a[100010];
int main()
{
while(scanf("%...
分类:
编程语言 时间:
2014-04-29 13:47:20
阅读次数:
358
//创建1个线程对象 并为这个线程对象指定要执行的方法.
Thread thread = new Thread(TestThread);
//设置线程为后台线程.
thread.IsBackground = true;
//开启线程
thread.Start();
...
分类:
编程语言 时间:
2014-04-29 13:32:23
阅读次数:
363
floyd求最短路。
注意图是有向图。。。
#include
#include
#include
using namespace std;
struct node
{
int x,y,id;
}edge[205];
int dis[205][205];
int main()
{
int c,T,n,a,b,op;
while(scanf("%d",&T...
分类:
其他好文 时间:
2014-04-29 13:21:23
阅读次数:
313
最近要做一个文件打开和保存的对话框,现将相关的代码记录如下,用以备忘!
所用控件:
2个静态标签(Static Text):用以显示功能标签;
2个文本框(Edit):用以显示打开的文件路径全名要保存的文件路径全名,设置其Read Only属性为true将文本框设置为不可编辑;
2个按钮(Button):用以浏览文件;
打开文件对话框
CFileDialog打开的对话框...
分类:
其他好文 时间:
2014-04-29 13:17:21
阅读次数:
301