Re: python logic

2017-09-01 Thread SS
On Friday, September 1, 2017 at 9:32:16 AM UTC-4, SS wrote: > Check out the following simple code: > > #!/bin/python > > print "1 - echo 1" > print "2 - echo 2" > > answer = input("Enter your choice - ") > > if answer == 1: > print "1" > elif answer == 2: > print "2" > else: > print "Inva

Re: python logic

2017-09-01 Thread Rhodri James
On 01/09/17 14:30, SS wrote: Check out the following simple code: #!/bin/python print "1 - echo 1" print "2 - echo 2" answer = input("Enter your choice - ") if answer == 1: print "1" elif answer == 2: print "2" else: print "Invalid choice!" The else statement noted above works fine

Re: python logic

2017-09-01 Thread Steve D'Aprano
On Fri, 1 Sep 2017 11:30 pm, SS wrote: > Check out the following simple code: [...] Did you read the documentation for the `input` function? In Python 2, `input` should be avoided, because it evaluates whatever the user types. Watch this: py> answer = input('type a number ') type a number 'abcd

Re: python logic

2017-09-01 Thread eth0
Era el Fri, 1 Sep 2017 06:30:43 -0700 (PDT) en comp.lang.python, cuando de repente SS dijo lo siguiente acerca de python logic: > Check out the following simple code: > > #!/bin/python > > print "1 - echo 1" > print "2 - echo 2" > > answer = i

python logic

2017-09-01 Thread SS
Check out the following simple code: #!/bin/python print "1 - echo 1" print "2 - echo 2" answer = input("Enter your choice - ") if answer == 1: print "1" elif answer == 2: print "2" else: print "Invalid choice!" The else statement noted above works fine for numeric values other then 1 o

Re: Python Logic Map/Logic Flow Chart. (Example Provided)

2010-02-10 Thread Rhodri James
On Tue, 09 Feb 2010 07:35:51 -, Gary Herron wrote: spike wrote: On Feb 8, 1:35 pm, Gary Herron wrote: spike wrote: Has anyone been able to come across a Python logic map or Python logic flow chart? An example can be seen on the right under History: http://en.wikipedia.org

Re: Python Logic Map/Logic Flow Chart. (Example Provided)

2010-02-09 Thread Steve Holden
spike wrote: > On Feb 8, 1:35 pm, Gary Herron wrote: >> spike wrote: >>> Has anyone been able to come across a Python logic map or Python logic >>> flow chart? >>> An example can be seen on the right under History: >>> http://en.wikipedia.org/wiki/Usen

Re: Python Logic Map/Logic Flow Chart. (Example Provided)

2010-02-09 Thread Jean-Michel Pichavant
I use this one: Begin | | V Start Mail client | | V Ask python-list <-+ | | | | Vwhat a bunch of dumbass wait 2 min| | | | | No. V | Did you get any answer

Re: Python Logic Map/Logic Flow Chart. (Example Provided)

2010-02-09 Thread Jean-Michel Pichavant
Carl Banks wrote: On Feb 8, 12:20 pm, spike wrote: Has anyone been able to come across a Python logic map or Python logic flow chart? An example can be seen on the right under History:http://en.wikipedia.org/wiki/Usenet#History This would be very helpful for all users. Begin

Re: Python Logic Map/Logic Flow Chart. (Example Provided)

2010-02-08 Thread Gary Herron
spike wrote: On Feb 8, 1:35 pm, Gary Herron wrote: spike wrote: Has anyone been able to come across a Python logic map or Python logic flow chart? An example can be seen on the right under History: http://en.wikipedia.org/wiki/Usenet#History This would be very helpful

Re: Python Logic Map/Logic Flow Chart. (Example Provided)

2010-02-08 Thread spike
On Feb 8, 1:35 pm, Gary Herron wrote: > spike wrote: > > Has anyone been able to come across a Python logic map or Python logic > > flow chart? > > > An example can be seen on the right under History: > >http://en.wikipedia.org/wiki/Usenet#History > > > T

Re: Python Logic Map/Logic Flow Chart. (Example Provided)

2010-02-08 Thread Carl Banks
On Feb 8, 1:35 pm, Gary Herron wrote: > spike wrote: > > Has anyone been able to come across a Python logic map or Python logic > > flow chart? > > > An example can be seen on the right under History: > >http://en.wikipedia.org/wiki/Usenet#History > > > T

Re: Python Logic Map/Logic Flow Chart. (Example Provided)

2010-02-08 Thread Carl Banks
On Feb 8, 12:20 pm, spike wrote: > Has anyone been able to come across a Python logic map or Python logic > flow chart? > > An example can be seen on the right under > History:http://en.wikipedia.org/wiki/Usenet#History > > This would be very helpful for all users. Be

Re: Python Logic Map/Logic Flow Chart. (Example Provided)

2010-02-08 Thread Gary Herron
spike wrote: Has anyone been able to come across a Python logic map or Python logic flow chart? An example can be seen on the right under History: http://en.wikipedia.org/wiki/Usenet#History This would be very helpful for all users. Huh??? What aspect of Python were you thinking of

Python Logic Map/Logic Flow Chart. (Example Provided)

2010-02-08 Thread spike
Has anyone been able to come across a Python logic map or Python logic flow chart? An example can be seen on the right under History: http://en.wikipedia.org/wiki/Usenet#History This would be very helpful for all users. -- http://mail.python.org/mailman/listinfo/python-list

Does anyone have a Python Logic Map/Flow Chart? (Example Provided)

2010-02-08 Thread spike
Has anyone been able to come across a Python logic map or flow chart? An example can be seen here on the right: http://en.wikipedia.org/wiki/Usenet This would be very helpful for users. -- http://mail.python.org/mailman/listinfo/python-list

Re: Simple question about python logic.

2007-10-12 Thread Colin J. Williams
Tim Chase wrote: >> I have a file containing following data. But the dimension can be >> different. >> >> A B C D E F G >> 3 4 1 5 6 2 4 >> 7 2 4 1 6 9 3 >> 3 4 1 5 6 2 4 >> 7 2 4 1 6 9 3 >> . >> . >> . >> . >> >> What is the best approach to make a column vector with the name such >> as A B, etc?

Re: Simple question about python logic.

2007-10-12 Thread Tim Chase
> I have a file containing following data. But the dimension can be > different. > > A B C D E F G > 3 4 1 5 6 2 4 > 7 2 4 1 6 9 3 > 3 4 1 5 6 2 4 > 7 2 4 1 6 9 3 > . > . > . > . > > What is the best approach to make a column vector with the name such > as A B, etc? There are a couple different

Re: Simple question about python logic.

2007-10-12 Thread Carl Banks
On Oct 12, 11:32 am, "[EMAIL PROTECTED]" <[EMAIL PROTECTED]> wrote: > I have a file containing following data. But the dimension can be > different. > > A B C D E F G > 3 4 1 5 6 2 4 > 7 2 4 1 6 9 3 > 3 4 1 5 6 2 4 > 7 2 4 1 6 9 3 > . > . > . > . > > What is the best approach to make a column vecto

Simple question about python logic.

2007-10-12 Thread [EMAIL PROTECTED]
I have a file containing following data. But the dimension can be different. A B C D E F G 3 4 1 5 6 2 4 7 2 4 1 6 9 3 3 4 1 5 6 2 4 7 2 4 1 6 9 3 . . . . What is the best approach to make a column vector with the name such as A B, etc? -- http://mail.python.org/mailman/listinfo/python-list