1
0
Fork 0

rozwiazanie zad 2

This commit is contained in:
s407531 2018-05-13 09:53:19 +02:00
parent f64e91b82f
commit 46c569c67b
1 changed files with 9 additions and 1 deletions

View File

@ -11,9 +11,17 @@ litery. (OOV = out of vocabulary) (W pythonie istnieje struktura danych tak
jak 'set', która przechowuje elementy bez powtórzeń.) jak 'set', która przechowuje elementy bez powtórzeń.)
""" """
from sets import Set
def oov(text, vocab): def oov(text, vocab):
pass rozdzielenie=text.split(' ')
slowo=set()
slowo=(slowo for slowo in rozdzielenie if slowo not in vocab)
return slowo