DEPRECATION: The default format will switch to columns in the future.
You can use --format=(legacy|columns) (or define a format=(legacy|columns)
in your pip.conf under the [list] section) to disable this warning.
# python3.6
Python 3.6.2 (default, Aug 29 2017, 23:23:38)
[GCC 4.9.2] on linux
Type "help", "copyright", "credits" or "license" for more information.
>>> def gcd(a, b):
... if b == 0:
... return a
... else:
... return gcd(b, a % b)
...
>>> print("TheGCD for (123, 45): %d" %(gcd(123, 45)))
TheGCD for (123, 45): 3
>>>
上記と同じことをファイルを作成して実行してみる。
gcd.py
123456789
#!/usr/local/bin/python3.6defgcd(a,b):ifb==0:returnaelse:returngcd(b,a%b)print("The GCD for (123, 45): %d"%(gcd(123,45)))