参加2017年ACMICPC西安2017亚洲邀请赛赛是什么体验

如何评价2017年陕西省ACM邀请赛? - 知乎227被浏览126510分享邀请回答73 条评论分享收藏感谢收起var press_
function changecal(action,year,month)
switch(action)
case "nextmonth":
if(month==11)
month = 1;
year = year*1 + 1;
month = month*1 + 2;
strcal = "> ";
case "premonth":
if(month==0)
month = 12;
year = year*1 - 1;
strcal = " <";
case "nextyear":
year = year*1 + 1;
month = month*1 + 1;
strcal = ">>";
case "preyear":
year = year*1 - 1;
month = month*1 + 1;
strcal = "<<";
strcal = " " + strcal + " ";
return(strcal);
function calender(cyear,cmonth)
var d,d_date,d_day,d_
//定义每月天数数组
var monthdates = ["31","28","31","30","31","30","31","31","30","31","30","31"]
d = new Date();
d_year = d.getYear();
//获取年份
//判断闰月,把monthdates的二月改成29
if (((d_year % 4 == 0) && (d_year % 100 != 0)) || (d_year % 400 == 0)) monthdates[1] = "29";
if ((cyear != "" ) || (cmonth != ""))
//如果用户选择了月份和年份,则当前的时间改为用户设定
d.setYear(cyear);
d.setMonth(cmonth-1);
d.setDate(1);
d_month = d.getMonth();
//获取当前是第几个月
d_year = d.getYear();
//获取年份
d_date = d.getDate();
//获取日期
//修正19XX年只显示两位的错误
if(d_year<2000){d_year = d_year + 1900}
//===========输出日历===========
str += changecal("preyear",d_year,d_month)
str += changecal("premonth",d_year,d_month)
str += d_year + " - " + (d_month*1+1)
str += changecal("nextmonth",d_year,d_month)
str += changecal("nextyear",d_year,d_month)
str += "";
str += "SuMoTuWeThFrSa";
str += "";
var firstday,lastday,totalcounts,firstspace,lastspace,
//需要显示的月份共有几天,可以用已定义的数组来获取
monthdays = monthdates[d.getMonth()];
//设定日期为月份中的第一天
d.setDate(1);
//需要显示的月份的第一天是星期几
firstday = d.getDay();
//1号前面需要补足的的空单元格的数
firstspace =
//设定日期为月份的最后一天
d.setDate(monthdays);
//需要显示的月份的最后一天是星期几
lastday = d.getDay();
//最后一天后面需要空单元格数
lastspace = 6 -
//前空单元格+总天数+后空单元格,用来控制循环
totalcounts = firstspace*1 + monthdays*1 + lastspace*1;
//count:大循环的变量;f_space:输出前空单元格的循环变量;l_space:用于输出后空单元格的循环变量
var count,flag,f_space,l_
//flag:前空单元格输完后令flag=1不再继续做这个小循环
for(count=1;count<=count++)
//一开始flag=0,首先输出前空单元格,输完以后flag=1,以后将不再执行这个循环
if(flag==0)
if(firstspace!=0)
for(f_space=1;f_space<=f_space++)
str += " ";
if(f_space!= firstspace) count++;
if((count-firstspace)<=monthdays)
//输出月份中的所有天数
curday = d_year+","+(d_month*1+1)+","+(count - firstspace)+"|"
linkday = d_year+","+(d_month*1+1)+","+(count - firstspace)
var today = new Date();
if( (d_year == today.getYear()) && (d_month == today.getMonth()) && ((count-firstspace) == today.getDate()) )
//将本地系统中的当前天数高亮
str += "" + (count - firstspace) + "";
//不用高亮的部分,没有日志
str += "" + (count - firstspace) + "";
if(count%7==0)
if(count<totalcounts)
str += "";
str += "";
//如果已经输出了月份中的最后一天,就开始输出后空单元格补足
for(l_space=1;l_space<=l_space++)
str += " ";
if(l_space!= lastspace) count++;
document.getElementById("calenderdiv").innerHTML = "" + str + "";
//调用函数
calender("","")
您现在的位置:
我院在ACM/ICPC亚洲区西安邀请赛上获得铜奖
发布日期: | 阅读次数:
& & 历时2天的ACM/ICPC亚洲区西安邀请赛于5月21日在西北工业大学落幕。此次大赛共有来自上海交通大学、北京理工大学、天津大学、湖南大学等122所高校293支代表队参加。我校信息学院刘勇老师带领计算机科学与技术专业李奕超、闫楠、郭一挺等3名同学组队参赛,经过5个小时的激烈角逐,获得铜奖。
& & 赛事介绍:ACM/ICPC是由美国计算机学会组织的国际大学生程序设计竞赛,始于1970年,是一项旨在展示大学生创新能力、团队精神和在压力下编写程序、分析解决问题能力的年度竞赛。经过40多年发展,该竞赛已经发展成为全球最具影响力的大学生程序设计竞赛,被誉为IT行业的“奥林匹克”。赛事由各大洲区域赛和全球总决赛两个阶段组成。竞赛规定每支参赛队伍由三名在校大学生组成,他们需要在规定的5个小时内解决10个到13个复杂实际编程问题。每队使用一台电脑,最后的获胜者为正确解答题目最多和总用时间最少的队伍。
& & 信息学院组建了一支涵盖各个专业的程序设计集训团队,为喜爱编程的学生搭建了一个施展才华、互相交流、共同进步的舞台。该团队在信息学院尤枫老师和刘勇老师指导下,利用周末及寒暑假时间,组织程序设计集训,为我校编程氛围和赛事成绩的持续提高打下了基础。校区学子在2017年国际大学生程序设计竞赛全国邀请赛(陕西)喜获佳绩【 2017 ACM-ICPC 亚洲区(西安赛区)网络赛】 F. Trig Function - Gzbgreat的博客 - CSDN博客
【 2017 ACM-ICPC 亚洲区(西安赛区)网络赛】 F. Trig Function
f(cos(x))=cos(n*x)
holds for all x.
Given two integers n
and m, you need to calculate the coefficient of
modulo 998244353.
Input Format
Multiple test cases (no more than
Each test case contains one line consisting of two integers
1≤n≤10^9,0≤m≤10^4.
Output Format
Output the answer in a single line for each test case.
#include &iostream&
#include &cstdio&
#include &cstring&
#include &algorithm&
#include &cmath&
#include &map&
#include &string&
#include &cstring&
#include &ctime&
#define ms(a,b) memset(a,b,sizeof(a))
const long long M = ;
ll powmod(ll a, ll b, ll p)
ll res = 1;
while (b != 0)
if (b & 1)
res = (res * a) %
a = (a * a) %
ll comb(ll a, ll b, ll p)
if (a & b)
if (a == b)
if (b & a - b)
ll ans = 1, ca = 1, cb = 1;
for (ll i = 0; i & ++i)
ca = (ca * (a - i)) %
cb = (cb * (b - i)) %
ans = (ca * powmod(cb, p - 2, p)) %
ll Lucas(int n, int m, int p)
ll ans = 1;
while (n && m && ans)
ans = (ans * comb(n % p, m % p, p)) %
int main()
std::ios::sync_with_stdio(false);
while (cin && n && m)
if (n - m & 0 || (n - m) % 2 != 0)
cout && 0 &&
ll k = (n - m) / 2;
ll ans = 0;
if (k % 2 == 0)
ans = (n * Lucas(n - k, k, M) % M * powmod(2, m, M) % M * powmod(n + m, M - 2, M) ) % M;
cout && ans &&
ans = (-n * Lucas(n - k, k, M) % M * powmod(2, m, M) % M * powmod(n + m, M - 2, M)) % M;
cout && (ans + M) % M &&
我的热门文章如何评价2017年陕西省ACM邀请赛? - 知乎227被浏览126510分享邀请回答44 条评论分享收藏感谢收起}

我要回帖

更多关于 2017acm西安邀请赛 的文章

更多推荐

版权声明:文章内容来源于网络,版权归原作者所有,如有侵权请点击这里与我们联系,我们将及时删除。

点击添加站长微信