code: def SNTV_winners(self, profile, K):
          
  
          # Currently, we expect the profile to contain complete ordering over candidates. Ties are
          # allowed however.
          elecType = profile.getElecType()
          if elecType != "soc" and elecType != "toc" and elecType != "csv":
              print("ERROR: unsupported election type")
              exit()
  
          m = profile.numCands
          candScoresMap = MechanismPlurality().getCandScoresMap(profile)
          if K >= m:
              return list(candScoresMap.keys())
          # print(candScoresMap)
          sorted_items = sorted(candScoresMap.items(), key=lambda x: x[1], reverse=True)
          sorted_dict = {key: value for key, value in sorted_items}
          winners = list(sorted_dict.keys())[0:K]
          return winners
docs: Returns a list that associates all the winners of a profile under Single non-transferable vote rule.
  
          :ivar Profile profile: A Profile object that represents an election profile.