Check Strict Superset

Sort by

recency

|

1138 Discussions

|

  • + 0 comments

    I did it like this:

    # Enter your code here. Read input from STDIN. Print output to STDOUT
    
    A = set(map(int, input().split()))
    T = int(input())
    
    is_superset = True
    for i in range(T):
        B = set(map(int, input().split()))
        if not A.issuperset(B):
            is_superset =False
            break
    print(is_superset)
            
    
  • + 0 comments

    A = set(input().split()) n = int(input()) ans = True for i in range(n): otherset = set(input().split()) if ( not A.issuperset(otherset)): ans = False break print(ans)

  • + 0 comments

    d=True a=set(map(int,input().split())) if len(a) >0 and len(a) <501: b=int(input()) if b>0 and b<21: for i in range(b): c=set(map(int,input().split())) if len(c)>0 and len(c)<101: if not a.issuperset(c): d=False break

    print(d)

  • + 0 comments

    Ahha-ha! funny language

    A = set(map(int, input().split()))
    N = int(input())
    res = True
    while N > 0 and res:
        N -=1
        res = A.issuperset(set(map(int, input().split())))
    print (res)
    

    `

  • + 0 comments
    SetA = set(input(``).split())
    n = int(input())``
    result = True
    for i in range(n):
        current_set = set(input().split())
        if not SetA.issuperset(current_set):
            result = False
            break
    print(result)`