Rick Johnson writes:
>> There is now also a line that starts with: PCH_CPU_TEMP:
>> And I do not want that one.
>
> Yes. But be aware, that while the `str.startswith(target)`
> method is indeed more efficient than a more generalized
> "inclusion test", if the target is not _always_ at the
> begin
On Monday, December 4, 2017 at 9:44:27 AM UTC, Cecil Westerhof wrote:
> I have a script that was running perfectly for some time. It uses:
> array = [elem for elem in output if 'CPU_TEMP' in elem]
>
> But because output has changed, I have to check for CPU_TEMP at the
> beginning of the line. W
Neil Cerutti writes:
> On 2017-12-04, Cecil Westerhof wrote:
>> Joel Goldstick writes:
>>
>>> On Mon, Dec 4, 2017 at 5:21 AM, Ned Batchelder
>>> wrote:
>>>
On 12/4/17 4:36 AM, Cecil Westerhof wrote:
> I have a script that was running perfectly for some time. It uses:
> a
On 2017-12-04, Cecil Westerhof wrote:
> Joel Goldstick writes:
>
>> On Mon, Dec 4, 2017 at 5:21 AM, Ned Batchelder
>> wrote:
>>
>>> On 12/4/17 4:36 AM, Cecil Westerhof wrote:
>>>
I have a script that was running perfectly for some time. It uses:
array = [elem for elem in output if
On 12/4/2017 11:14 AM, Ned Batchelder wrote:
> On 12/4/17 9:13 AM, Rick Johnson wrote:
>> Perhaps it's not politically correct for me to say this, but
>> i've never been one who cared much about political
>> correctness, so i'm just going to say it...
>
> Cecil, feel free to ignore the rest of Rick
On 12/4/17 9:13 AM, Rick Johnson wrote:
> Perhaps it's not politically correct for me to say this, but
> i've never been one who cared much about political
> correctness, so i'm just going to say it...
Cecil, feel free to ignore the rest of Rick's message.â His messages are
famous for their outra
On Mon, Dec 4, 2017 at 5:21 AM, Ned Batchelder wrote:
> On 12/4/17 4:36 AM, Cecil Westerhof wrote:
>
>> I have a script that was running perfectly for some time. It uses:
>> array = [elem for elem in output if 'CPU_TEMP' in elem]
>>
>> But because output has changed, I have to check for CPU_
Cecil Westerhof wrote:
> Joel Goldstick writes:
[...]
> > I like Ned's clear answer, but I'm wondering why the
> > original code would fail because the substring is at the
> > start of the line, since 'in' would still be true no
> > matter where the desired string is placed. It would be
> > usef
Joel Goldstick writes:
> On Mon, Dec 4, 2017 at 5:21 AM, Ned Batchelder
> wrote:
>
>> On 12/4/17 4:36 AM, Cecil Westerhof wrote:
>>
>>> I have a script that was running perfectly for some time. It uses:
>>> array = [elem for elem in output if 'CPU_TEMP' in elem]
>>>
>>> But because output h
On 12/4/17 4:36 AM, Cecil Westerhof wrote:
> I have a script that was running perfectly for some time. It uses:
> array = [elem for elem in output if 'CPU_TEMP' in elem]
>
> But because output has changed, I have to check for CPU_TEMP at the
> beginning of the line. What would be the best way
Ned Batchelder writes:
> On 12/4/17 4:36 AM, Cecil Westerhof wrote:
>> I have a script that was running perfectly for some time. It uses:
>> array = [elem for elem in output if 'CPU_TEMP' in elem]
>>
>> But because output has changed, I have to check for CPU_TEMP at the
>> beginning of the l
Neil Cerutti writes:
> On 2017-12-04, Cecil Westerhof wrote:
>> Joel Goldstick writes:
>>
>>> On Mon, Dec 4, 2017 at 5:21 AM, Ned Batchelder
>>> wrote:
>>>
On 12/4/17 4:36 AM, Cecil Westerhof wrote:
> I have a script that was running perfectly for some time. It uses:
> a
Rick Johnson writes:
>> There is now also a line that starts with: PCH_CPU_TEMP:
>> And I do not want that one.
>
> Yes. But be aware, that while the `str.startswith(target)`
> method is indeed more efficient than a more generalized
> "inclusion test", if the target is not _always_ at the
> begin
On 2017-12-04, Cecil Westerhof wrote:
> Joel Goldstick writes:
>
>> On Mon, Dec 4, 2017 at 5:21 AM, Ned Batchelder
>> wrote:
>>
>>> On 12/4/17 4:36 AM, Cecil Westerhof wrote:
>>>
I have a script that was running perfectly for some time. It uses:
array = [elem for elem in output if
On 12/4/2017 11:14 AM, Ned Batchelder wrote:
On 12/4/17 9:13 AM, Rick Johnson wrote:
Perhaps it's not politically correct for me to say this, but
i've never been one who cared much about political
correctness, so i'm just going to say it...
Cecil, feel free to ignore the rest of Rick's message
On 12/4/17 9:13 AM, Rick Johnson wrote:
Perhaps it's not politically correct for me to say this, but
i've never been one who cared much about political
correctness, so i'm just going to say it...
Cecil, feel free to ignore the rest of Rick's message. His messages are
famous for their outrageo
Cecil Westerhof wrote:
> Joel Goldstick writes:
[...]
> > I like Ned's clear answer, but I'm wondering why the
> > original code would fail because the substring is at the
> > start of the line, since 'in' would still be true no
> > matter where the desired string is placed. It would be
> >
Joel Goldstick writes:
> On Mon, Dec 4, 2017 at 5:21 AM, Ned Batchelder
> wrote:
>
>> On 12/4/17 4:36 AM, Cecil Westerhof wrote:
>>
>>> I have a script that was running perfectly for some time. It uses:
>>> array = [elem for elem in output if 'CPU_TEMP' in elem]
>>>
>>> But because output h
Ned Batchelder writes:
> On 12/4/17 4:36 AM, Cecil Westerhof wrote:
>> I have a script that was running perfectly for some time. It uses:
>> array = [elem for elem in output if 'CPU_TEMP' in elem]
>>
>> But because output has changed, I have to check for CPU_TEMP at the
>> beginning of the l
On Mon, Dec 4, 2017 at 5:21 AM, Ned Batchelder
wrote:
> On 12/4/17 4:36 AM, Cecil Westerhof wrote:
>
>> I have a script that was running perfectly for some time. It uses:
>> array = [elem for elem in output if 'CPU_TEMP' in elem]
>>
>> But because output has changed, I have to check for CPU_
On 12/4/17 4:36 AM, Cecil Westerhof wrote:
I have a script that was running perfectly for some time. It uses:
array = [elem for elem in output if 'CPU_TEMP' in elem]
But because output has changed, I have to check for CPU_TEMP at the
beginning of the line. What would be the best way to impl
On Monday, December 4, 2017 at 9:44:27 AM UTC, Cecil Westerhof wrote:
> I have a script that was running perfectly for some time. It uses:
> array = [elem for elem in output if 'CPU_TEMP' in elem]
>
> But because output has changed, I have to check for CPU_TEMP at the
> beginning of the line.
22 matches
Mail list logo