Skip to content

Static Analysis Glitch #167

Description

@BenMartinAu

Encountered in P10 on 6/8/15

def occurrences(text1, text2):
    total=0
    listchars="x"
    for i in text1:
        if i not in listchars:
            listchars += i
    for j in text2:
        if j in listchars:
            total += 1

    return total

Your for loop should iterate over the second argument

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions