摘要: 问题描述 最近FJ为他的奶牛们开设了数学分析课,FJ知道若要学好这门课,必须有一个好的三角函数基本功。所以他准备和奶牛们做一个“Sine之舞”的游戏,寓教于乐,提高奶牛们的计算能力。 不妨设 An=sin(1–sin(2+sin(3–sin(4+...sin(n))...) Sn=(...(A1+n 阅读全文
posted @ 2019-03-23 15:21 frente 阅读(113) 评论(0) 推荐(0) 编辑
摘要: #include using namespace std; int n,flag=0,cnt=0; string s; int main() { scanf("%d",&n); cin>>s; int last=n-1; for(int i=0;i=i;j--){//从最后一个元素开始找与第i个元素匹配的元素 if(i==j){ ... 阅读全文
posted @ 2019-03-21 20:32 frente 阅读(328) 评论(0) 推荐(0) 编辑
摘要: 问题描述 Tom教授正在给研究生讲授一门关于基因的课程,有一件事情让他颇为头疼:一条染色体上有成千上万个碱基对,它们从0开始编号,到几百万,几千万,甚至上亿。 比如说,在对学生讲解第1234567009号位置上的碱基时,光看着数字是很难准确的念出来的。 所以,他迫切地需要一个系统,然后当他输入12 阅读全文
posted @ 2019-03-21 00:09 frente 阅读(281) 评论(0) 推荐(0) 编辑
摘要: #include #include #include #include #include #include #include #include #include #include #include using namespace std; string s,str; mapm; int main() { while(getline(cin,s)&&s!="#"){ ... 阅读全文
posted @ 2019-03-18 23:55 frente 阅读(80) 评论(0) 推荐(0) 编辑
摘要: 问题: 在8×8格的国际象棋上摆放八个皇后,使其不能互相攻击,即任意两个皇后都不能处于同一行、同一列或同一斜线上,问有多少种摆法。 代码1:(dfs) 阅读全文
posted @ 2019-03-16 16:42 frente 阅读(127) 评论(0) 推荐(0) 编辑
摘要: 1.高精度乘法: 例题:(蓝桥杯基础练习) 代码实现: 2.高精度加法: 例题:蓝桥杯基础练习 代码实现: 阅读全文
posted @ 2019-03-16 13:57 frente 阅读(124) 评论(0) 推荐(0) 编辑
摘要: #include using namespace std; int n,m,sum=0,maxx=0,num=1e9+5; int a[10][10],flag[10][10]; int ansx[4]={0,0,-1,1},ansy[4]={1,-1,0,0}; void dfs(int x,int y,int currentsum,int currentnum){ fl... 阅读全文
posted @ 2019-03-15 00:06 frente 阅读(179) 评论(1) 推荐(0) 编辑
摘要: 贪心、 B. Views Matter time limit per test 2 seconds memory limit per test 256 megabytes input standard input output standard output 贪心、 B. Views Matter 阅读全文
posted @ 2019-03-14 00:03 frente 阅读(91) 评论(0) 推荐(0) 编辑
摘要: 注意题目条件:a balanced team, 仅保证大家水平差距不超过5即可,不管水平高低 阅读全文
posted @ 2019-03-12 23:25 frente 阅读(95) 评论(0) 推荐(0) 编辑
摘要: 1.简单模板: https://www.cnblogs.com/OctoptusLian/p/7429645.html(啊哈磊) 2.题目:蓝桥杯真题<带分数> 问题描述 100 可以表示为带分数的形式:100 = 3 + 69258 / 714。 还可以表示为:100 = 82 + 3546 / 阅读全文
posted @ 2019-03-11 21:29 frente 阅读(167) 评论(0) 推荐(0) 编辑