摘要: The kingdom of Olympia consists of N cities and M bidirectional roads. Each road connects exactly two cities and two cities can be connected with more 阅读全文
posted @ 2017-05-25 23:51 perplex 阅读(393) 评论(0) 推荐(0) 编辑
摘要: You're given a matrix A of size n × n. Let's call the matrix with nonnegative elements magic if it is symmetric (so aij = aji), aii = 0 and aij ≤ max( 阅读全文
posted @ 2017-05-25 23:46 perplex 阅读(252) 评论(0) 推荐(0) 编辑