first commit
This commit is contained in:
30
2010-06-09/10012.cpp
Normal file
30
2010-06-09/10012.cpp
Normal file
@ -0,0 +1,30 @@
|
||||
/*
|
||||
date:107/10/13
|
||||
author:Chen Yi Jing
|
||||
|
||||
要將一堆圓圈塞進一個長方形裡,求最小長方形面積
|
||||
1. 圓該怎麼擺
|
||||
*/
|
||||
|
||||
#include <iostream>
|
||||
#include <math.h>
|
||||
using namespace std;
|
||||
int main() {
|
||||
int line = 0, n = 0;
|
||||
|
||||
while(cin >> line) {
|
||||
for (int i = 0; i < line; i++) {
|
||||
cin >> n;
|
||||
float num[n];
|
||||
for (int j = 0; j < n; j++) {
|
||||
cin >> num[j];
|
||||
}
|
||||
for (int j = 0; j < n; j++) {
|
||||
cout << num[j];
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
cout<< sqrt(1.5*1.5 - 0.5*0.5);
|
||||
}
|
Reference in New Issue
Block a user