printf,scanf打印格式

长度指示符转换规范转换为某种类型的二进制
hhdchar
hdshort
dint
ldlong
lldlong long
hhuunsigned char
huunsigned short
uunsigned int
lu

unsigned long

lluunsigned long long
ffloat
lfdouble
c

字符对应的ASCLL码

s字符串中字符对应的ASCLL码
#include <stdio.h>
int main()
{
	char c;
	short s;
	int n;
	long l;
	float f;
	double df;
	scanf("%hhd %hd %d %ld %f %lf",&c,&s,&n,&l,&f,&df); //后面加&是将转化后的二进制存储到基础变量中
	printf("%d %d %d %d %f %f\n", c, s, n, l, f, df);
	return 0;
}

 SACLL码表

SACLL 

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值