exec(p1 + '=' + str(h1)) -----Original Message----- From: python-boun...@py.cz [mailto:python-boun...@py.cz] On Behalf Of "Ing. Vladislav Ludík" Sent: Tuesday, December 21, 2010 12:45 AM To: Konference PyCZ Subject: [python] vytvoření proměnných
Zdravím všechny, poradí někdo účinnou a jednoduchou metodu vytvoření spojení názvů proměnných s jejich hodnotami: x => {p1, p2, p3, ...pn} y => {h1, h2, h3, ...hn} kde p jsou proměnné a h jsou jejich hodnoty. Výsledkem by měly být deklarované proměnné s jejich hodnotami: p1 = h1 p2 = h2 p2 = h3 . . pn = hn Díky, zdraví V.L. _______________________________________________ Python mailing list Python@py.cz http://www.py.cz/mailman/listinfo/python This e-mail and any attachment is for authorised use by the intended recipient(s) only. It may contain proprietary material, confidential information and/or be subject to legal privilege. It should not be copied, disclosed to, retained or used by, any other party. If you are not an intended recipient then please promptly delete this e-mail and any attachment and all copies and inform the sender. Thank you. _______________________________________________ Python mailing list Python@py.cz http://www.py.cz/mailman/listinfo/python