From: Danny Yoo
Date: 02/18/06 15:18:14
To: Kermit Rose
Cc: Tutor
Subject: Re: [Tutor] Need to write a python and call it within a python main program (fwd)
Just as a note: please use your email client's "Reply to All" feature so
that our correspondence stays on t
> I need help on the SYNTAX of Python
>
> I have programming experience in Fortran and a little bit of C.
Ah, ok; let's see if we can transfer some concepts from your previous
experience into Python.
Just as a note: please use your email client's "Reply to All" feature so
that our correspondenc
-- Forwarded message --
Date: Sat, 18 Feb 2006 15:02:47 -0500 (Eastern Standard Time)
From: Kermit Rose <[EMAIL PROTECTED]>
To: Danny Yoo <[EMAIL PROTECTED]>
Subject: Re: [Tutor] Need to write a python and call it within a python
main program
From: Danny Yoo
>
> I need to write a function that modifies its 4 imput values,
> a,b,c,d according to the following rules.
[program description cut]
> I also need to find out how to write the main program that calls this
> function repeatedly, testing the output values for the solution to the
> equation.
Hi K
I need to write a function that modifies its 4 imput values,
a,b,c,d according to the following rules.
set j = 8 * mod(a,2) + 4 * mod(b,2) + 2 * mod(c,2) + mod(d,2)
if j = 0, a,b,c,d = a/2,b/2,c/2,d/2
if j = 1, a,b,c,d = -1,-1,-1,-1
if j = 2, a,b,c,d = a,b/2,c,d/2
if j = 3, a,b,c,d = a,(a