codeforces 560 C Gerald's Hexagon】的更多相关文章

神精度--------这都能过.随便算就好了,根本不用操心 就是把六边形补全成三角形.然后去掉补的三个三角形,然后面积除以边长1的三角形的面积就可以.... #include<map> #include<string> #include<cstring> #include<cstdio> #include<cstdlib> #include<cmath> #include<queue> #include<vector…
[CF简单介绍] 提交链接:http://codeforces.com/contest/560/problem/C 题面: C. Gerald's Hexagon time limit per test 2 seconds memory limit per test 256 megabytes input standard input output standard output Gerald got a very curious hexagon for his birthday. The bo…
C. Gerald's Hexagon time limit per test 2 seconds memory limit per test 256 megabytes input standard input output standard output Gerald got a very curious hexagon for his birthday. The boy found out that all the angles of the hexagon are equal to .…
C. Gerald's Hexagon time limit per test 2 seconds memory limit per test 256 megabytes input standard input output standard output Gerald got a very curious hexagon for his birthday. The boy found out that all the angles of the hexagon are equal to .…
C. Gerald's Hexagon time limit per test 2 seconds memory limit per test 256 megabytes input standard input output standard output Gerald got a very curious hexagon for his birthday. The boy found out that all the angles of the hexagon are equal to .…
http://codeforces.com/contest/559/problem/A 题目大意:按顺序给出一个各内角均为120°的六边形的六条边长,求该六边形能分解成多少个边长为1的单位三角形. 解: 性质1:边长为n的正三角形能够划分成n*n个边长为1的正三角形. 绘图找规律 性质2:延长各边总能找到一个大的正三角形.而且所求等于大三角形减去三个补出来的三个三角形面积 收获: 以后先找规律,看能不能找出一些特征即使不会证明 其次,总的减去部分化为所求假设想求的难以直接求 #include <…
题意:按顺序给出一个各内角均为120°的六边形的六条边长,求该六边形能分解成多少个边长为1的单位三角形. 把单位三角形面积看做1,实际上就是求六边形面积.随便找六边形的三条互相不相邻的边,分别以这三条边为基础向外扩展一个等边三角形.就可以将原六边形补成一个大等边三角形,然后用大等边三角形面积减去补上的3个小等边三角形面积就是原来六边形的面积. 而等边三角形面积非常easy.就是边长的平方(实际就是边长为n的等边三角形能分解成n^2个边长为1的单位三角形,画个图就能理解了). #include <…
time limit per test2 seconds memory limit per test256 megabytes inputstandard input outputstandard output Gerald got a very curious hexagon for his birthday. The boy found out that all the angles of the hexagon are equal to . Then he measured the len…
time limit per test2 seconds memory limit per test256 megabytes inputstandard input outputstandard output Gerald bought two very rare paintings at the Sotheby's auction and he now wants to hang them on the wall. For that he bought a special board to…
A. Gerald's Hexagon time limit per test 2 seconds memory limit per test 256 megabytes input standard input output standard output Gerald got a very curious hexagon for his birthday. The boy found out that all the angles of the hexagon are equal to .…