CHOOSE
function CHOOSE(): number | string | boolean
Description
Chooses a value or action to perform from a list of values, based on an index number.
Returns
number | string | boolean
Try It
var oWorksheet = Api.GetActiveSheet();
var oFunction = Api.GetWorksheetFunction();
oWorksheet.GetRange("A1").SetValue(oFunction.CHOOSE(2, 3, 4, 89, 76, 0));