[Tutor] Testing tutor list server

2016-09-20 Thread Alan Gauld via Tutor
Just checkin' -- Alan G Author of the Learn to Program web site http://www.alan-g.me.uk/ http://www.amazon.com/author/alan_gauld Follow my photo-blog on Flickr at: http://www.flickr.com/photos/alangauldphotos ___ Tutor maillist - Tutor@python.org To

Re: [Tutor] job killed: too high numbers?

2016-09-20 Thread Random832
On Tue, Sep 20, 2016, at 11:48, Gabriele Brambilla wrote: > I have this script ... > points = 3375000 ... > for iw in range(points): > print iw > does it mean that my number of points is too high? Probably. The most likely thing to cause something to exit with a status of "Killed"

Re: [Tutor] job killed: too high numbers?

2016-09-20 Thread Matt Ruffalo
Hello- On 2016-09-20 11:48, Gabriele Brambilla wrote: > does it mean that my number of points is too high? In short, yes. From your usage of the 'print' statement, you are running the code under Python 2.x. In this version of Python, the 'range' function creates a full list of numbers, and so you

Re: [Tutor] job killed: too high numbers?

2016-09-20 Thread Steven D'Aprano
On Tue, Sep 20, 2016 at 11:48:47AM -0400, Gabriele Brambilla wrote: > Hi, > > I have this script [...] > print "pastopens" > for iw in range(points): > print iw > > > But when I run it it is killed in the for cycle, it doesn't print any > number: > > [gabriele:~/Desktop/GITcode]

Re: [Tutor] New to Python, Already Confused

2016-09-20 Thread Steven D'Aprano
On Mon, Sep 19, 2016 at 11:01:30PM +, Gampper, Terry wrote: > Hello > I started my journey with Python last week and find it to be an > easy-to-learn language. I am currently teaching introduction to > computer programming. One of the assignments we are working on > involves an instructor gi

Re: [Tutor] job killed: too high numbers?

2016-09-20 Thread Wolfgang Maier
On 20.09.2016 17:48, Gabriele Brambilla wrote: Hi, I have this script import numpy as np import random as rnd from math import * import matplotlib.pyplot as plt folder = '../NOBACKUP/heavi3/' pre = '10' dat = '.dat' snshot = '4189' d = 0.02 d2 = d/2.0 tot = 156 half = 78 points = 3375000

Re: [Tutor] job killed: too high numbers?

2016-09-20 Thread Peter Otten
Gabriele Brambilla wrote: > Hi, > > I have this script > points = 3375000 > for iw in range(points): > print iw > > > But when I run it it is killed in the for cycle, it doesn't print any > number: > > [gabriele:~/Desktop/GITcode] gbrambil% python EknotFromKostas.py > im here

Re: [Tutor] job killed: too high numbers?

2016-09-20 Thread Gabriele Brambilla
Hi, The number was high but it was only a sort of test.now I learned how it works, thanks Gb On Sep 20, 2016 12:48 PM, "Matt Ruffalo" wrote: > Hello- > > On 2016-09-20 11:48, Gabriele Brambilla wrote: > > does it mean that my number of points is too high? > > In short, yes. From your usage of

Re: [Tutor] New to Python, Already Confused

2016-09-20 Thread Joel Goldstick
You should probably convert scores to ints on input. At any rate, here is your problem: low_tscore = min(tscore1,tscore2,tscore3,tscore4,tscore5) You need to convert tscore1, etc. to ints, otherwise min will give lexical comparison (alphabetic order), not numeric order On Mon, Sep 19, 2016 at 7

[Tutor] job killed: too high numbers?

2016-09-20 Thread Gabriele Brambilla
Hi, I have this script import numpy as np import random as rnd from math import * import matplotlib.pyplot as plt folder = '../NOBACKUP/heavi3/' pre = '10' dat = '.dat' snshot = '4189' d = 0.02 d2 = d/2.0 tot = 156 half = 78 points = 3375000 BxN = np.zeros((tot,tot,tot)) ByN = np.zeros((tot

[Tutor] New to Python, Already Confused

2016-09-20 Thread Gampper, Terry
Hello I started my journey with Python last week and find it to be an easy-to-learn language. I am currently teaching introduction to computer programming. One of the assignments we are working on involves an instructor giving a series of 5 tests, and the lowest score is dropped, then calculatin