ntia.cn/problem-sets/1381430105642242048/problems/1388... to Pas 实验辅助教学平台 考试练习 教育超市 ASSISTANT 〈返回 7-5 Added 2 floating-number in round towards In this questiion, given 2 positive floating numbers A...

Solve this in c language programming
ntia.cn/problem-sets/1381430105642242048/problems/1388... to<br>Pas<br>实验辅助教学平台<br>考试练习<br>教育超市<br>ASSISTANT<br>〈返回<br>7-5 Added 2 floating-number in round towards<br>In this questiion, given 2 positive floating numbers A and B, you are supposed to<br>output 2 types of their sum. The first way is to calculate their true sum, which<br>keeps 2 fraction digits. The second way is to round half-up each number to 2<br>decimal place first, and then sum them.<br>Input Specification:<br>Each input file contains one test case, which gives A and B in a line. Separate each<br>other in one space.<br>Output Specification:<br>For each test case, the fisrt line print the value of A+B, which keeps 2 fraction<br>digits. The second line print the value of A+B which calculating A+B in the second<br>way. No more space behand each number.<br>Sample Input 1:<br>14.527 15.616<br>Sample Output' 1:<br>30.14<br>30.15<br>Sample Input 2:<br>(田<br>

Extracted text: ntia.cn/problem-sets/1381430105642242048/problems/1388... to Pas 实验辅助教学平台 考试练习 教育超市 ASSISTANT 〈返回 7-5 Added 2 floating-number in round towards In this questiion, given 2 positive floating numbers A and B, you are supposed to output 2 types of their sum. The first way is to calculate their true sum, which keeps 2 fraction digits. The second way is to round half-up each number to 2 decimal place first, and then sum them. Input Specification: Each input file contains one test case, which gives A and B in a line. Separate each other in one space. Output Specification: For each test case, the fisrt line print the value of A+B, which keeps 2 fraction digits. The second line print the value of A+B which calculating A+B in the second way. No more space behand each number. Sample Input 1: 14.527 15.616 Sample Output' 1: 30.14 30.15 Sample Input 2: (田
Sample Output 1:<br>30.14<br>30.15<br>Sample Input 2:<br>25.524 46.613<br>Sample Output 2:<br>72.14<br>72.13<br>Sample Input 3:<br>19.233 33.258<br>Sample Output 3:<br>52.49<br>52.49<br>

Extracted text: Sample Output 1: 30.14 30.15 Sample Input 2: 25.524 46.613 Sample Output 2: 72.14 72.13 Sample Input 3: 19.233 33.258 Sample Output 3: 52.49 52.49

Jun 11, 2022
SOLUTION.PDF

Get Answer To This Question

Related Questions & Answers

More Questions »

Submit New Assignment

Copy and Paste Your Assignment Here