draw(winnerCount) {
const tickets = ["rasel", "rabina", "santo", "rajib", "billal"];
const winnerIndexes = new Array(winnerCount);
let winnerIndex = 0;
if(tickets.length){
while (winnerIndex < winnerCount) {
const ticketIndex = Math.floor(Math.random() * tickets.length);
if (!winnerIndexes.includes(ticketIndex)) {
winnerIndexes[winnerIndex++] = ticketIndex;
continue;
}
console.log("hi")
}
const winners = winnerIndexes.map((winner) => tickets[winner]);
return winners;
}
}