mirror of
https://github.com/TheAlgorithms/Python.git
synced 2025-07-19 19:03:02 +08:00
Modernize Python 2 code to get ready for Python 3
This commit is contained in:
@ -1,3 +1,4 @@
|
||||
from __future__ import print_function
|
||||
import collections, pprint, time, os
|
||||
|
||||
start_time = time.time()
|
||||
@ -25,4 +26,4 @@ with open('anagrams.txt', 'w') as file:
|
||||
file.write(pprint.pformat(all_anagrams))
|
||||
|
||||
total_time = round(time.time() - start_time, 2)
|
||||
print('Done [', total_time, 'seconds ]')
|
||||
print(('Done [', total_time, 'seconds ]'))
|
||||
|
Reference in New Issue
Block a user