0

I have python 3.7 installed at /usr/local/bin/python3.7 and I recently learned about a new operator called the walrus operator := that was introduced in python 3.8 here's how it works for those who are not familiar with it as myself 5 minutes ago:

my_list = [1, 2, 3, 4, 5]

if len(my_list) > 3:
    print(f'Long list {len(my_list)}')  # len(my_list) used twice

if (n := len(my_list)) > 3:
    print(f'Long list {n}')  # len(my_list) used twice

So I installed python3.8 on my macbook to try it out using brew:

brew upgrade python@3.8

Now I have python3.8 installed at this location:

/usr/local/opt/python@3.8/bin/python3

Now I'm wondering is there a possibility to share pip3.7 / python3.7 packages with pip3.8 / python3.8 I mean is there some workaround / command to run for these packages to show using pip3.8 list without causing conflicts?

sK500
  • 1
  • 2
  • 16

0 Answers0