Initial commit

This commit is contained in:
2025-03-14 22:39:32 +08:00
commit 7b1e0f329e
38 changed files with 1153 additions and 0 deletions

13
14lanqiao/test2.cpp Normal file
View File

@@ -0,0 +1,13 @@
#include<bits/stdc++.h>
using namespace std;
int main(){
double n = 23333333;
double res = 11625907.5798;
for(int a = 0; a <= n; a++){ // a为0出现的次数
int b = n - a; // b为1出现的次数
if(a>=b) continue;
double ans = (-1)*a*(a/n)*log2(a/n) + (-1)*b*(b/n)*log2(b/n);
if(fabs(ans - res) < 1e-4) cout << a << endl;
}
return 0;
}