ICode9

精准搜索请尝试: 精确搜索
  • A. Dima and Friends【1000 / 思维】2021-10-22 19:06:15

    https://codeforces.com/problemset/problem/272/A #include<bits/stdc++.h> using namespace std; int a[105],n,sum; int main(void) { cin>>n; for(int i=1;i<=n;i++) cin>>a[i],sum+=a[i]; int cnt=0; for(int i=1;i<=5;i++) { if((sum+i

  • Codeforces Round #167 (Div. 1) E. Dima and Game2020-02-01 17:56:07

      一个 $(l,r)$ 有两个后继,所以 sg 值最大只有 2,$r-l+1$ 相等的 pair 的 sg 值相同,那么就枚举 $d=r -l+1$,对于一个 $d$ 很容易求有多少对 $(l,r)$ 满足 $r-l+1=d$ 打表发现 $d$ 的 sg 值最多只有 100 段。 设 $g_i$ 表示有多少对 $(l,r)$ sg 值为 $i$,把表打出来之后就很容易求出

  • Two Cakes2019-08-30 20:40:59

    Sasha and Dima want to buy two n-tier cakes. Each cake should consist of n different tiers: from the size of 1 to the size of n. Tiers should go in order from the smallest to the biggest (from top to bottom). They live on the same street, there are 2⋅

  • Codeforces 272D。Dima and Two Sequences,多重集的全排列2019-08-30 12:37:04

    output standard output Little Dima has two sequences of points with integer coordinates: sequence (a1, 1), (a2, 2), ..., (an, n) and sequence (b1, 1), (b2, 2), ..., (bn, n). Now Dima wants to count the number of distinct sequences of points

专注分享技术,共同学习,共同进步。侵权联系[81616952@qq.com]

Copyright (C)ICode9.com, All Rights Reserved.

ICode9版权所有