Write a function `paginate` that takes an array, a page number, and a page size, and returns the items on that page. Pages are 1-indexed.
Input: paginate([1,2,3,4,5], 2, 2)
Output: [3, 4]
Explanation: Page 2 with size 2 is [3, 4].
Input: paginate([1,2,3,4,5], 3, 2)
Output: [5]
Explanation: Only one item on page 3.