Function Time Limit: 4000/2000 MS (Java/Others)    Memory Limit: 131072/131072 K (Java/Others)Total Submission(s): 652    Accepted Submission(s): 267 Sample Input 3 2 1 0 2 0 1 3 4 2 0 1 0 2 3 1 Sample Output Case #1: 4 Case #2: 4 Source 2017 Multi-U…
学长讲座讲过的,代码也讲过了,然而,当时上课没来听,听代码的时候也一脸o((⊙﹏⊙))o 我的妈呀,语文不好是硬伤,看题意看了好久好久好久(死一死)... 数学+思维题,代码懂了,也能写出来,但是还是有一点不懂,明天继续. 感谢我的队友不嫌弃我是他的猪队友(可能他心里已经骂了无数次我是猪队友了_(:з」∠)_ ) Function Time Limit: 4000/2000 MS (Java/Others)    Memory Limit: 131072/131072 K (Java/Other…
学长好久之前讲的,本来好久好久之前就要写题解的,一直都没写,懒死_(:з」∠)_ Senior Pan Time Limit: 12000/6000 MS (Java/Others)    Memory Limit: 131072/131072 K (Java/Others)Total Submission(s): 1332    Accepted Submission(s): 533 Problem Description Senior Pan fails in his discrete ma…
http://acm.hdu.edu.cn/showproblem.php?pid=6038 题意:给出两个序列,一个是0~n-1的排列a,另一个是0~m-1的排列b,现在求满足的f的个数. 思路: 先看一下样例吧: 对于这组数来说,假如我们先指定了f(0)对应的在b中的值,那么根据第2个式子,就可以得出f(1),根据f(1)就又可以得出f(2),最后根据f(2)就可以检验f(0)的值是否正确. 这也就是说,对于a中的一个循环节,只要确定了其中一个数所映射的值,那么其它数就都被相应的确定了. 所…
/* HDU 6038 - Function [ 置换,构图 ] 题意: 给出两组排列 a[], b[] 问 满足 f(i) = b[f(a[i])] 的 f 的数目 分析: 假设 a[] = {2, 0, 1} 则 f(0) = b[f(2)] f(1) = b[f(0)] f(2) = b[f(1)] 即 f(0) = b[b[b[f(0)]]] f(1) = b[b[b[f(1)]]] f(2) = b[b[b[f(2)]]] 由于将 a[i]->i 连边可以得到不相交的多个循环 可以看出…
Dying Light Time Limit: 2000/1000 MS (Java/Others)    Memory Limit: 131072/131072 K (Java/Others)Total Submission(s): 513    Accepted Submission(s): 122 Problem Description LsF is visiting a local amusement park with his friends, and a mirror room su…
KazaQ's Socks Time Limit: 2000/1000 MS (Java/Others)    Memory Limit: 131072/131072 K (Java/Others)Total Submission(s): 338    Accepted Submission(s): 212 Sample Input 3 7 3 6 4 9 Sample Output Case #1: 3 Case #2: 1 Case #3: 2 Source 2017 Multi-Unive…
Add More Zero Time Limit: 2000/1000 MS (Java/Others)    Memory Limit: 131072/131072 K (Java/Others)Total Submission(s): 398    Accepted Submission(s): 283 Sample Input 1 64   Sample Output Case #1: 0 Case #2: 19   Source 2017 Multi-University Trainin…
Function Time Limit: 4000/2000 MS (Java/Others)    Memory Limit: 131072/131072 K (Java/Others)Total Submission(s): 1025    Accepted Submission(s): 457 Problem Description You are given a permutation a from 0 to n−1 and a permutation b from 0 to m−1.…
Funny Function Time Limit: 2000/1000 MS (Java/Others)    Memory Limit: 32768/32768 K (Java/Others)Total Submission(s): 1109    Accepted Submission(s): 527 Sample Input 2 2 2 3 3 Sample Output 2 33 Source 2017 Multi-University Training Contest - Team…