// In this problem, solve a famous programming interview question to find the index of the last occurrences of a number
// in a sorted array using binary search in O(log n) time.

// ex. input
// [1,2,2,2,2,3,4,5,5,5,5,6,6,7] 2
// [1,2,2,2,2,3,4,5,5,5,5,6,6,7] 8
// [1,2,2,2,2,3,4,5,5,5,5,6,6,7] 5

// ex. output
// 4
// -1
// 10

// In this problem, solve a famous programming interview question to find the index of the last occurrences of a number
// in a sorted array using binary search in O(log n) time.

// ex. input
// [1,2,2,2,2,3,4,5,5,5,5,6,6,7] 2
// [1,2,2,2,2,3,4,5,5,5,5,6,6,7] 8
// [1,2,2,2,2,3,4,5,5,5,5,6,6,7] 5

// ex. output
// 4
// -1
// 10

/**
 * @param {array[], number} nums k
 * @return {number}
 */


add params