胸怀天下 脚踏实地 |
|
||
2009年6月19日
摘要:
#include<iostream.h>#include<string.h>classPerson{public:Person(char*pN){cout<<"Constructing"<<pN<<endl;pName=newchar[strlen(pN)+1];if(pName!=0)strcpy(pName,pN);}~Person(... 阅读全文
摘要:
#include<windows.h>#include<mmsystem.h>//using namespace std;int WINAPI WinMain(HINSTANCE hInstance,HINSTANCE hPreInstance,PTSTR szCmdLine,int iCmdShow){//MessageBox(NULL,TEXT("hello"),"",... 阅读全文
摘要:
//读取文件void CFileView::OnFilRead() {// TODO: Add your command handler code hereCFile file;TRY{file.Open("lm.txt",CFile::modeRead);}CATCH(CFileException , e){#ifdef _DEBUGafxDump<<"File could not ... 阅读全文
摘要:
itoa()函数有3个参数:第一个参数是要转换的数字,第二个参数是要写入转换结果的目标字符串,第三个参数是转移数字时所用 的基数。在上例中,转换基数为10。10:十进制;2:二进制...如:# include <stdio.h># include <stdlib.h>void main (void){int num = 100;char str[25];itoa(num, ... 阅读全文
|
Copyright © 2024 icey
Powered by .NET 8.0 on Kubernetes |