Bessie
P2639 [USACO09OCT] Bessie's Weight Problem G
大概就是在不超过容量的情况下,问你最多能吃多少 是吃与不吃,选与不选的问题,所以是01背包,但是是变式 #include<bits/stdc++.h> using namespace std; const int N=5e4; int f[N],t[1000]; int main(){ int T, ......
[USACO13DEC] The Bessie Shuffle S 洗牌 题解
提供一种思路,可以做到$O(n)$。\ 目前是全`OJ`最优解,跑到了`79ms`。 `update 2023.07.29` 完工,期望无bug(暑假快乐吖o(* ̄▽ ̄*)ブ)\ `update 2023.07.27` ~~(要原题检测了,先占个坑,有时间再补)~~ ## 原题大意 [P3095 [ ......