Path: csiph.com!goblin3!goblin1!goblin.stu.neva.ru!uio.no!news.tele.dk!news.tele.dk!small.news.tele.dk!newsgate.cistron.nl!newsgate.news.xs4all.nl!nzpost1.xs4all.net!not-for-mail Return-Path: X-Original-To: python-list@python.org Delivered-To: python-list@mail.python.org X-Spam-Status: OK 0.005 X-Spam-Evidence: '*H*': 0.99; '*S*': 0.00; 'skip:[ 20': 0.03; 'executable': 0.07; 'trailing': 0.07; 'ast': 0.09; 'thx': 0.09; 'tuple': 0.09; 'example:': 0.10; 'comma': 0.16; 'comma,': 0.16; 'executables': 0.16; 'from:addr:martin': 0.16; '\xe9crit': 0.16; 'wrote:': 0.16; 'element': 0.18; 'cc:2**0': 0.20; 'to:2**1': 0.21; 'martin': 0.22; 'arguments': 0.22; 'setup,': 0.22; 'tuples': 0.22; 'cc:no real name:2**0': 0.22; 'import': 0.24; 'header:In-Reply- To:1': 0.24; 'function': 0.28; 'program,': 0.29; 'call.': 0.30; 'guess': 0.31; 'but': 0.36; 'there': 0.36; 'to:addr:python-list': 0.36; 'subject:: ': 0.37; 'version': 0.38; 'end': 0.39; 'why': 0.39; 'does': 0.39; 'rather': 0.39; 'to:addr:python.org': 0.40; 'hello,': 0.40; 'care': 0.60; 'vous': 0.61; 'charset:windows-1252': 0.62; 'dont': 0.64; 'dans': 0.72; 'skip:n 40': 0.72; 'received:89': 0.80; 'subject:location': 0.84 Subject: Re: Strange location for a comma To: ast , python-list@python.org References: <55e83afb$0$3157$426a74cc@news.free.fr> <55e83ce3$0$3327$426a74cc@news.free.fr> Cc: martin@mkomon.cz From: =?UTF-8?Q?Martin_Komo=c5=88?= Date: Thu, 3 Sep 2015 14:34:05 +0200 MIME-Version: 1.0 In-Reply-To: <55e83ce3$0$3327$426a74cc@news.free.fr> Content-Type: text/plain; charset=windows-1252 Content-Transfer-Encoding: 8bit X-Mailman-Approved-At: Thu, 03 Sep 2015 18:24:14 +0200 X-BeenThere: python-list@python.org X-Mailman-Version: 2.1.20+ Precedence: list List-Id: General discussion list for the Python programming language List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Newsgroups: comp.lang.python Message-ID: Lines: 42 NNTP-Posting-Host: 2001:888:2000:d::a6 X-Trace: 1441297455 news.xs4all.nl 23750 [2001:888:2000:d::a6]:37491 X-Complaints-To: abuse@xs4all.nl Xref: csiph.com comp.lang.python:95957 In this case those are not tuples but rather arguments in a function call. The extra comma does not change the evaluation, my guess is that it is there for easier adding/removing arguments without having to care about trailing commas. Martin On 03/09/15 14:28, ast wrote: > > "ast" a écrit dans le message de > news:55e83afb$0$3157$426a74cc@news.free.fr... >> Hello, >> At the end of the last line of the following program, >> there is a comma, I dont understand why ? >> >> Thx >> >> >> from cx_Freeze import setup, Executable >> >> # On appelle la fonction setup >> setup( >> name = "salut", >> version = "0.1", >> description = "Ce programme vous dit bonjour", >> executables = [Executable("salut.py")], # <--- HERE >> ) >> >> > > Ok its understood, it's a 1 element only tuple > > example: > >>>> A = 5, >>>> A > (5,) > >>>> A = (6) >>>> A > 6 >