U E D R , A S I H C RSS

Is This Integration?/허준수

~cpp
#include <iostream>
#include <cmath>

using namespace std;
#define PI 3.141592

int main()
{
	cout.setf(ios::fixed, ios::floatfield);       
    cout.setf(ios::showpoint);       
	cout.precision(3);     

	double a, s1, s2, s3;
	while(cin>>a) {
		s1 = (PI*a*a/12 - ((sqrt(3)/4 - 1.0/4)*a*a ))*4;
		s2 = ((a*a*PI/2 - a*a) - s1) * 2;
		s3 = a*a - s1 - s2;
		cout << s1 << " " << s2 << " " << s3 <<endl;
	}
	return 0;
}

IsThisIntegration?
Valid XHTML 1.0! Valid CSS! powered by MoniWiki
last modified 2021-02-07 05:23:28
Processing time 0.0089 sec