Ad
  • Custom User Avatar

    This solution is actually inappropriate, given that a "words" like "ƒ©˙∆" or "eабвгдеёжзийклмнопрстуфхцчшщъыьэюя" are indeed isograms because they have no repeating letters or glyphs.

    Only the second condition is required, which would then make this solution the same as the most upvoted.

  • Custom User Avatar

    This code performs roughly twice as much work as is necessary.

    1. Every iteration tests if the word is 'needle' or not.
    2. If the word is 'needle' the value of the expression returned is calculated, which is the first occurence of the string 'needle' in haystack, effectively nearly doubling the work.

    If the input is the following list the work is exactly doubled: ['pin', 'sword', 'knife', 'needle'].

  • Custom User Avatar

    Thanks! I'm just beginning to get back into Python, so this was cobbled together!

    I'm sure I'll learn lots from the community here. It's good so far!