1. spirit
  2. guess_language
  3. Issues


Issue #6 invalid

check_with_enchant best_score / len(words) integer instead of float

Anonymous created an issue

The line best_score / len(words) < threshold:

always true b/c the division was treated as integer.

fix by doing something like if best_score / (float(len(words))) < threshold:

Comments (4)

  1. spirit repo owner

    This is Python 3 code. The division returns a float. If you need Python 2, the setup.py script will use 3to2 and add the from __future__ import division line.

  2. Log in to comment