自定义博客皮肤VIP专享

*博客头图:

格式为PNG、JPG,宽度*高度大于1920*100像素,不超过2MB,主视觉建议放在右侧,请参照线上博客头图

请上传大于1920*100像素的图片!

博客底图:

图片格式为PNG、JPG,不超过1MB,可上下左右平铺至整个背景

栏目图:

图片格式为PNG、JPG,图片宽度*高度为300*38像素,不超过0.5MB

主标题颜色:

RGB颜色,例如:#AFAFAF

Hover:

RGB颜色,例如:#AFAFAF

副标题颜色:

RGB颜色,例如:#AFAFAF

自定义博客皮肤

-+

wu-kan

个人主页https://wu-kan.cn,CSDN博客不再维护

  • 博客(18)
  • 收藏
  • 关注

原创 题解:2015-2016 Petrozavodsk Winter Training Camp, Saratov SU Contest

Maximum Product #include<bits/stdc++.h> using namespace std; typedef long long ll; vector<ll> a,b,ans; ll n; ll product(const vector<ll> &v) { ll ret=1,i=0; while(!v[i])++i; f...

2018-10-30 10:29:56 1614

原创 题解:Dhaka 2011

Binary Matrix #include <cstdio> #include <cstdlib> #include <cstring> #include <algorithm> #include <queue> #define N 2010 using namesp

2018-10-27 18:02:45 245

原创 题解:[UVA-11426]GCD - Extreme (II)

GCD - Extreme (II) 求∑i=1n∑j=i+1ngcd⁡(i,j)\sum_{i=1}^n\sum_{j=i+1}^n\gcd(i,j)∑i=1n​∑j=i+1n​gcd(i,j)。 解法一:蓝书解法,计算贡献 设f(n)=∑i=1n−1gcd⁡(i,n)f(n)=\sum_{i=1}^{n-1}\gcd(i,n)f(n)=∑i=1n−1​gcd(i,n),则所求答案为f(n)f(...

2018-10-24 18:30:35 229

原创 计算机组成原理实验一:MIPS汇编语言程序设计

实验目的 初步认识和掌握MIPS汇编语言程序设计的基本方法; 悉PCSpim模拟器的使用。悉PCSpim模拟器的使用。 实验内容 从键盘输入10个无符号字数或从内存中读取10个无符号字数并从大到小进行排序,排序结果在屏幕上显示出来。 实验器材 电脑一台,PCSpim仿真器软件一套。 实验过程与结果 十个数的排序,考虑使用插入排序实现。使用插入排序的好处,是能够在读入的同时完成排序。考虑对应的C...

2018-10-23 11:42:48 8176 5

原创 函数程序设计实验三:使用Newton-Raphson方式计算平方根

module Newton_Raphson where squareroot2 :: Float -> Integer -> Float squareroot2 x0 n=squareroot 2 x0 n squareroot :: Float -> Float -> Integer -> Float squareroot r x0 0=x0 squareroo...

2018-10-23 01:55:08 792 1

原创 题解:珂朵莉树练习题组

Willem, Chtholly and Seniorious #include<bits/stdc++.h> #define mul(a,b,c) ((a)*(b)%(c)) using namespace std; typedef long long ll; typedef pair<int,ll&am

2018-10-22 00:52:29 933

原创 题解:2017-2018 ACM-ICPC Southeastern European Regional Programming Contest (SEERC 2017)

Concerts 辣鸡数据范围。滚动DP。 #include<bits/stdc++.h> using namespace std; const int N=1e7+9,M=1e9+7; char a[N],b[N]; int n,k,f[2][N],h[127]; int main() { scanf("%d%d",&k,&n); for(char c='A'; ...

2018-10-21 23:00:42 934

原创 题解:Ural Championship 2010

The House of Doctor Dee #include<bits/stdc++.h> #define X first #define Y second using namespace std; typedef long long ll; typedef pair<ll,ll> Coord; pair<Coord,Coord> v[2]; int mai

2018-10-20 20:15:13 177

原创 题解:无旋Treap练习

Tyvj 1728 普通平衡树 #include<bits/stdc++.h> using namespace std; typedef int ll; struct FhqTreap { struct Node { int ch[2],siz; ll key,val; }; vector&a

2018-10-18 08:58:12 229

原创 程设项目二:圣杯战争

项目概况 项目名称:圣杯战争 项目介绍:实现一个游戏的英雄系统、战斗系统、装备系统、技能系统等,可模拟游戏从者间的相互对抗 游戏背景 圣杯战争是TYPE-MOON出品的《Fate/stay night》和《Fate/Zero》等Fate系列作品中出现的概念。广义上的圣杯战争,就是围绕着能实现持有者心愿的“圣杯”的争夺战。 本项目还原了这一概念,七名御主(Master,即玩家)操纵自己的从者(Ser...

2018-10-16 11:08:03 452

原创 程设项目一:某科学的超会议议程管理系统(Scientific Meeting Management System)

项目概况 项目名称:某科学的超会议议程管理系统(Scientific Meeting Management System) 项目介绍:基于命令行,实现添加(add)、删除(delete)、修改(modify)、查询(query)等议程管理功能。 需求分析 每次打开系统时,自动恢复上次的数据。 每次关闭系统时,将数据保存到本地。 向议程中加入一个会议,当会议与任何已有的议程都不冲突时

2018-10-16 11:07:48 429

原创 函数程序设计实验二:递归练习

module HW where {- 1. 定义求两个非负整数最大公因子的函数: mygcd ::Integer ->Integer ->Integer -} mygcd ::Integer ->Integer ->Integer mygcd a 0=a mygcd a b=mygcd b (mod a b) {- 2. 定义阶乘函数 fac :: Integer -&...

2018-10-16 11:06:22 324

原创 函数程序设计实验一:分式

--import Test.QuickCheck module MyFraction where Fraction=(Integer,Integer) --分式化简 ratreduction::Fraction->Fraction ratreduction(x,y)=(div x g,div y g)where g=gcd x y --加法 ratplus::Fraction->F...

2018-10-16 10:49:46 305

原创 题解:2012-2013 ACM-ICPC, Central Europe Regional Contest (CERC 12)

Kingdoms 破产是收支不平衡时才有概率发生,并且一个国家破产之后有概率导致破产 #include<bits/stdc++.h> using namespace std; int t,n,a[31][31],cnt[1<<20],ans; void dfs(int s) { if(cnt[s])return; for(int i=0; i&l

2018-10-16 10:44:48 377

原创 题解:2009-2010 ACM-ICPC Northeastern European Regional Contest (NEERC 09)

Business Center #include <cstdlib> #include <algorithm> using namespace std; int n,m; int main() { while (~scanf("%d%d",&amp

2018-10-06 16:11:56 422

原创 题解:Ural Championship 2012

Brainwashing Device #include<bits/stdc++.h> using namespace std; const int N=511,INF=1e9; int n,K,f[N][N],a[N][N],c[N][N],s[N][N],g[N][N]; int main() { scanf("%d%d",&n,&K); for(int i

2018-10-06 15:46:30 136

原创 题解:Ural Championship 2011

Help in the RNOS #include<bits/stdc++.h> using namespace std; typedef long long ll; ll cal(char s[],int n) { char t[63]; fill(t,t+n,'0'); t[n-1]='1'; ll ans=0; for(int i=n-1; ~i; --i) if(...

2018-10-05 12:34:24 182

原创 题解:Ural Regional School Programming Contest 2011

GOV Chronicles 体验极差的四级阅读理解,大致是在文章里找每个人参加了多少比赛…用一下Ctrl+F。 漏了最后面还有两个人各参加了一场比赛还wa了一发。 有几个人的信息比较含糊所幸样例里还给了答案。 #include<stdio.h> int n,a[14]= {5,21,12,2,1,4,6,1,4,4,1,0,1,1}; int main() { scanf(&amp

2018-10-01 18:47:57 282

空空如也

空空如也

TA创建的收藏夹 TA关注的收藏夹

TA关注的人

提示
确定要删除当前文章?
取消 删除