Practice People Whose List of Favorite Companies Is Not a Subset of Another List
Read the task, work through the examples, and check your approach against the constraints. Use the original LeetCode task for coding and submissions.
People Whose List of Favorite Companies Is Not a Subset of Another List
Problem Statement
Given the array favoriteCompanies where favoriteCompanies[i] is the list of favorites companies for the ith person (indexed from 0). Return the indices of people whose list of favorite companies is not a subset of any other list of favorites companies. You must return the indices in increasing order.
Source: People Whose List of Favorite Companies Is Not a Subset of Another List on LeetCode. Use the original task for its coding environment and submissions.
Examples
# Example 1
favoriteCompanies = [["leetcode","google","facebook"],["google","microsoft"],["google","facebook"],["google"],["amazon"]]
[0,1,4]
# Example 2
favoriteCompanies = [["leetcode","google","facebook"],["leetcode","amazon"],["facebook","google"]]
[0,1]
# Example 3
favoriteCompanies = [["leetcode"],["google"],["facebook"],["amazon"]]
[0,1,2,3]
Constraints
Related LeetCode Problems
Practice more problems similar to People Whose List of Favorite Companies Is Not a Subset of Another List.
Review your practice with PhantomCodeAI
After trying the problem yourself, use the app to discuss your approach, complexity, and edge cases.