ServiceNow Interview Question

How would you implement a game that you throw five dices and the values are in an array and return true if the array has 4 consecutive number

Interview Answers

Anonymous

Jan 23, 2021

It's essential to demonstrate that you can really go deep... there are plenty of followup questions and (sometimes tangential) angles to explore. There's a lot of Software Engineer(Internship) experts who've worked at ServiceNow, who provide this sort of practice through mock interviews. There's a whole list of them curated on Prepfully. prepfully.com/practice-interviews

Anonymous

Jul 25, 2020

function dice (arr = [], n = 4) { let flag = 1; arr = arr.sort(); for (let i=0;i

Anonymous

Jul 25, 2020

function dice (arr = [], n = 4) { let flag = 1; arr = arr.sort(); for (let i=0; i