11 2017 档案
摘要:题目描述: 有n个整数(1<=n<=200000),分别为a1, a2, a3, ..., an。对于第i个整数ai,它的范围为0~10^9, 有k个整数(1<=k<=200000),分别为M1, M2, M3, ..., Mk。对于第i个整数Mi,它的范围为0~10^9。你的任务是对M1, M2,
阅读全文
摘要:题目描述: 回文词是一种对称的字符串。任意给定一个字符串,通过插入若干字符,都可以变成回文词。此题的任务是,求出将给定字符串变成回文词所需要插入的最少字符数。 比如 “Ab3bd”插入2个字符后可以变成回文词“dAb3bAd”或“Adb3bdA”,但是插入少于2个的字符无法变成回文词。 注:此问题区
阅读全文
摘要:题目描述: Vasiliy has an exam period which will continue for n days. He has to pass exams on m subjects. Subjects are numbered from 1 to m. About every da
阅读全文
摘要:题目描述: 一个除1以外的正整数都能被分解为若干个质因子的乘积。比如24 = 2 * 2 * 2 * 3。现在给你m, n, 求[m, n]内的所有正整数被分解为质因子的个数总和。 例如 : m = 5, n = 9时 : 5 = 5 1 6 = 2 * 3 2 7 = 7 1 8 = 2 * 2
阅读全文
摘要:题目描述: On his trip to Luxor and Aswan, Sagheer went to a Nubian market to buy some souvenirs for his friends and relatives. The market has some strange
阅读全文
摘要:题目描述:One day n friends gathered together to play "Mafia". During each round of the game some player must be the supervisor and other n - 1 people take
阅读全文
浙公网安备 33010602011771号