下面程序的功能是根据近似公式:π2/6(六分之π的平方)≈ 1/12(1的平方分之1)+1/22(2的平方分之1)+1/32(3的平方分之1)+ …… +1/n2(n的平方分之1),求π值。#include
int main(){double s=0.0;long i;for(i=1;i<=n;i++)s=s+ 1.0/(float)(i*i);printf("%0.2f",___________);return 0;}
拍照语音搜题,微信中搜索"皮皮学"使用
参考答案:
参考解析:
知识点:
皮皮学刷刷变学霸
举一反三
【单选题】A company enters into a contract to build a factory for a customer. The agreed price is £2m and the specified completion date is 31 October 2016. However, the contract provides that the company should...
【简答题】Utopia: St.Nicholas Strait Iformation Service. This is Utopia. Are there any navigational warnings? St.Nicholas Strait Iformation Service: Utopia. This is St.Nicholas Strait Iformation Service. There ...
【单选题】A 52-year-old woman has had a chronic cough for the past 2 years, accompanied by a small amount of occasionally blood-streaked, whitish sputum On physical examination, her temperature is 37.9 C, pulse...
【简答题】There is a girl of 15, who has set up a company of her own. Her name is Wendy Wong. She 1 the business two years ago. She has already __2___ several successful computer s. They are so ___3___ that...