Ask Your Question

legeh's profile - activity

2014-12-09 17:08:33 +0200 commented answer How can I plot points given by code?

Ideally I would like to use a method that works for an infinite number of points (ie. for bigger ranges too). So adding them one by one is not ideal.

How do I make a list and plot it?

edit: got it

L = [(x,y,x+y-2) for x in range(11) for y in range(ceil(0.5*(x+4)),min((2*x-3),11))]
points(L)

Thanks!

2014-12-09 16:11:30 +0200 asked a question How can I plot points given by code?

I want to plot the points, that I get from the following code all together in one plot. How can I do that?

for x in range(11):
  for y in range(ceil(0.5*(x+4)),(2*x-3)):
        print (x,y,x+y-2)

Thanks