[00:28:09] *** Joins: nocaic_ (nocaic@RBOSE-qdg032.unitymediagroup.de) [00:32:21] *** Quits: nocaic (nocaic@RBOSE-qdg032.unitymediagroup.de) (Connection closed) [00:58:00] *** Quits: Kebap (Max@RBOSE-o7vsf2.adsl.alicedsl.de) (Quit: adios amigos) [01:02:33] *** Quits: Caly (Caly@RBOSE.org) (Quit: Leaving) [01:12:16] *** Quits: kalken (default@RBOSE-q49a9j.bredband.comhem.se) (Ping timeout: 241 seconds) [01:20:47] *** livE is now known as DNS [02:26:17] *** Joins: nocaic (nocaic@RBOSE-qdg032.unitymediagroup.de) [02:33:15] *** Quits: nocaic_ (nocaic@RBOSE-qdg032.unitymediagroup.de) (Ping timeout: 241 seconds) [04:35:32] *** Joins: nocaic_ (nocaic@RBOSE-qdg032.unitymediagroup.de) [04:42:31] *** Quits: nocaic (nocaic@RBOSE-qdg032.unitymediagroup.de) (Ping timeout: 241 seconds) [07:00:01] *** Quits: jscinoz (jscinoz@RBOSE-rdhsrj.tpgi.com.au) (Ping timeout: 241 seconds) [07:09:13] *** Joins: nocaic (nocaic@RBOSE-qdg032.unitymediagroup.de) [07:16:13] *** Quits: nocaic_ (nocaic@RBOSE-qdg032.unitymediagroup.de) (Ping timeout: 241 seconds) [08:19:04] *** Joins: jscinoz (jscinoz@RBOSE-rdhsrj.tpgi.com.au) [08:30:41] *** Joins: nocaic_ (nocaic@RBOSE-qdg032.unitymediagroup.de) [08:37:40] *** Quits: nocaic (nocaic@RBOSE-qdg032.unitymediagroup.de) (Ping timeout: 241 seconds) [08:47:14] *** Joins: kalken (default@RBOSE-q49a9j.bredband.comhem.se) [10:01:21] *** Joins: nocaic (nocaic@RBOSE-qdg032.unitymediagroup.de) [10:08:20] *** Quits: nocaic_ (nocaic@RBOSE-qdg032.unitymediagroup.de) (Ping timeout: 241 seconds) [11:16:45] *** Joins: nocaic_ (nocaic@RBOSE-qdg032.unitymediagroup.de) [11:23:43] *** Quits: nocaic (nocaic@RBOSE-qdg032.unitymediagroup.de) (Ping timeout: 241 seconds) [11:37:08] hi folks - anyone in? [11:37:13] *** nocaic_ is now known as nocaic [11:39:14] what is the best way to replicate ' 1:n ' data structures in python indexed by '1' ? [11:44:34] nocaic, you want to numerate elements in a different way? or are you talking about db one-to-many relations? [11:44:51] could you rephrase maybe the question a bit? [11:46:59] lukas: I am talking bout some container with this sorta content==> username : mailaddr1@foo.com mailaddr2@bar.org mailaddr3@baz.net [11:47:32] need to get the emails returned by looking up the username [11:49:12] you can use standard build in types like tuples, list, sets or dictionaries [11:51:16] with tuples and list you would need to operate on indexes of items but you could search for it, with dictionaries you can simply look up for a keyword [11:51:46] ofc you can as well create your own objects as another solution [11:55:06] nocaic, many developers claim that dictionaries are the fastest solution to later iterate through them, but whatever you choose, will work, you can always optimize it for speed later [11:56:03] which version of python you are using? [11:58:50] if you need a concrete example, we may jump into gobby [12:03:25] lukas: I was thinking a dict is probably the best solution. Thx for your efforts anyway. it is to be deployed on python 2.x afaik... [12:03:50] seeing as I am at work, gobby might not be the most handsome idea, however I am flattered for the offer ;D [12:04:32] nocaic: maybe you want some lambda-function? [12:06:30] kalken: think I already got it running. I am a bit confused, as I am programming something I still have not grasped the full details of - yet... [12:07:43] nocaic, but you want to get just a list of all emails from your data structure? [12:08:34] if so, then i would suggest make a list with dictionary objects like: [{"username":"name1", "email":"email1"}, {"username":"name2", "email":"email2",} [12:08:41] and then to get the emails: [12:09:14] emails = [user['email'] for user in users] [12:09:30] where users would be that list defined previously [12:09:47] lukas: awesome :) [12:10:16] gotta run - meeting m( [12:10:32] if you need indexes, then in very similar way, if you need to filter that by any criteria, simple as well, but let me know [12:11:09] *** Joins: Caly (Caly@RBOSE.org) [12:59:53] *** Joins: Calyp (Caly@RBOSE.org) [13:04:44] *** Quits: Caly (Caly@RBOSE.org) (Ping timeout: 241 seconds) [13:17:12] *** Quits: Calyp (Caly@RBOSE.org) (Ping timeout: 241 seconds) [13:18:46] *** Joins: kman (kman@RBOSE-hhm.9h0.94.93.IP) [13:28:40] *** Joins: Calyp (Caly@RBOSE.org) [13:32:48] *** Quits: kman (kman@RBOSE-hhm.9h0.94.93.IP) (Connection closed) [13:33:40] *** Joins: kman (kman@RBOSE-hhm.9h0.94.93.IP) [13:39:21] *** Joins: nocaic_ (nocaic@RBOSE-qdg032.unitymediagroup.de) [13:43:42] *** Quits: nocaic (nocaic@RBOSE-qdg032.unitymediagroup.de) (Connection closed) [13:49:30] *** Quits: kman (kman@RBOSE-hhm.9h0.94.93.IP) (Ping timeout: 241 seconds) [14:11:31] *** Quits: Slush- (Slush-@RBOSE-uu2jnl.cust.bredbandsbolaget.se) (Ping timeout: 241 seconds) [14:37:04] *** Joins: kman (kman@RBOSE-hhm.9h0.94.93.IP) [14:39:29] *** Joins: Slush- (Slush-@RBOSE-uu2jnl.cust.bredbandsbolaget.se) [14:46:01] *** Quits: kman (kman@RBOSE-hhm.9h0.94.93.IP) (Ping timeout: 241 seconds) [14:48:36] *** Joins: kman (kman@RBOSE-hhm.9h0.94.93.IP) [14:53:19] *** Quits: kman (kman@RBOSE-hhm.9h0.94.93.IP) (Connection closed) [16:50:39] *** Joins: nocaic (nocaic@RBOSE-qdg032.unitymediagroup.de) [16:54:58] *** Quits: nocaic_ (nocaic@RBOSE-qdg032.unitymediagroup.de) (Connection closed) [17:47:42] *** Joins: nocaic_ (nocaic@RBOSE-qdg032.unitymediagroup.de) [17:54:41] *** Quits: nocaic (nocaic@RBOSE-qdg032.unitymediagroup.de) (Ping timeout: 241 seconds) [18:14:19] *** Joins: nocaic (nocaic@RBOSE-qdg032.unitymediagroup.de) [18:17:55] *** Joins: Kebap (Max@RBOSE-b2t73m.adsl.alicedsl.de) [18:21:19] *** Quits: nocaic_ (nocaic@RBOSE-qdg032.unitymediagroup.de) (Ping timeout: 241 seconds) [19:46:58] *** Joins: nocaic_ (nocaic@RBOSE-qdg032.unitymediagroup.de) [19:53:57] *** Quits: nocaic (nocaic@RBOSE-qdg032.unitymediagroup.de) (Ping timeout: 241 seconds) [20:08:29] *** Joins: nocaic (nocaic@RBOSE-qdg032.unitymediagroup.de) [20:15:29] *** Quits: nocaic_ (nocaic@RBOSE-qdg032.unitymediagroup.de) (Ping timeout: 241 seconds) [20:27:53] *** Joins: BranManFloMore (BranManFloMor@RBOSE-i97fcv.biz.rr.com) [21:47:10] *** Joins: nocaic_ (nocaic@RBOSE-qdg032.unitymediagroup.de) [21:53:19] *** Quits: nocaic (nocaic@RBOSE-qdg032.unitymediagroup.de) (Connection closed) [23:39:10] *** Joins: nocaic (nocaic@RBOSE-qdg032.unitymediagroup.de) [23:46:09] *** Quits: nocaic_ (nocaic@RBOSE-qdg032.unitymediagroup.de) (Ping timeout: 241 seconds)