Showing 3 questions
You're given a list of customer arrival and service times. Calculate the average waiting time for all customers, assuming they are served in the order they arrive.
#1. Average Waiting Time
Given a sorted array, find the first and last position of a given target value. If the target is not found, return [-1, -1].
#2. Find First and Last Position of Element in Sorted Array
Determine if every row and every column in a given square matrix contains all the numbers from 1 to n, where n is the size of the matrix. Effectively, check if it's a valid Sudoku (without subgrids).
#3. Check if Every Row and Column Contains All Numbers