Farmer John's N (1
Farmer John's N (1 <= N <= 100,000) cows, conveniently numbered 1..N, are once again standing in a row. Cow i has height Hi (1 <= Hi <= 1,000,000). Each cow is looking to her left toward those with higher index numbers. We say that cow i 'looks up' to cow j if i < j and Hi < Hj. For each cow i, FJ would like to know the index of the first cow in line looked up to by cow i. Note: about 50% of the test data will have N <= 1,000.
![HBC24840ShiftandReverse,哈希[USACO 2009 Mar S]Look Up题解
-第1张图片-东莞河马信息技术 HBC24840ShiftandReverse,哈希[USACO 2009 Mar S]Look Up题解
-第1张图片-东莞河马信息技术](https://www.xxstcz.com/zb_users/upload/2023/11/20231121215702170057502212705.jpeg)
(图片来源网络,侵删)