当前位置:网站首页>2022-7-18 summary
2022-7-18 summary
2022-07-25 04:50:00 【JSU-YSJ】
The time for this summary is 2022-7-16~2022-7-18
These two days are mainly in question brushing training :
Niuke supplement :



CF Supplementary questions :
5.00 Summer vacation Niuke adds supplementary questions :

/*
https://ac.nowcoder.com/acm/contest/33186/I
Chiitoitsu
*/
#include <bits/stdc++.h>
using namespace std;
#define int long long
const int mod = 1e9 + 7;
int n;
int dp[20][200];
int ksm(int a, int b) {
int ret = 1;
while (b) {
if (b & 1) {
ret *= a;
ret %= mod;
}
a = a * a;
a %= mod;
b >>= 1;
}
return ret;
}
int inv(int a) { return ksm(a, mod - 2); }
int mul(int a, int b) { return a * b % mod; }
void solve(int c) {
// memset(dp, 1, sizeof dp);
for (int i = 6; i >= 0; i--) {
for (int j = 1; j <= 136; j++) {
dp[i][j] = 1;
int ok = (13 - 2 * i) * 3;
dp[i][j] = dp[i][j] + mul(dp[i][j - 1], mul(j - ok, inv(j)));
dp[i][j] %= mod;
if (i != 6) { dp[i][j] = dp[i][j] + mul(dp[i + 1][j - 1], mul(ok, inv(j))); }
dp[i][j] %= mod;
}
}
string s;
cin >> s;
int cnt = 0;
std::map<string, int> mp;
for (int i = 0; i < 25; i += 2) {
string tmp = "";
tmp += s[i];
tmp += s[i + 1];
mp[tmp]++;
if (mp[tmp] == 2) { cnt++; }
}
// cout << cnt << endl;
printf("Case #%d: %ld\n", c, dp[cnt][123]);
return;
}
signed main() {
int T;
cin >> T;
for (int i = 1; i <= T; i++) { solve(i); }
return 0;
} This is a wrong topic ,
This probability DP, At first, it was (7-i) The number of cards is not considered , Consider logarithm directly , Not paying attention to , What a injustice , Another topic is

Write a wrong symbol , After a long time .... In a word, I didn't pay attention to the details , Then I returned the sample and 37.5%, Outrageous . Play well tomorrow .
边栏推荐
- Libenent and libev
- [golang from introduction to practice] poker licensing game
- After watching the latest interview with big manufacturers, these six JVM interview questions were asked
- LVGL 8.2 Textarea
- IT自媒体高调炫富,被黑客组织盯上,铁定要吃牢饭了…
- 01 create project warehouse
- Sony announced the closure of Beijing mobile phone factory! The production line will be moved to Thailand, and the cost can be reduced by half!
- @Summary of ResponseBody annotation
- ESWC 2018 | r-gcn: relational data modeling based on graph convolution network
- MCU experiment record
猜你喜欢

Implementation of recommendation system collaborative filtering in spark

实战|记一次攻防演练打点

ESWC 2018 | r-gcn: relational data modeling based on graph convolution network

How to ensure data consistency between MySQL and redis?

Ora-01460: conversion request cannot be implemented or unreasonable

运筹学基础【一】 之 导论
![[detailed tutorial] a thorough article on mongodb aggregation query](/img/81/1ac7afa778849b8a4b103107fd9cb6.png)
[detailed tutorial] a thorough article on mongodb aggregation query

Kubesphere 3.3.0 offline installation tutorial

暗黑王者|ZEGO 低照度图像增强技术解析

Database design process
随机推荐
How to ensure data consistency between MySQL and redis?
Cannot make qopenglcontext current in a different thread: the solution to pyqt multithread crash
[internship] processing time
很多时候都是概率
Anaconda installs jupyter
Pychart configuration pyqt5
阿亚的角度思考
很清晰的条理
Interpretation and download of the report | ink Tianlun July database industry report, be prepared for danger in times of safety, and safety first
I didn't expect Mysql to ask these questions
[wechat applet] label (86/100)
[golang from introduction to practice] stone scissors paper game
LVGL 8.2 Span
Introduction to CpG control network
Paper:《Peeking Inside the Black Box: Visualizing Statistical Learning with Plots of Individual Condi
Libenent and libev
It we media shows off its wealth in a high profile, and is targeted by hacker organizations. It is bound to be imprisoned
GDT,LDT,GDTR,LDTR
Pyg builds GCN to realize link prediction
Network engineering case: integrated network design of CII company