Skip to content

Conversation

@simcard0000
Copy link

In reference to issue 47, brackets were added to print statements in order to make files compatible with Python 3 forward, where print statements are now functions.

def genGraphInfoBetweeness(self, centrality):
print "\n+++++++++++ %s ++++++++++++" % (centrality)
print "Calculating centrality values..."
print ("\n+++++++++++ %s ++++++++++++" % (centrality))

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Seems you're converting the code to Python 3, better to use the Python3 recommended formatting style with {}.

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Sorry for the delay, but if I may ask, can you clarify what you mean by using a formatting style with { }? Do you mean for me to further format the print statements using { }? Or the code in general? Also, if you are looking to transform all the code in the application into Python 3, may I suggest using "2to3", a Python tool for converting such code?

Copy link

@gnomezgrave gnomezgrave left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Seems you're converting the code to Python 3, better to use the Python3 recommended formatting style with {}.

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.

2 participants