原创 CSU-ACM2017暑期訓練12-KMP F - 前綴後綴
F - 前綴後綴 Asterix, Obelix and their temporary buddies Suffix and Prefix has finally found the Harmony temple. Howeve
原创 Problem - 557C - Codeforces - Arthur and Table
Arthur and Table Arthur has bought a beautiful big table into his new flat. When he came home, Arthur noticed that
原创 CSU1978: LXX的圖論題
CSU1978: LXX的圖論題 Description 由於lxx的圖論和數據結構太弱了,大佬Z決定爲lxx補一補。於是大佬Z爲lxx出了一道題目,題目如下:給出一張有向圖,圖中有n個點,m條邊,每條邊上都有一個權值w,問圖中是
原创 CSU-ACM2017暑期訓練14-最短路 D - 輸入量很大的模板題
D - 輸入量很大的模板題 In the age of television, not many people attend theater performances. Antique Comedians of Malidines
原创 CSU-ACM2017暑期訓練16-樹狀數組 B - Stars POJ - 2352
B - Stars Astronomers often examine star maps where stars are represented by points on a plane and each star has Ca
原创 CSU1976: 搬運工小明
CSU1976: 搬運工小明 Description 作爲老人的小明非常憂傷,因爲他馬上要被流放到本部去了,住進全左家壠最有歷史感的11舍真是一件非常榮幸的事情。 搬行李是個體力活,小明發現自己的行李太多啦,所以他決定去買很多個袋
原创 CSU1977: Bit-reversal Permutation
CSU1977: Bit-reversal Permutation Description A fast Fourier transform (FFT) algorithm computes the discrete Fourie
原创 CSU-ACM2017暑期訓練12-KMP H - 結合dp
H - 結合dp As is known to all, in many cases, a word has two meanings. Such as “hehe”, which not only means “hehe”,
原创 CSU-ACM2017暑假訓練9-區間DP F - Running
F - Running The cows are trying to become better athletes, so Bessie is running on a track for exactly N (1 ≤ N ≤ 1
原创 CSU-ACM2017暑期訓練12-KMP E - 循環
E - 循環 For each prefix of a given string S with N characters (each character has an ASCII code between 97 and 126,
原创 CSU-ACM2017暑期訓練12-KMP D - 匹配
D - 匹配 The French author Georges Perec (1936–1982) once wrote a book, La disparition, without the letter 'e'. He wa
原创 CSU-ACM2017暑期訓練16-樹狀數組 A - Ultra-QuickSort POJ - 2299
A - Ultra-QuickSort In this problem, you have to analyze a particular sorting algorithm. The algorithm processes a
原创 CSU-ACM2017暑期訓練16-樹狀數組 H - Bubble Sort HDU - 5775
H - Bubble Sort P is a permutation of the integers from 1 to N(index starting from 1). Here is the code of Bubble
原创 CSU-ACM2017暑期訓練12-KMP G - Next[]樹 CodeForces - 432D
G - Next[]樹 CodeForces - 432D You have a string s = s1s2...s|s|, where |s| is the length of string s, and si its i-
原创 CSU-ACM2017暑假訓練9-區間DP G - String painter
G - String painter There are two strings A and B with equal length. Both strings are made up of lower case letters