On Sun, Dec 7, 2008 at 12:25 PM, Lie Ryan <[EMAIL PROTECTED]> wrote:
> texts = ["a = %s\n" % plan.a,
> "b = %s\n" % plan.b,
> "c = %s\n" % plan.c,
> "d = %s\n" % plan.d
>]
>
> for text in texts:
>try:
>fo.write(text)
>except AttributeError:
>
On Mon, 01 Dec 2008 20:44:20 -0500, Bryan Fodness wrote:
> I would like to use a try except to see if a value exists. But, when I
> use the following, if a does not exist it exits. I understand why this
> does this, but is there a way to get b,c, and d if a does not exist
> without using a try e
Bryan Fodness wrote:
I would like to use a try except to see if a value exists. But, when
I use the following, if a does not exist it exits. I understand why
this does this, but is there a way to get b,c, and d if a does not
exist without using a try except for every statement?
try:
fo
On 02/12/2008, Bryan Fodness <[EMAIL PROTECTED]> wrote:
> I would like to use a try except to see if a value exists. But, when I use
> the following, if a does not exist it exits. I understand why this does
> this, but is there a way to get b,c, and d if a does not exist without using
> a try exc
I would like to use a try except to see if a value exists. But, when I use
the following, if a does not exist it exits. I understand why this does
this, but is there a way to get b,c, and d if a does not exist without using
a try except for every statement?
try:
fo.write("a = %s\n" %plan.a)