On 2020-11-03, dn <pythonl...@danceswithmice.info> wrote: > > > The (full) specs are not clear. There's certainly room for > misunderstanding. I'd be happier if I could 'see' a full spec or > recognise a practical application, because then we'd be better able to > discuss facts. Meantime, we try to help with what we have been given... > > > The OP's sample code only realises "conforming word[s]" (good term > BTW!). The snippet does not report any "count". Similarly, there's no > facts to avoid ("I assume") an assumption about whether "Letters" may > include duplication - indeed: whether duplication has meaning or should > be regarded as user-error. >
Let me clarify what I want to do: We all know Scrabble game. there's a file with Dictionary containing word in each line, the idea is to input some letters for example mentioned earlier: att, the script supposed to find all words in which letters: 'a','t','t' occur and print these words. It supposed not to print word: 'auto' because there's only one 't' but words such as: 'toast', 'toasty', 'tolerant' are meeting the criteria becase we have in these words one 'a' and two 't' as user has input. I've checked collections counter but seems to complicated for me at this stage yet and I'm struggling with applying it. -- https://mail.python.org/mailman/listinfo/python-list