随笔分类 - 预处理-前缀和
摘要:描述 Given an N*N matrix, find the coolest square sub-matrix.We define the cool value of the square matrix as X-Y where X indicating the sum of all inte
阅读全文
摘要:Description 给定一系列非负整数,求最长的连续子序列,使其和是7的倍数。 Input 第一行为正整数N(1<=N<=50000),接下来有N行,每行有一个非负整数,所有整数不大于10^6。 Output 如果存在连续子序列,其和为7的倍数,则输出子序列长度,如果不存在则输出0。 Sampl
阅读全文