HBC206677EndAsGPA题解

素流年 算法基础篇 55 0
想要检验自己的编程水平?来试试全网最全C++题库,让您在挑战中不断进步。
At the end of term, Makise Von got a poor grade. Meanwhile, EndA started to show his magic. Now Makise Von wonders if EndA's GPA is really 4.0, and he has almost made it. There arenexams, and EndA's score of the i-th exam isai. Beside, it's known that the i-th exam's proportion of the GPA ispi%. So let EndA's GPA beans, then ans=4%∑i=1npi%aians=4%cdotsum_{i=1}^np_i%cdot a_ians=4%∑i=1npi%ai Help Makise Von judge that if EndA's GPA is 4.0.

At the end of term, Makise Von got a poor grade. Meanwhile, EndA started to show his magic. Now Makise Von wonders if EndA's GPA is really 4.0, and he has almost made it. There are n exams, and EndA's score of the i-th exam is ai . Beside, it's known that the i-th exam's proportion of the GPA is pi% . So let EndA's GPA be ans , then ans=4%⋅∑i=1npi%⋅aians=4%cdotsum_{i=1}^np_i%cdot a_ians=4%⋅∑i=1n​pi​%⋅ai​ Help Makise Von judge that if EndA's GPA is 4.0.

HBC206677EndAsGPA题解
-第1张图片-东莞河马信息技术
(图片来源网络,侵删)
全网最全C++题库,助您挑战自我,突破极限,成为编程领域的佼佼者!

标签: HBC206677EndAsGPA题解