弹跳球问题 发表于 2024-10-31 本文字数: 329 阅读时长 ≈ 3 分钟文章时效性提示本文发布于 500 天前,部分信息可能已经改变,请注意甄别。题目:一球从100米高度自由落下,每次落地后反跳回原高度的一半,再落下,求它在第10次落地时,共经过多少米?第10次反弹多高?12345678910111213#include <stdio.h>int main() { float height = 100; int count = 0; float distance = 0; for (count=1; count<=10; count++) { distance = height + distance; height = height / 2; printf("第%d次落地,下次高度:%lf,总距离:%lf\n",count,height,distance); } return 0;}