Just sorting the array first and return the sum of even index element.

```
class Solution(object):
def arrayPairSum(self, nums):
"""
:type nums: List[int]
:rtype: int
"""
nums.sort()
return sum(nums[i*2] for i in range(len(nums)//2))
```