Re: what is new with int conversion in Python 3

2016-05-22 Thread Sayth Renshaw
On Sunday, 22 May 2016 17:26:51 UTC+10, Sayth Renshaw wrote: > I am doing a passage in a book that was written for python 2 i am writing > everything in 3. > > This is the author Ivan Idris code to show time difference between python and > numpy arrays. The only edit I made was to fix the print

Re: what is new with int conversion in Python 3

2016-05-22 Thread Peter Otten
Sayth Renshaw wrote: Read carefully: > Run from the command line as follows > > python vectorsum.py n > > where n is an integer that specifies the size of the vectors. So to run the script with Python 3 you could do $ python3 vectorsum.py 42 in the shell. This implicitly sets sys.argv[1]

Re: what is new with int conversion in Python 3

2016-05-22 Thread Steven D'Aprano
On Sun, 22 May 2016 05:26 pm, Sayth Renshaw wrote: > I am doing a passage in a book that was written for python 2 i am writing > everything in 3. [...] > However when I run this I get a valuerror. So either something has changed > with int or datetime I cannot google a consistent answer. Neither

Re: what is new with int conversion in Python 3

2016-05-22 Thread Chris Angelico
On Sun, May 22, 2016 at 5:26 PM, Sayth Renshaw wrote: > However when I run this I get a valuerror. So either something has changed > with int or datetime I cannot google a consistent answer. > > > --- > ValueError

what is new with int conversion in Python 3

2016-05-22 Thread Sayth Renshaw
I am doing a passage in a book that was written for python 2 i am writing everything in 3. This is the author Ivan Idris code to show time difference between python and numpy arrays. The only edit I made was to fix the print statements. #!/usr/bin/env/python import sys from datetime import dat