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


Groups > comp.lang.python > #11306

Re: Java is killing me! (AKA: Java for Pythonheads?)

Path csiph.com!x330-a1.tempe.blueboxinc.net!usenet.pasdenom.info!news.albasani.net!feeder.news-service.com!newsfeed.xs4all.nl!newsfeed6.news.xs4all.nl!xs4all!post.news.xs4all.nl!not-for-mail
Return-Path <rosuav@gmail.com>
X-Original-To python-list@python.org
Delivered-To python-list@mail.python.org
X-Spam-Status OK 0.008
X-Spam-Evidence '*H*': 0.98; '*S*': 0.00; 'ugly': 0.07; 'python': 0.08; 'myself,': 0.09; 'programmer': 0.10; 'argument': 0.15; '(eg': 0.16; 'bounds': 0.16; 'from:addr:rosuav': 0.16; 'from:name:chris angelico': 0.16; 'justify': 0.16; 'subject:?)': 0.16; 'subject:Java': 0.16; 'wrote:': 0.16; 'arguments': 0.18; 'figure': 0.21; 'header:In-Reply-To:1': 0.22; 'optional': 0.23; 'pm,': 0.24; 'aug': 0.24; 'posted': 0.26; 'message- id:@mail.gmail.com': 0.29; 'specified': 0.31; 'does': 0.32; 'actually': 0.33; 'there': 0.33; 'to:addr:python-list': 0.33; 'fri,': 0.36; 'but': 0.37; 'received:google.com': 0.38; 'received:209.85': 0.38; 'subject:: ': 0.39; 'suggestions': 0.39; 'either': 0.39; 'meaning': 0.39; 'to:addr:python.org': 0.39; 'sense': 0.39; "it's": 0.40; '100%': 0.82; 'flexibility,': 0.84; 'cope': 0.91
DKIM-Signature v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :content-type; bh=FUwI1IEd8o6t9YTZ4a/jtX6wziKpQwCjidkFsVduXiA=; b=hWFOr+OIA4MpOhTKs6BT8RuuJkQ1dL/011/h3w6kOGr8DNQO9oMRzDH17ijvFp5CtV Sae5CaCOHNCFhvWhccxKz5iQ+SNc6uDYqetOsutqPjhL3rKXfAN7IPqUiaBYpy6js6x8 /MIwMH5qEzya5qU1xqn8aK2/gMxQcfafQ3YqA=
MIME-Version 1.0
In-Reply-To <j23mbe$nfe$1@reader1.panix.com>
References <j23mbe$nfe$1@reader1.panix.com>
Date Fri, 12 Aug 2011 21:39:33 +0100
Subject Re: Java is killing me! (AKA: Java for Pythonheads?)
From Chris Angelico <rosuav@gmail.com>
To python-list@python.org
Content-Type text/plain; charset=ISO-8859-1
X-BeenThere python-list@python.org
X-Mailman-Version 2.1.12
Precedence list
List-Id General discussion list for the Python programming language <python-list.python.org>
List-Unsubscribe <http://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 <http://mail.python.org/mailman/listinfo/python-list>, <mailto:python-list-request@python.org?subject=subscribe>
Newsgroups comp.lang.python
Message-ID <mailman.2237.1313181576.1164.python-list@python.org> (permalink)
Lines 18
NNTP-Posting-Host 2001:888:2000:d::a6
X-Trace 1313181576 news.xs4all.nl 23932 [2001:888:2000:d::a6]:49662
X-Complaints-To abuse@xs4all.nl
Xref x330-a1.tempe.blueboxinc.net comp.lang.python:11306

Show key headers only | View raw


On Fri, Aug 12, 2011 at 6:02 PM, kj <no.email@please.post> wrote:
> I ask myself, how does the journeyman Python programmer cope with
> such nonsense?
>

Firstly, figure out how many combinations of optional arguments
actually make sense. Any that don't, don't support. That may well cut
it down significantly. And then, if there are any that make sense but
will be really rare (eg if you allow optional specification of a max
and a min, and most times you'll use either both bounds or neither),
you can save a few by having the "optional" argument specified with a
sentinel meaning "default". It's ugly in a few places to justify
simplicity in most.

If you really need 100% flexibility, then the suggestions already
posted will definitely be the best.

ChrisA

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


Thread

Java is killing me! (AKA: Java for Pythonheads?) kj <no.email@please.post> - 2011-08-12 17:02 +0000
  Re: Java is killing me! (AKA: Java for Pythonheads?) Nathan Rice <nathan.alexander.rice@gmail.com> - 2011-08-12 13:15 -0400
  Re: Java is killing me! (AKA: Java for Pythonheads?) MRAB <python@mrabarnett.plus.com> - 2011-08-12 18:35 +0100
    Re: Java is killing me! (AKA: Java for Pythonheads?) rav <rafalgulinski@gmail.com> - 2011-08-13 06:17 -0700
  Re: Java is killing me! (AKA: Java for Pythonheads?) Alain Ketterlin <alain@dpt-info.u-strasbg.fr> - 2011-08-12 19:45 +0200
  Re: Java is killing me! (AKA: Java for Pythonheads?) Miki Tebeka <miki.tebeka@gmail.com> - 2011-08-12 11:18 -0700
  Re: Java is killing me! (AKA: Java for Pythonheads?) Chris Angelico <rosuav@gmail.com> - 2011-08-12 21:39 +0100
  Re: Java is killing me! (AKA: Java for Pythonheads?) Dennis Lee Bieber <wlfraed@ix.netcom.com> - 2011-08-12 23:31 -0700
  Re: Java is killing me! (AKA: Java for Pythonheads?) Dirk Olmes <dirk@xanthippe.ping.de> - 2011-08-15 16:16 +0000

csiph-web