Troubles with global variables

Janko Hauser jhauser at
Sun Oct 14 20:54:21 CEST 2001

Ah, silly me. The just posted example had the answer. You are not
printing the variables, but a constant string. Use this line as the
menu line, and perhaps look up the manual for string formatting rules.

print 'Menu: \n1) Change a: %s\n2) Change b: %s' % (a,b)

  Institut fuer Meereskunde             phone: 49-431-597 3989
  Dept. Theoretical Oceanography        fax  : 49-431-565876
  Duesternbrooker Weg 20                email: jhauser at
  24105 Kiel, Germany

More information about the Python-list mailing list