def locate_card_linear(cards, query):
    """Linear search for `query` in a desc sorted list `cards`."""
    # time complexity: O(N)
    # space complexity: O(1)
    position = 0
    while position < len(cards):
                
        # check if current elem matches the query
        if cards[position] == query:
            return position
        position += 1
        
    # if we have reached the end of the list w/out returning, 
    # then query is not in cards
    return -1