Skip to content

Conversation

@huangrui199126
Copy link
Contributor

@huangrui199126 huangrui199126 commented Aug 29, 2016

go through the test of pep8 and pylint


This change is Reviewable

go through the test of pep8 and pylint
@yukuairoy
Copy link
Contributor

Review status: 0 of 1 files reviewed at latest revision, 1 unresolved discussion.


Problems/src/Bit/word_square.py, line 4 [r1] (raw file):

Word Square definition, 0<=k<n(width/length), row k and column k are idenitcal
eg: row 1: ABCD and column 1:ABCD are the same
"""

Add a line between copy and module docstring.


Comments from Reviewable

@stonemary
Copy link
Contributor

Reviewed 1 of 1 files at r1.
Review status: all files reviewed at latest revision, 2 unresolved discussions.


Problems/src/Bit/word_square.py, line 60 [r1] (raw file):

TEST = ["ABCD", "BNRT", "CRMY", "DTYE", "CRM", "DT", "DTY"]
print word_square(TEST, 4)

print(word_square(TEST, 4)).
use print with brackets instead for py3 compatibility.


Comments from Reviewable

@yukuairoy
Copy link
Contributor

Review status: all files reviewed at latest revision, 2 unresolved discussions.


Problems/src/Bit/word_square.py, line 60 [r1] (raw file):

Previously, stonemary (小石头) wrote…

print(word_square(TEST, 4)).
use print with brackets instead for py3 compatibility.

It's of course better to move this to a separate unittest module. If you think this is too much hassle, then I prefer assert over print in this case: CORRECT_RESULT = ... assert CORRECT_RESULT == word_square(TEST, 4)

Comments from Reviewable

@stonemary
Copy link
Contributor

:lgtm:


Review status: all files reviewed at latest revision, 2 unresolved discussions.


Comments from Reviewable

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

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants