Re: Is there a way to set several list elements a same value with one line code

2015-12-03 Thread Denis McMahon
On Thu, 03 Dec 2015 16:30:25 -0800, Robert wrote: > Hi, > > I remember that there is a way to set several list elements a same value > with > one line code. Excuse me, I don't remember the accurate syntax on the > code snippet. But the basic format looks like this. > > 1. There is a four-eleme

Re: Is there a way to set several list elements a same value with one line code

2015-12-03 Thread Robert
On Thursday, December 3, 2015 at 7:59:16 PM UTC-5, MRAB wrote: > On 2015-12-04 00:30, Robert wrote: > > Hi, > > > > I remember that there is a way to set several list elements a same value > > with > > one line code. Excuse me, I don't remember the accurate syntax on the code > > snippet. But

Re: Is there a way to set several list elements a same value with one line code

2015-12-03 Thread MRAB
On 2015-12-04 00:30, Robert wrote: Hi, I remember that there is a way to set several list elements a same value with one line code. Excuse me, I don't remember the accurate syntax on the code snippet. But the basic format looks like this. 1. There is a four-element list, such as: bb=[[[

Is there a way to set several list elements a same value with one line code

2015-12-03 Thread Robert
Hi, I remember that there is a way to set several list elements a same value with one line code. Excuse me, I don't remember the accurate syntax on the code snippet. But the basic format looks like this. 1. There is a four-element list, such as: bb=[[[]],[[]],[[]],[[]]] 2. An assignment lin