企业即时通讯 - Enterprise Instant Messenger

局域网聊天工具,文字讯息、文件发送、语音通讯、高清视频通讯、远程桌面控制。

用户操作
[即时聊天] [发私信] [加为好友]
FreeEIM StudioID:i_like_cpp
972448次访问,排名32,好友4人,关注者7人。
i_like_cpp的文章
原创 888 篇
翻译 4 篇
转载 69 篇
评论 1148 篇
FreeEIM Studio的公告
最近评论
ScanerKi:#include <stdio.h>

int asm(int s)
{
int t=0;
__asm
{
mov eax, DWORD PTR [ebp+8] ;把s的值传给eax
mov t, eax ;把eax的值传给t
}
printf("- %d……
li_delong:谢谢
li_delong:谢谢
li_delong:谢谢
XUETUJIAN:
文章分类
收藏
相册
EIM 截图
相关软件图片
PI的最精确值
FreeEIM 标签
FreeEIM华军下载
XP SP2 SDK
下载FreeEIM
盛天龙
飞鸽传书
不错的网站
CPPBLOG
局域网聊天
泡妞专家
用VC写Assembly代码(RSS)
百度的Blog(RSS)
存档
软件项目交易
订阅我的博客
XML聚合  FeedSky
订阅到鲜果
订阅到Google
订阅到抓虾
订阅到BlogLines
订阅到Yahoo
订阅到GouGou
订阅到飞鸽
订阅到Rojo
订阅到newsgator
订阅到netvibes

原创 一小段C++程序,关于ltoa函数的收藏

新一篇: 怎样和朋友寒暄 | 旧一篇: 通用ShellCode深入剖析

Example.

/* ltoa example */
#include <stdio.h>
#include <stdlib.h>

int main ()
{
  int i;
  char buffer [sizeof(long)*8+1];
  printf ("Enter a number: ");
  scanf ("%d",&i);
  ltoa (i,buffer,10);
  printf ("decimal: %s\n",buffer);
  ltoa (i,buffer,16);
  printf ("hexadecimal: %s\n",buffer);
  ltoa (i,buffer,2);
  printf ("binary: %s\n",buffer);
  return 0;
}

 

Convert long integer value to string.
  Converts a long integer value to a null-terminated string using the specified radix and stores the result in the given buffer.
  If radix is 10 and value is negative the string is preceded by the minus sign (-). With any other radix, value is always considered unsigned.
  buffer should be large enough to contain any possible value: (sizeof(long)*8+1) for radix=2.

Parameters.

value
Value to be represented as a string.
buffer
Buffer where to store the resulting string.
radix
Numeral radix in which value has to be represented, between 2 and 36.

Return Value.
  A pointer to the string.

Portability.
  Not defined in ANSI-C. Supported by some compilers.

Output:
Enter a number: 16021977
decimal: 16021977
hexadecimal: f479d9
binary: 111101000111100111011001

发表于 @ 2006年01月21日 11:51:00|评论(loading...)|编辑

新一篇: 怎样和朋友寒暄 | 旧一篇: 通用ShellCode深入剖析

评论

#rss 发表于2006-01-22 09:20:00  IP: 220.112.65.*
http://www.wrss.cn/?bloger
无线RSS聚合新闻
[b]使用手机看免费新闻资讯、体育赛事、娱乐信息、财经要闻 [/b]
[无线RSS聚合新闻]-手机访问http://wrss.cn/ [完全免费] wap rss
http://www.wrss.cn/?bloger无线RSS聚合新闻
发表评论  


登录
Csdn Blog version 3.1a
Copyright © FreeEIM Studio