Search
⌘K

Leetcode 2900. Longest Unequal Adjacent Groups Subsequence I

Given an array words and a parallel binary array groups, find a longest subsequence (preserving original order) of words such that the corresponding group bits strictly alternate (no two consecutive bits are equal); return any valid longest subsequence.


Question Timeline

See when this question was last asked and where, including any notes left by other candidates.

Comments

Your account is free and you can post anonymously if you choose.