摘要:
题目大意: 每一条边都有两个权值,val和路径长度d,要保证在valvalj,di include include include include include define RG register define il inline define iter iterator define Max( 阅读全文
摘要:
Today at the lesson Vitya learned a very interesting function — mex. Mex of a sequence of numbers is the minimum non negative number that is not prese 阅读全文
摘要:
Description 松鼠的新家是一棵树,前几天刚刚装修了新家,新家有n个房间,并且有n 1根树枝连接,每个房间都可以相互到达,且俩个房间之间的路线都是唯一的。天哪,他居然真的住在“树”上。松鼠想邀请****前来参观,并且还指定一份参观指南,他希望**能够按照他的指南顺序,先去a1,再去a2,…… 阅读全文
摘要:
Kirill plays a new computer game. He came to the potion store where he can buy any potion. Each potion is characterized by two integers — amount of ex 阅读全文
摘要:
Gleb ordered pizza home. When the courier delivered the pizza, he was very upset, because several pieces of sausage lay on the crust, and he does not 阅读全文
摘要:
Ilya is very fond of graphs, especially trees. During his last trip to the forest Ilya found a very interesting tree rooted at vertex 1. There is an i 阅读全文