SentinelOne interview question

Time complexity discussions on the above problems