std::vector::at
reference at (size_type n); const_reference at (size_type n) const;
Access element
Returns a reference to the element at position n in the vector.
返回一个指向位置n的元素的引用。
The function automatically checks whether n is within the bounds of valid elements in the vector, throwing an out_of_range exception if it is not (i.e., if n is greater or equal than its size). This is in contrast with member operator[], that does not check against bounds.
该方法将自动检测n是否是在一个有效的范围,如果不是则将抛出out_of_r