当前位置:网站首页>7-6 mixed type data format input
7-6 mixed type data format input
2022-07-03 14:14:00 【Big fish】
This question requires the preparation of procedures , Read in floating-point numbers in order 1、 Integers 、 character 、 Floating point numbers 2, And then according to the character 、 Integers 、 Floating point numbers 1、 Floating point numbers 2 Sequential output .
Input format :
Enter floating-point numbers in order in one line 1、 Integers 、 character 、 Floating point numbers 2, In the meantime 1 Space separation .
Output format :
In a line by character 、 Integers 、 Floating point numbers 1、 Floating point numbers 2 Sequential output , Floating point numbers are reserved after the decimal point 2 position .
sample input :
2.12 88 c 4.7
sample output :
c 88 2.12 4.70c The language code is as follows :
#include<stdio.h>
int main()
{
double a;// Start floating point assignment float Type causes errors , Change it to double Two decimal places can be reserved after type
int b;
char e;
double d;
scanf("%lf %d %c %lf",&a,&b,&e,&d);// The input floating-point type is %lf type
printf("%c %d %.2f %.2f",e,b,a,d);
return 0;
}
边栏推荐
猜你喜欢

交联环糊精金属有机骨架负载甲氨蝶呤缓释微粒|金属-有机多孔材料UiO-66负载黄酮苷类药物|齐岳

Global event bus

FPGA test method takes mentor tool as an example

可编程逻辑器件软件测试

消息订阅与发布

愉悦资本新双币基金近40亿元完成首次关账

Exercise 10-8 recursive implementation of sequential output of integers

GRPC的四种数据流以及案例
![[clean up the extraordinary image of Disk C]](/img/0d/331115bc5d82d6337ae975a08494b2.jpg)
[clean up the extraordinary image of Disk C]

Redis:Redis的数据结构、key的操作命令
随机推荐
QT learning 20 standard dialog box in QT (middle)
超简单手机地图开发
关于回溯问题中的排列问题的思考(LeetCode46题与47题)
Uniapp skills - dom display and hiding
JS first summary
交联环糊精金属有机骨架负载甲氨蝶呤缓释微粒|金属-有机多孔材料UiO-66负载黄酮苷类药物|齐岳
Metal organic framework (MOFs) antitumor drug carrier | pcn-223 loaded with metronidazole | uio-66 loaded with ciprofloxacin hydrochloride(
[acnoi2022] guess numbers
Exercise 9-3 plane vector addition
QT learning 17 dialog box and its types
Current situation, analysis and prediction of information and innovation industry
Message subscription and publishing
QT learning 25 layout manager (4)
2021年区域赛ICPC沈阳站J-Luggage Lock(代码简洁)
Collection of mobile adaptation related articles
simpleParallax. JS (create poor visual effects for website pictures)
[clean up the extraordinary image of Disk C]
中感微冲刺科创板:年营收2.4亿净亏1782万 拟募资6亿
信创产业现状、分析与预测
npm install卡住与node-npy的各种奇怪报错