摘要:
Input输入数据的第一行是一个整数C,表示测试实例的个数,然后是C 行数据,每行包含一个整数n(0<n<=10000),表示折线的数量。Output对于每个测试实例,请输出平面的最大分割数,每个实例的输出占一行。Sample Input2 1 2Sample Output2 7主要是找规律#include<stdio.h>#include<iostream>#include<algorithm>#include<cmath>using namespace std;int main(){ int t,ans,n; scanf(&quo 阅读全文
摘要:
/*不容易系列之(4)——考新郎 Time Limit: 2000/1000 MS (Java/Others) Memory Limit: 65536/32768 K (Java/Others) Total Submission(s): 12511 Accepted Submission(s): 4740Problem Description 国庆期间,省城HZ刚刚举行了一场盛大的集体婚礼,为了使婚礼进行的丰富一些,司仪临时想出了有一个有意思的节目,叫做"考新郎",具体的操作是这样的:首先,给每位新娘打扮得几乎一模一样,并盖上大大的红盖头随机坐成一排; 然后,让各位新郎寻找 阅读全文
摘要:
/*Binomial Showdown Time Limit: 1000MS Memory Limit: 65536K Total Submissions: 15798 Accepted: 4839DescriptionIn how many ways can you choose k elements out of n elements, not taking order into account? Write a program to compute this number. InputThe input will contain one or more test cases. Each 阅读全文