T1.码灵鼠

手推f[2],f[3]可以发现f[i]=i-1

给出归纳证明:

8.12模拟赛

为什么E(ai)+E(aj)==2E(ai)?因为i和j是相互独立的。

记得long long

#include<iostream>
#include<cstdio>

using namespace std;

inline long long rd(){
    long long ret=0,f=1;char c;
    while(c=getchar(),!isdigit(c))f=c=='-'?-1:1;
    while(isdigit(c))ret=ret*10+c-'0',c=getchar();
    return ret*f;
}

long long n;

int main(){
    n=rd();
    for(int i=1;i<=n;i++){
        long long x=rd();
        printf("%lld\n",x+1ll);
    }
}
View Code

相关文章:

  • 2021-12-28
  • 2021-12-15
  • 2021-06-15
  • 2021-04-02
  • 2021-08-12
  • 2021-12-25
  • 2021-05-27
  • 2021-09-06
猜你喜欢
  • 2021-06-01
  • 2021-08-19
  • 2022-12-23
  • 2022-12-23
  • 2021-04-18
  • 2021-07-06
相关资源
相似解决方案