Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.lang.python > #64865

Re: Remove unwanted characters from column

Path csiph.com!usenet.pasdenom.info!dedibox.gegeweb.org!gegeweb.eu!nntpfeed.proxad.net!proxad.net!feeder1-2.proxad.net!usenet-fr.net!nerim.net!novso.com!newsfeed.xs4all.nl!newsfeed4.news.xs4all.nl!xs4all!newsgate.cistron.nl!newsgate.news.xs4all.nl!post.news.xs4all.nl!not-for-mail
Return-Path <python-python-list@m.gmane.org>
X-Original-To python-list@python.org
Delivered-To python-list@mail.python.org
X-Spam-Status OK 0.001
X-Spam-Evidence '*H*': 1.00; '*S*': 0.00; 'from:addr:yahoo.co.uk': 0.04; 'elif': 0.05; 'column': 0.07; 'english,': 0.09; 'lawrence': 0.09; 'received:80.91': 0.09; 'received:80.91.229': 0.09; 'received:gmane.org': 0.09; 'received:list': 0.09; 'subject:characters': 0.09; 'jan': 0.12; 'language.': 0.14; 'assignment.': 0.16; 'received:80.91.229.3': 0.16; 'received:plane.gmane.org': 0.16; 'spacing': 0.16; 'subject:Remove': 0.16; 'prevent': 0.16; 'language': 0.16; 'wrote:': 0.18; 'thanks.': 0.20; '>>>': 0.22; 'header:User- Agent:1': 0.23; 'rid': 0.24; 'url:moin': 0.24; 'mon,': 0.24; 'header:X-Complaints-To:1': 0.27; 'header:In-Reply-To:1': 0.27; 'character': 0.29; 'characters': 0.30; 'statement': 0.30; 'code': 0.31; 'url:wiki': 0.31; "d'aprano": 0.31; 'steven': 0.31; 'know.': 0.32; 'supposed': 0.32; 'url:python': 0.33; 'monday,': 0.33; 'subject:from': 0.34; 'url:org': 0.36; 'january': 0.37; 'two': 0.37; 'to:addr:python-list': 0.38; 'to:addr:python.org': 0.39; 'received:org': 0.40; 'remove': 0.60; 'read': 0.60; 'above,': 0.60; 'complete': 0.62; 'address': 0.63; 'email addr:gmail.com': 0.63; 'show': 0.63; 'our': 0.64; '10:': 0.84; 'received:89': 0.85
X-Injected-Via-Gmane http://gmane.org/
To python-list@python.org
From Mark Lawrence <breamoreboy@yahoo.co.uk>
Subject Re: Remove unwanted characters from column
Date Mon, 27 Jan 2014 14:34:01 +0000
References <8d703876-ba90-492d-a558-a5a9bb8023c7@googlegroups.com> <mailman.6019.1390800112.18130.python-list@python.org> <04d509f9-54fa-4ba5-bb6e-24ce60e12523@googlegroups.com> <52e6650c$0$29999$c3e8da3$5496439d@news.astraweb.com> <9b121fe6-9ed8-4adf-af24-80166f348c7d@googlegroups.com>
Mime-Version 1.0
Content-Type text/plain; charset=ISO-8859-1; format=flowed
Content-Transfer-Encoding 7bit
X-Gmane-NNTP-Posting-Host host-89-240-164-233.as13285.net
User-Agent Mozilla/5.0 (Windows NT 6.1; rv:24.0) Gecko/20100101 Thunderbird/24.2.0
In-Reply-To <9b121fe6-9ed8-4adf-af24-80166f348c7d@googlegroups.com>
X-BeenThere python-list@python.org
X-Mailman-Version 2.1.15
Precedence list
List-Id General discussion list for the Python programming language <python-list.python.org>
List-Unsubscribe <https://mail.python.org/mailman/options/python-list>, <mailto:python-list-request@python.org?subject=unsubscribe>
List-Archive <http://mail.python.org/pipermail/python-list/>
List-Post <mailto:python-list@python.org>
List-Help <mailto:python-list-request@python.org?subject=help>
List-Subscribe <https://mail.python.org/mailman/listinfo/python-list>, <mailto:python-list-request@python.org?subject=subscribe>
Newsgroups comp.lang.python
Message-ID <mailman.6042.1390833253.18130.python-list@python.org> (permalink)
Lines 66
NNTP-Posting-Host 2001:888:2000:d::a6
X-Trace 1390833253 news.xs4all.nl 2978 [2001:888:2000:d::a6]:43669
X-Complaints-To abuse@xs4all.nl
Xref csiph.com comp.lang.python:64865

Show key headers only | View raw


On 27/01/2014 14:23, matt.s.marotta@gmail.com wrote:
> On Monday, 27 January 2014 08:54:20 UTC-5, Steven D'Aprano  wrote:
>> On Mon, 27 Jan 2014 05:32:08 -0800, matt.s.marotta wrote:
>>
>>
>>
>>> The code that I used is the proper way that we were supposed to complete
>>
>>> the assignment.  All I need now is an 'if...then' statement to get rid
>>
>>> of the unwanted FarmID at the end of the addresses.  I just don't know
>>
>>> what will come after the 'if' part.
>>
>>
>>
>> Show us what you do know. If you don't know the "if", what about the
>>
>> "then"?
>>
>>
>>
>>
>>
>> if .... :
>>
>>      do what?
>>
>>
>>
>>
>>
>> What do you intend to do inside the if? Under what circumstances would
>>
>> you do it?
>>
>>
>>
>> If you can answer those questions in English, then we can help you write
>>
>> code to do it.
>>
>>
>>
>>
>>
>> --
>>
>> Steven
>
> If the farmID < 10:
> remove one character from the address column
> Elif farmID > 10:
> remove two characters from the address column
>

Would you please read and action this 
https://wiki.python.org/moin/GoogleGroupsPython to prevent us seeing the 
double line spacing above, thanks.

-- 
My fellow Pythonistas, ask not what our language can do for you, ask 
what you can do for our language.

Mark Lawrence

Back to comp.lang.python | Previous | NextPrevious in thread | Next in thread | Find similar | Unroll thread


Thread

Remove unwanted characters from column matt.s.marotta@gmail.com - 2014-01-26 19:49 -0800
  Re:Remove unwanted characters from column Dave Angel <davea@davea.name> - 2014-01-27 00:24 -0500
    Re: Remove unwanted characters from column matt.s.marotta@gmail.com - 2014-01-27 05:32 -0800
      Re: Remove unwanted characters from column Steven D'Aprano <steve+comp.lang.python@pearwood.info> - 2014-01-27 13:54 +0000
        Re: Remove unwanted characters from column matt.s.marotta@gmail.com - 2014-01-27 06:23 -0800
          Re: Remove unwanted characters from column Mark Lawrence <breamoreboy@yahoo.co.uk> - 2014-01-27 14:34 +0000
          Re: Remove unwanted characters from column Chris Angelico <rosuav@gmail.com> - 2014-01-28 01:57 +1100
            Re: Remove unwanted characters from column matt.s.marotta@gmail.com - 2014-01-27 07:03 -0800
              Re: Remove unwanted characters from column Chris Angelico <rosuav@gmail.com> - 2014-01-28 02:19 +1100
  Re: Remove unwanted characters from column Denis McMahon <denismfmcmahon@gmail.com> - 2014-01-27 15:22 +0000

csiph-web