14 solutions
-
0
#根据谢老师发的视频讲解得出的暴力方法,详情请看https://www.bilibili.com/video/bv11L4y1b7JQ#
#include <iostream> using namespace std; typedef long long ll; int main() { ll count=0; for(ll i=1;i<2021;i++) { for(ll j=1;j<2021;j++) { for(ll u=1;u<2021;u++) { ll m=2021-i-j-u; if(m>=2) { count+=m-1; } else break; } } } cout<<count<<endl; return 0; }
Information
- ID
- 106
- Time
- 1000ms
- Memory
- 256MiB
- Difficulty
- 6
- Tags
- # Submissions
- 504
- Accepted
- 163
- Uploaded By