HBC15879A Simple Problem题解

一天到晚红烧的鱼 算法基础篇 59 0
不断提升技能,才能在职场中立于不败之地!全网最全C++题库,助您成为编程领域的佼佼者。
It’s universally acknowledged that there’re innumerable trees in the campus of HUST.In HUST there is a famous road named YuYuan Rd linking the west campus with the east. Different types of trees are planted aside the road symmetrically. Each pair of trees on this road are given a value ai, specifying the type of trees in position i from west to east. One day, Coach Yin goes back to the dormitory from No.9 building at lunchtime. Unfortunately, he fails in finding the grandiose YunYuan Hotel. What he only remembers is the type of trees in the front of the hotel, which is an interval of the sequence described before. Moreover, he cannot classify types of tree correctly, and may identify several type of tree with other numbers. In specific, positions with different numbers are still different, while positions with same value remain consistent. Coach Yin loves the food in YunYuan Hotel. You should tell him how many places he should go to find out the hotel.

It’s universally acknowledged that there’re innumerable trees in the campus of HUST. In HUST there is a famous road named YuYuan Rd linking the west campus with the east. Different types of trees are planted aside the road symmetrically. Each pair of trees on this road are given a value ai, specifying the type of trees in position i from west to east. One day, Coach Yin goes back to the dormitory from No.9 building at lunchtime. Unfortunately, he fails in finding the grandiose YunYuan Hotel. What he only remembers is the type of trees in the front of the hotel, which is an interval of the sequence described before. Moreover, he cannot classify types of tree correctly, and may identify several type of tree with other numbers. In specific, positions with different numbers are still different, while positions with same value remain consistent. Coach Yin loves the food in YunYuan Hotel. You should tell him how many places he should go to find out the hotel.

HBC15879A Simple Problem题解
-第1张图片-东莞河马信息技术
(图片来源网络,侵删)
成为编程大师,不再是梦想!全网最全C++题库,助您开启编程新篇章。

标签: HBC15879A Simple Problem题解