Anything similar to __END__ in perl

Karsten Hilbert Karsten.Hilbert at gmx.net
Fri Dec 8 04:43:22 EST 2017


On Thu, Dec 07, 2017 at 11:55:48PM -0600, Peng Yu wrote:

> Hi, perl has __END__ which ignore all the lines below it.
> 
> Is there anything similar to __END__ in python? Thanks.

Something similar is:

	import sys
	sys.exit()

Karsten
-- 
GPG key ID E4071346 @ eu.pool.sks-keyservers.net
E167 67FD A291 2BEA 73BD  4537 78B9 A9F9 E407 1346



More information about the Python-list mailing list