Pastebin
API
tools
faq
paste
Login
Sign up
SHARE
TWEET
Untitled
a guest
Jul 20th, 2018
261
0
Never
Add comment
Not a member of Pastebin yet?
Sign Up
, it unlocks many cool features!
text
0.18 KB
| None
|
0
0
raw
download
clone
embed
print
report
LL dp[301][2501];
dp[0][1] = 1;
for (int i = 0; i < n; i++) {
for (int j = 0; j < 2500; j++) {
dp[i + 1][j * a[i] % (p * q)] += dp[i][j];
}
}
LL answer = dp[n][0];
Add Comment
Please,
Sign In
to add comment
Public Pastes
Untitled
PHP | 25 sec ago | 0.49 KB
input_select card
YAML | 10 min ago | 2.25 KB
2 log
HTML | 23 min ago | 0.07 KB
users
PHP | 24 min ago | 3.99 KB
Powershell - Example of mysqldump
PowerShell | 24 min ago | 1.03 KB
search
PHP | 25 min ago | 1.26 KB
Untitled
Go | 26 min ago | 1.80 KB
TTD Best Script
Lua | 27 min ago | 0.21 KB
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the
Cookies Policy
.
OK, I Understand
Not a member of Pastebin yet?
Sign Up
, it unlocks many cool features!