{"user_id":"anon_1da38bbb7f3b2cdf","answerer_user_id":"anon_fb6c3730b0c63815","subreddit":"programming","timestamp":"2006-12-20T18:20:52+00:00","post_id":"viqs","question":"Why haven't you written a book about Haskell?","preferred_answer":"It's called print.\r\n\r\nprint :: (Show a) => a -> IO ()\r\n\r\nprint = putStrLn . show\r\n\r\nReally. Anything that derives or instances Show can be printed.","full_conversation":[{"role":"OP","user_id":"anon_1da38bbb7f3b2cdf","comment_id":"viqs","kind":"post","text":"Why haven't you written a book about Haskell?","timestamp":"2006-12-20T18:20:52+00:00","score":12},{"role":"answerer","user_id":"anon_fb6c3730b0c63815","comment_id":"cvj36","kind":"comment","text":"It's called print.\r\n\r\nprint :: (Show a) => a -> IO ()\r\n\r\nprint = putStrLn . show\r\n\r\nReally. Anything that derives or instances Show can be printed.","timestamp":"2006-12-20T19:16:55+00:00","score":4},{"role":"OP","user_id":"anon_1da38bbb7f3b2cdf","comment_id":"cvj43","kind":"comment","text":"Thanks. I don't know how many tuts I've waded through that only show printStr.","timestamp":"2006-12-20T19:23:23+00:00","score":2},{"role":"answerer","user_id":"anon_fb6c3730b0c63815","comment_id":"cvj5w","kind":"comment","text":"I am a bit confused why you mention dynamic languages, but do not want to work with an interpreter available.\r\n\r\nOf course, I won't stop you from working how you like, and there was certainly an answer to your question.\r\n\r\nThe way I work with Haskell code is to edit it alongside a running copy of ghci which I constantly reload in. Emacs supports this particular style of development with integration between the two. I'm sure there's similar plugins for other editors.\r\n\r\nI became very accustomed to this from working with Common Lisp, where like Smalltalk, programmers tend to work within a dynamically changing environment with immediate feedback from recompiled code.\r\n\r\nThere are a lot of advantages besides being able to type expressions at the prompt. Having immediate and referenced feedback on type errors is nice. Being able to query types and information about program identifiers is also very useful.","timestamp":"2006-12-20T19:30:21+00:00","score":1}],"n_turns":4,"n_turns_after_thanks":1,"op_metadata":{"user_id":"anon_1da38bbb7f3b2cdf","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_fb6c3730b0c63815","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"cvj36","thanks_reply_id":"cvj43","post_score":12,"answer_score":4,"preferred_answer_is_top_level":false}}
{"user_id":"anon_a6e77aa1364ce6bf","answerer_user_id":"anon_5b278eabf51f968d","subreddit":"programming","timestamp":"2007-02-13T19:15:31+00:00","post_id":"14dfy","question":"How do you quit your Java (J2EE) Programming job to do something more interesting","preferred_answer":"Actually, that's why I used job board aggregators like http://www.indeed.com and http://www.simplyhired.com -- when you are looking for something more rare, they work pretty well. If you do a search, they both give you an RSS link to the search so you can monitor it over time. I found my current job that way -- it took months of keeping up with the feed to find what I was looking for, but I would never have found it otherwise.","full_conversation":[{"role":"OP","user_id":"anon_a6e77aa1364ce6bf","comment_id":"14dfy","kind":"post","text":"How do you quit your Java (J2EE) Programming job to do something more interesting","timestamp":"2007-02-13T19:15:31+00:00","score":27},{"role":"answerer","user_id":"anon_5b278eabf51f968d","comment_id":"c14dx8","kind":"comment","text":"Actually, that's why I used job board aggregators like http://www.indeed.com and http://www.simplyhired.com -- when you are looking for something more rare, they work pretty well. If you do a search, they both give you an RSS link to the search so you can monitor it over time. I found my current job that way -- it took months of keeping up with the feed to find what I was looking for, but I would never have found it otherwise.","timestamp":"2007-02-13T20:28:22+00:00","score":5},{"role":"OP","user_id":"anon_a6e77aa1364ce6bf","comment_id":"c14dyn","kind":"comment","text":"Thanks. I am not implying that I just 'wont' work with java. It is more the culture surrounding J2EE development that really doesnt encourage innovation and users and management are in complete control.","timestamp":"2007-02-13T20:35:13+00:00","score":3},{"role":"answerer","user_id":"anon_5b278eabf51f968d","comment_id":"c14e82","kind":"comment","text":"Do you work for internal IT or a software company? I think environment differences have to do more with what the focus of the company is rather than what technology it uses.\r\n\r\nWhen I was working in J2EE as in in-house developer, the project was actually pretty ok and well run. The rest of the company was pathological and made the environment unbearable. That same exact project in another company would have been totally fine. \r\n\r\nNow I work in .NET for a software company -- we sell software, so we really care about it -- software is an asset and developers are investment, not a cost center (the way non-software companies think of them). The difference in environment has nothing to do with the differences between Java and .NET.","timestamp":"2007-02-13T21:16:13+00:00","score":10}],"n_turns":4,"n_turns_after_thanks":1,"op_metadata":{"user_id":"anon_a6e77aa1364ce6bf","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_5b278eabf51f968d","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c14dx8","thanks_reply_id":"c14dyn","post_score":27,"answer_score":5,"preferred_answer_is_top_level":false}}
{"user_id":"anon_9becfdbd6554b5e0","answerer_user_id":"anon_d13585895a3e0bd6","subreddit":"programming","timestamp":"2007-02-27T20:53:33+00:00","post_id":"16wlm","question":"Why Rails Fixtures are No Fun","preferred_answer":"Fixtures shouldn't have hard-coded IDs in them. That's just asking for trouble.\r\n\r\nIt's Python, but I wrote [NonMockObjects](http://www.jerf.org/programming/nonMockObjects.html) basically for this same reason. (Well, actually, I just skipped over the part where I tried to hard-code my test database rows, since I lucked into a situation where once I realized I needed test data, the requisite data was already too complicated to hard code in any reasonable amount of time.) Perhaps a Ruby port would be a good idea. NonMockObjects is currently in use in a Django environment, which is very similar, so I know the idea is sound.\r\n\r\nWith a bit of library support and the right structure, I find generating test data via code to be about an order of magnitude or so easier, and I just don't get everyone's apparent obsession with test fixtures which, being static data and not code, are not particularly amenable to refactoring, abstraction, or any of the other advantages of living code over dead data.","full_conversation":[{"role":"OP","user_id":"anon_9becfdbd6554b5e0","comment_id":"16wlm","kind":"post","text":"Why Rails Fixtures are No Fun","timestamp":"2007-02-27T20:53:33+00:00","score":5},{"role":"answerer","user_id":"anon_d13585895a3e0bd6","comment_id":"c16z51","kind":"comment","text":"Fixtures shouldn't have hard-coded IDs in them. That's just asking for trouble.\r\n\r\nIt's Python, but I wrote [NonMockObjects](http://www.jerf.org/programming/nonMockObjects.html) basically for this same reason. (Well, actually, I just skipped over the part where I tried to hard-code my test database rows, since I lucked into a situation where once I realized I needed test data, the requisite data was already too complicated to hard code in any reasonable amount of time.) Perhaps a Ruby port would be a good idea. NonMockObjects is currently in use in a Django environment, which is very similar, so I know the idea is sound.\r\n\r\nWith a bit of library support and the right structure, I find generating test data via code to be about an order of magnitude or so easier, and I just don't get everyone's apparent obsession with test fixtures which, being static data and not code, are not particularly amenable to refactoring, abstraction, or any of the other advantages of living code over dead data.","timestamp":"2007-02-28T05:05:35+00:00","score":3},{"role":"OP","user_id":"anon_9becfdbd6554b5e0","comment_id":"c175xz","kind":"comment","text":"Thanks for the input jerf.","timestamp":"2007-03-01T05:26:47+00:00","score":1},{"role":"answerer","user_id":"anon_d13585895a3e0bd6","comment_id":"c1796p","kind":"comment","text":"Less extreme than porting code from another language, you ought to be able to get somewhere with using Ruby symbols for IDs, then allowing the fixture framework to convert that to IDs for you. Then the IDs are still symbolic and can get moved around and such, but you can still use what fixtures you have with minimal changes.\r\n\r\nI have no idea who you'd suggest that to, but I'd consider it a vital fixtures feature. (You'll also need some way of requesting objects by the symbolic ID used this run.)","timestamp":"2007-03-01T19:14:09+00:00","score":2}],"n_turns":4,"n_turns_after_thanks":1,"op_metadata":{"user_id":"anon_9becfdbd6554b5e0","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_d13585895a3e0bd6","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c16z51","thanks_reply_id":"c175xz","post_score":5,"answer_score":3,"preferred_answer_is_top_level":true}}
{"user_id":"anon_94265549b21d00f4","answerer_user_id":"anon_d649eeb147a27ba2","subreddit":"programming","timestamp":"2007-03-14T14:57:19+00:00","post_id":"1a73t","question":"FINE: I will look at LISP. Where do I start?","preferred_answer":"Probably will be recommended by 50 trillion people after me, but Practical Common Lisp is a nice book. Look on the author's page and download a Lispbox for Windows.\r\n\r\nEdit: Should mention that today the two most-used dialects of Lisp are Common Lisp and Scheme. In my opinion, Common Lisp is more \"practical\", but Scheme is prettier. If you do want to broaden your mind about programming rather than just \"learn another language\", then I recommend SICP (Structure and Interpretation of Computer Programs). Be warned though - it does require patience (probably wouldn't be worth much if it didn't).","full_conversation":[{"role":"OP","user_id":"anon_94265549b21d00f4","comment_id":"1a73t","kind":"post","text":"FINE: I will look at LISP. Where do I start?","timestamp":"2007-03-14T14:57:19+00:00","score":163},{"role":"answerer","user_id":"anon_d649eeb147a27ba2","comment_id":"c1a76x","kind":"comment","text":"Probably will be recommended by 50 trillion people after me, but Practical Common Lisp is a nice book. Look on the author's page and download a Lispbox for Windows.\r\n\r\nEdit: Should mention that today the two most-used dialects of Lisp are Common Lisp and Scheme. In my opinion, Common Lisp is more \"practical\", but Scheme is prettier. If you do want to broaden your mind about programming rather than just \"learn another language\", then I recommend SICP (Structure and Interpretation of Computer Programs). Be warned though - it does require patience (probably wouldn't be worth much if it didn't).","timestamp":"2007-03-14T15:09:30+00:00","score":15},{"role":"OP","user_id":"anon_94265549b21d00f4","comment_id":"c1a780","kind":"comment","text":"Done and done. Thanks!\r\n\r\nLookee here: The text of said book\r\nhttp://www.gigamonkeys.com/book/\r\n\r\nAnd here is the download of Lispbox from the same site\r\nhttp://www.gigamonkeys.com/book/lispbox/","timestamp":"2007-03-14T15:13:06+00:00","score":11},{"role":"answerer","user_id":"anon_d649eeb147a27ba2","comment_id":"c1a7aj","kind":"comment","text":"Yep, I was too lazy to post those links and decided to rely on you googling for them :)","timestamp":"2007-03-14T15:20:29+00:00","score":2}],"n_turns":4,"n_turns_after_thanks":1,"op_metadata":{"user_id":"anon_94265549b21d00f4","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_d649eeb147a27ba2","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c1a76x","thanks_reply_id":"c1a780","post_score":163,"answer_score":15,"preferred_answer_is_top_level":true}}
{"user_id":"anon_ffc0e4863259c323","answerer_user_id":"anon_fe2a03b6fcb7a669","subreddit":"programming","timestamp":"2007-03-15T23:21:56+00:00","post_id":"1akns","question":"Can Operating Systems tell if they're running in a Virtual Machine?","preferred_answer":"This guy is running about 8-10 months behind the times. Most notably, a few weeks ago Peter Ferrie at Symantec and our team at Matasano published \r\n[several techniques for detecting virtualization][1], including \"hardware-virtualized\" rootkits --- Joanna's BluePill (AMD) and our Vitriol (Intel). \r\n\r\nThere's a \"debate\" about whether hypervisor detection will remain feasible in the long term (assuming it continues to rely on VT/SVM extensions). What we know now is:\r\n\r\n- You can definitely tell if you're software/DBT virtualized (a la VMWare), and likely always will be able to.\r\n\r\n- You can currently tell if you're hardware virtualized via VT/SVM.\r\n\r\n- There are a lot of ways to tell if you're hardware virtualized, many of them hard to defeat.\r\n\r\n- Most of them are way, way easier if you're in ring 0, like the Vista kernel is, and most of them take near-negligable CPU time.\r\n\r\n- But who knows what else Joanna will come up with; this is cat-and-mouse stuff.\r\n\r\nNits: nobody cares about SubVirt (it's very noisy), \"inferred\" fingerprinting doesn't rely on instructions the VMM doesn't know how to emulate (you can, for instance, defeat a virtualized TSC counter), there is no evidence Joanna's \"RedPill\" exists, the IDTR is now virtualized, and, come on, there are like 4889438 clocks inside of a modern PC, and they all have to agree with each other to hide a hypervisor; you don't need wristwatches to time Blue Pill.\r\n\r\n[1]: http://www.matasano.com/log/680/detecting-virtualized-rootkits/","full_conversation":[{"role":"OP","user_id":"anon_ffc0e4863259c323","comment_id":"1akns","kind":"post","text":"Can Operating Systems tell if they're running in a Virtual Machine?","timestamp":"2007-03-15T23:21:56+00:00","score":185},{"role":"answerer","user_id":"anon_fe2a03b6fcb7a669","comment_id":"c1ami4","kind":"comment","text":"This guy is running about 8-10 months behind the times. Most notably, a few weeks ago Peter Ferrie at Symantec and our team at Matasano published \r\n[several techniques for detecting virtualization][1], including \"hardware-virtualized\" rootkits --- Joanna's BluePill (AMD) and our Vitriol (Intel). \r\n\r\nThere's a \"debate\" about whether hypervisor detection will remain feasible in the long term (assuming it continues to rely on VT/SVM extensions). What we know now is:\r\n\r\n- You can definitely tell if you're software/DBT virtualized (a la VMWare), and likely always will be able to.\r\n\r\n- You can currently tell if you're hardware virtualized via VT/SVM.\r\n\r\n- There are a lot of ways to tell if you're hardware virtualized, many of them hard to defeat.\r\n\r\n- Most of them are way, way easier if you're in ring 0, like the Vista kernel is, and most of them take near-negligable CPU time.\r\n\r\n- But who knows what else Joanna will come up with; this is cat-and-mouse stuff.\r\n\r\nNits: nobody cares about SubVirt (it's very noisy), \"inferred\" fingerprinting doesn't rely on instructions the VMM doesn't know how to emulate (you can, for instance, defeat a virtualized TSC counter), there is no evidence Joanna's \"RedPill\" exists, the IDTR is now virtualized, and, come on, there are like 4889438 clocks inside of a modern PC, and they all have to agree with each other to hide a hypervisor; you don't need wristwatches to time Blue Pill.\r\n\r\n[1]: http://www.matasano.com/log/680/detecting-virtualized-rootkits/","timestamp":"2007-03-16T04:40:18+00:00","score":30},{"role":"OP","user_id":"anon_ffc0e4863259c323","comment_id":"c1amnp","kind":"comment","text":"Thanks for taking the time to respond!\r\n\r\nI wrote that back in October, so it wasn't quite as behind the times back then. Would you care to comment on the blog post and possibly expand further on the nits?","timestamp":"2007-03-16T05:14:04+00:00","score":10},{"role":"answerer","user_id":"anon_fe2a03b6fcb7a669","comment_id":"c1amof","kind":"comment","text":"Wow, I'm sorry. I downvoted my own comment. =)","timestamp":"2007-03-16T05:17:16+00:00","score":0},{"role":"OP","user_id":"anon_ffc0e4863259c323","comment_id":"c1ams0","kind":"comment","text":"Well, I voted you back up! Thanks for your very insightful comment on the post.","timestamp":"2007-03-16T05:36:34+00:00","score":5}],"n_turns":5,"n_turns_after_thanks":2,"op_metadata":{"user_id":"anon_ffc0e4863259c323","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_fe2a03b6fcb7a669","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c1ami4","thanks_reply_id":"c1amnp","post_score":185,"answer_score":30,"preferred_answer_is_top_level":true}}
{"user_id":"anon_ee9ff70126257336","answerer_user_id":"anon_bf60e431d9e8c752","subreddit":"programming","timestamp":"2007-07-31T03:52:10+00:00","post_id":"2awjt","question":"Ask Reddit: how do I digitize all my paper?","preferred_answer":"Well, I don't know about doing it all by yourself. I have digitalized some books I own using djvulibre and unpaper (djvulibre produces the DJVU format, and unpaper corrects the problems and cleans the scans). If you can get a service to digitize your stuff, then it's trivial to generate ebooks.\r\n\r\nhttp://djvu.sourceforge.net/\r\nhttp://unpaper.berlios.de/\r\nhttp://www.djvu.org/\r\n\r\nThe djvu.org has a service for you to submit stuff and they generate the djvu files.\r\n\r\nThe DJVU format achieves very high compression. Apparently, it uses wavelets technology. State-of-the-art, they say.\r\n\r\nBt the way, the original implementation used LUSH, a Lisp-based language and environment for number-crunching tasks.","full_conversation":[{"role":"OP","user_id":"anon_ee9ff70126257336","comment_id":"2awjt","kind":"post","text":"Ask Reddit: how do I digitize all my paper?","timestamp":"2007-07-31T03:52:10+00:00","score":0},{"role":"answerer","user_id":"anon_bf60e431d9e8c752","comment_id":"c2awnw","kind":"comment","text":"Well, I don't know about doing it all by yourself. I have digitalized some books I own using djvulibre and unpaper (djvulibre produces the DJVU format, and unpaper corrects the problems and cleans the scans). If you can get a service to digitize your stuff, then it's trivial to generate ebooks.\r\n\r\nhttp://djvu.sourceforge.net/\r\nhttp://unpaper.berlios.de/\r\nhttp://www.djvu.org/\r\n\r\nThe djvu.org has a service for you to submit stuff and they generate the djvu files.\r\n\r\nThe DJVU format achieves very high compression. Apparently, it uses wavelets technology. State-of-the-art, they say.\r\n\r\nBt the way, the original implementation used LUSH, a Lisp-based language and environment for number-crunching tasks.","timestamp":"2007-07-31T04:08:54+00:00","score":3},{"role":"OP","user_id":"anon_ee9ff70126257336","comment_id":"c2awry","kind":"comment","text":"Thanks, since it's lisp I guess I'll have to use it:)\r\n\r\nFound a good google answer too:\r\nhttp://answers.google.com/answers/threadview?id=365069","timestamp":"2007-07-31T04:28:13+00:00","score":2},{"role":"answerer","user_id":"anon_bf60e431d9e8c752","comment_id":"c2b4sy","kind":"comment","text":"The *original* implementation used LUSH. But LUSH kinda sucks (dynamic scoping all over). It was only used for prototyping, since LUSH performs fast numerical computations (that's what it's made for) and it's a lisp.\r\n\r\nIt was developed under AT & T and the released as open source.\r\n\r\nThe current implementation is written in C, IIRC. For speed and portability, I guess.","timestamp":"2007-07-31T20:04:56+00:00","score":0}],"n_turns":4,"n_turns_after_thanks":1,"op_metadata":{"user_id":"anon_ee9ff70126257336","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_bf60e431d9e8c752","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c2awnw","thanks_reply_id":"c2awry","post_score":0,"answer_score":3,"preferred_answer_is_top_level":false}}
{"user_id":"anon_90b9415ab4c43cea","answerer_user_id":"anon_c0c5a200d38e99fc","subreddit":"programming","timestamp":"2007-08-23T14:38:58+00:00","post_id":"2hyp2","question":"Why do so many database programmers think that a primary key = a single autogenerated column?","preferred_answer":"Uniqueness of primary keys is not the only requirement.\r\n\r\nSurrogate keys never change. So the link once established is solid. You never think about it, never have any headache maintaining it.\r\n\r\nIf you use data fields for primary keys, data may change in a future. And then you have to chase that key in every child table and update it accordingly.\r\n\r\nToo much trouble for nothing.","full_conversation":[{"role":"OP","user_id":"anon_90b9415ab4c43cea","comment_id":"2hyp2","kind":"post","text":"Why do so many database programmers think that a primary key = a single autogenerated column?","timestamp":"2007-08-23T14:38:58+00:00","score":83},{"role":"answerer","user_id":"anon_c0c5a200d38e99fc","comment_id":"c2i080","kind":"comment","text":"Uniqueness of primary keys is not the only requirement.\r\n\r\nSurrogate keys never change. So the link once established is solid. You never think about it, never have any headache maintaining it.\r\n\r\nIf you use data fields for primary keys, data may change in a future. And then you have to chase that key in every child table and update it accordingly.\r\n\r\nToo much trouble for nothing.","timestamp":"2007-08-23T16:34:26+00:00","score":6},{"role":"OP","user_id":"anon_90b9415ab4c43cea","comment_id":"c2i08y","kind":"comment","text":"vagif -- I appreciate what you are saying, but I recommend perhaps reading the article.","timestamp":"2007-08-23T16:36:52+00:00","score":4},{"role":"answerer","user_id":"anon_c0c5a200d38e99fc","comment_id":"c2i0tt","kind":"comment","text":"Yes, you are right. Of course you can stack together surrogate keys (surrogate only!) to create another perfectly surrogate key. \r\n\r\nBut what you are forgetting is that chasing that small simplification (removing 1 field and 1 more unique index constraint) you are introducing much more complexity somewhere else.\r\n\r\nHow many times you need to create a table ? 1 time only.\r\n\r\nHow many times you need to query it ? Many times in many different places in your code.\r\n\r\nSo tell me which is simpler ?\r\n\r\n select bla bla \r\n from a inner join b on a.blablaid = b.blablaid \r\n and a.anotherblaid = b.anotherblaid\r\n\r\nor\r\n\r\n select bla bla \r\n from a inner join b on a.blablaid = b.blablaid \r\n\r\nBtw same goes for all other operations:\r\n\r\n update a ... where a.blablaid = 111 and a.anotherblaid = 222\r\n\r\nversus \r\n\r\n update a ... where a.blablaid = 111\r\n\r\n\r\nI do not mind such a small overhead and ambiguity in a table definition if it allows me to conveniently describe joins in a consistent manner everywhere in my code.","timestamp":"2007-08-23T17:23:54+00:00","score":2}],"n_turns":4,"n_turns_after_thanks":1,"op_metadata":{"user_id":"anon_90b9415ab4c43cea","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_c0c5a200d38e99fc","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c2i080","thanks_reply_id":"c2i08y","post_score":83,"answer_score":6,"preferred_answer_is_top_level":true}}
{"user_id":"anon_624c930b4b8c6e24","answerer_user_id":"anon_84c845b2bfa8f3f8","subreddit":"programming","timestamp":"2007-08-29T09:34:24+00:00","post_id":"2jpxj","question":"Do you occasionally program in Bash? Read this thoroughly, you will save a lot of time.","preferred_answer":"I've never used wait before, but is it roughly equivalent to:\r\n\r\n from subprocess import call\r\n from threading import Thread\r\n import sys\r\n\r\n procs = []\r\n for i, arg in enumerate(sys.argv):\r\n cmd = \"echo hello %s\" % i\r\n t = Thread(target=lambda: call(cmd))\r\n t.start()\r\n procs.append(t)\r\n\r\n for p in procs:\r\n p.join()\r\n\r\n print \"do something else\"\r\n\r\n\r\n?","full_conversation":[{"role":"OP","user_id":"anon_624c930b4b8c6e24","comment_id":"2jpxj","kind":"post","text":"Do you occasionally program in Bash? Read this thoroughly, you will save a lot of time.","timestamp":"2007-08-29T09:34:24+00:00","score":75},{"role":"answerer","user_id":"anon_84c845b2bfa8f3f8","comment_id":"c2js0g","kind":"comment","text":"I've never used wait before, but is it roughly equivalent to:\r\n\r\n from subprocess import call\r\n from threading import Thread\r\n import sys\r\n\r\n procs = []\r\n for i, arg in enumerate(sys.argv):\r\n cmd = \"echo hello %s\" % i\r\n t = Thread(target=lambda: call(cmd))\r\n t.start()\r\n procs.append(t)\r\n\r\n for p in procs:\r\n p.join()\r\n\r\n print \"do something else\"\r\n\r\n\r\n?","timestamp":"2007-08-29T13:52:36+00:00","score":6},{"role":"OP","user_id":"anon_624c930b4b8c6e24","comment_id":"c2jsx3","kind":"comment","text":"The bash version feels really natural and doesn't depend on any external code. This is exactly my point : typical shell activities are a lot more natural in bash than in python. Of course you wouldn't want to use bash for more general programming activities. (although you can, of course!)","timestamp":"2007-08-29T15:11:59+00:00","score":10},{"role":"answerer","user_id":"anon_84c845b2bfa8f3f8","comment_id":"c2jsz4","kind":"comment","text":"> The bash version feels really natural \r\n\r\nThe python version feels more natural to me, but that could just be bias. I've never learned more bash than absolutely required because its gotchas are horrifying IMHO.\r\n\r\n> and doesn't depend on any external code\r\n\r\nNeither does the python version - it's all in the standard library. Unless you count that as \"external code\"?\r\n\r\nPlus, if the script grows (as they are wont to do) into something more substantial, you're already in a general programming language.","timestamp":"2007-08-29T15:15:44+00:00","score":7},{"role":"OP","user_id":"anon_624c930b4b8c6e24","comment_id":"c2jt12","kind":"comment","text":"Fair points, but do you really use python for *everything*? I'm a heavy python user, but for looking through a bunch of files, I find the combination of bash with applications such as grep, sed, xargs, find, etc. really useful. I really don't see how I could do this stuff easily with python.","timestamp":"2007-08-29T15:19:30+00:00","score":5},{"role":"answerer","user_id":"anon_84c845b2bfa8f3f8","comment_id":"c2jt7k","kind":"comment","text":"Sometimes that stuff is really handy, and I marshal it in and out of python as necessary. When you set shell=True in subprocess.Popen, you can run arbitrary shell commands and use all the >s, bars, and ampersands you would from the command line.\r\n\r\nThere's some good examples [here](http://www.oreillynet.com/onlamp/blog/2007/08/pymotw_subprocess_1.html).","timestamp":"2007-08-29T15:34:31+00:00","score":8}],"n_turns":6,"n_turns_after_thanks":3,"op_metadata":{"user_id":"anon_624c930b4b8c6e24","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_84c845b2bfa8f3f8","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c2js0g","thanks_reply_id":"c2jsx3","post_score":75,"answer_score":6,"preferred_answer_is_top_level":false}}
{"user_id":"anon_ca90f34f3a1bde62","answerer_user_id":"anon_ce9662c3a8d363dd","subreddit":"programming","timestamp":"2007-08-30T05:43:45+00:00","post_id":"2k1q7","question":"ask reddit: What school teaches computer science *right*?","preferred_answer":"I think the most important thing is not to expect your school to give all ability/knowledge you need. Do study on your own -- that will develop something that is really valuable -- initiative. Java/C++/C#/TheNewCoolLanguage are only tools.\r\n\r\nTry to learn (on your own) as many different \"things\" as you can, and also as deeply as you can. Of course, you can't learn everything about computers. But you can take 2 or 3 areas and dive deeply, while reading about everything else.\r\n\r\nThis is what I would do if I were in your position:\r\n\r\n- Programming paradigms: funcional (Haskell/Scheme/Erlang/OCaml/etc), OO (Java/Smalltalk/C++/Ruby/etc), generative (Q), low-level (C), Logic (Prolog), maybe Forth;\r\n- Compiler and interpreter construction: Get \"Lisp in Small Pieces\" and other books on how to implement languages and write some little language of yours. Not in a weekend, but maybe over 3 or 4 years;\r\n- Always mix theory and practice as much as possible. Compiler course? Write a compiler. Optimization course? Solve a real-world problem with what you've learned. Programming course? Don't do only small examples, write large programs;\r\n- Try to seriously understand what you see in CS undergrad and grad courses, even if your CS school doesn't give you the opportunity: distributed computing, computational biology, computer graphics, AI, computer architecture, etc;\r\n- Theoretical CS: algorithm complexity, combinatorial optimization, cryptography, theory of Quantum computing, lots of math;\r\n- More \"human\" stuff: read something about human-computer interaction and a bit of psychology. May sound silly, but think what will happen when you, knowing lots of math and programming AND humanities, is compared to lots of people you see out there, who don't do both;\r\n- Also, do learn arts. Music, painting, drama, doesn't matter what. The more you expand the ways you use your brain, the better you'll be in everything you do;\r\n- And do sports. Really, it makes a huge difference. You become more efficient, get sick less often... You know what I mean. Bike, indoor climbing, jogging, martial arts -- there are so many cool options!\r\n- Develop discipline. Really, you can boost your productivity by getting used to plan your days and stick to what you're doing without wandering aroung (reddit, slashdot, chat, coffee, look at the wall, play some game, ...). Not that these things are \"bad\", but you should have some control over how much time and energy they take from you.","full_conversation":[{"role":"OP","user_id":"anon_ca90f34f3a1bde62","comment_id":"2k1q7","kind":"post","text":"ask reddit: What school teaches computer science *right*?","timestamp":"2007-08-30T05:43:45+00:00","score":32},{"role":"answerer","user_id":"anon_ce9662c3a8d363dd","comment_id":"c2k32s","kind":"comment","text":"I think the most important thing is not to expect your school to give all ability/knowledge you need. Do study on your own -- that will develop something that is really valuable -- initiative. Java/C++/C#/TheNewCoolLanguage are only tools.\r\n\r\nTry to learn (on your own) as many different \"things\" as you can, and also as deeply as you can. Of course, you can't learn everything about computers. But you can take 2 or 3 areas and dive deeply, while reading about everything else.\r\n\r\nThis is what I would do if I were in your position:\r\n\r\n- Programming paradigms: funcional (Haskell/Scheme/Erlang/OCaml/etc), OO (Java/Smalltalk/C++/Ruby/etc), generative (Q), low-level (C), Logic (Prolog), maybe Forth;\r\n- Compiler and interpreter construction: Get \"Lisp in Small Pieces\" and other books on how to implement languages and write some little language of yours. Not in a weekend, but maybe over 3 or 4 years;\r\n- Always mix theory and practice as much as possible. Compiler course? Write a compiler. Optimization course? Solve a real-world problem with what you've learned. Programming course? Don't do only small examples, write large programs;\r\n- Try to seriously understand what you see in CS undergrad and grad courses, even if your CS school doesn't give you the opportunity: distributed computing, computational biology, computer graphics, AI, computer architecture, etc;\r\n- Theoretical CS: algorithm complexity, combinatorial optimization, cryptography, theory of Quantum computing, lots of math;\r\n- More \"human\" stuff: read something about human-computer interaction and a bit of psychology. May sound silly, but think what will happen when you, knowing lots of math and programming AND humanities, is compared to lots of people you see out there, who don't do both;\r\n- Also, do learn arts. Music, painting, drama, doesn't matter what. The more you expand the ways you use your brain, the better you'll be in everything you do;\r\n- And do sports. Really, it makes a huge difference. You become more efficient, get sick less often... You know what I mean. Bike, indoor climbing, jogging, martial arts -- there are so many cool options!\r\n- Develop discipline. Really, you can boost your productivity by getting used to plan your days and stick to what you're doing without wandering aroung (reddit, slashdot, chat, coffee, look at the wall, play some game, ...). Not that these things are \"bad\", but you should have some control over how much time and energy they take from you.","timestamp":"2007-08-30T09:43:00+00:00","score":30},{"role":"OP","user_id":"anon_ca90f34f3a1bde62","comment_id":"c2k6bd","kind":"comment","text":"I appreciate your reply a lot. But one questions jumps at me: How do I have time to learn all those things when I'm busy at school not expecting to learn all those things? \r\n\r\nI understand your point that I play the biggest part in my own learning, but if I'm doing most of the learning on my own, what's the point of school?","timestamp":"2007-08-30T15:38:48+00:00","score":2},{"role":"answerer","user_id":"anon_ce9662c3a8d363dd","comment_id":"c2k6r2","kind":"comment","text":"Well, I'm not saying schools are useless. You will learn a lot from your school, and the better your school is, the more you learn. What I meant is that you should also study on your own (always have a pet project!)\r\nAt school, you will learn lots of math that would be harder to learn alone (Calculus, Linear Algebra, Statistics...), and you may get involved in some cool project at the school lab (robots, experimental systems, and lots of other interesting things). And you will \"learn to learn quickly\" (because you will have lots of deadlines). That's one great ability.\r\n\r\nEven at school, you should learn to anticipate what will be required from you and learn in advance... Also, see what they didn't teach you and complement your studies in your free time.\r\n\r\nYou will also quickly realize what are your good teachers, and they will help you with good feedback when you ask questions or opinions. By the way, teachers that make you think and find out things by yourself are the best!\r\n\r\nBesides all of this (and some people will kill me or saying this), a degree may get you some credibility (but that depends a lot on who you're talking to)...","timestamp":"2007-08-30T16:13:53+00:00","score":2}],"n_turns":4,"n_turns_after_thanks":1,"op_metadata":{"user_id":"anon_ca90f34f3a1bde62","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_ce9662c3a8d363dd","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c2k32s","thanks_reply_id":"c2k6bd","post_score":32,"answer_score":30,"preferred_answer_is_top_level":true}}
{"user_id":"anon_2329820dac83fbbe","answerer_user_id":"anon_9f942e2ba086e8fd","subreddit":"programming","timestamp":"2007-09-04T20:28:19+00:00","post_id":"2lrqa","question":"My startup. Comments?","preferred_answer":"Ok.. tried to join just for giggles. Using Firefox (Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.8.1.6) Gecko/20070725 Firefox/2.0.0.6) with AdBlock Plus (though I don't know if that matters in this case). Filled out form, clicked 'Join', and keep getting 'Please tells us where you heard about Scriggle-it\" even though I have 'reddit' in the 'Where did you hear about Scriggle-it?' input control. \r\n\r\nNeeds work. Cool look and feel though FWIW.","full_conversation":[{"role":"OP","user_id":"anon_2329820dac83fbbe","comment_id":"2lrqa","kind":"post","text":"My startup. Comments?","timestamp":"2007-09-04T20:28:19+00:00","score":0},{"role":"answerer","user_id":"anon_9f942e2ba086e8fd","comment_id":"c2lryy","kind":"comment","text":"Ok.. tried to join just for giggles. Using Firefox (Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.8.1.6) Gecko/20070725 Firefox/2.0.0.6) with AdBlock Plus (though I don't know if that matters in this case). Filled out form, clicked 'Join', and keep getting 'Please tells us where you heard about Scriggle-it\" even though I have 'reddit' in the 'Where did you hear about Scriggle-it?' input control. \r\n\r\nNeeds work. Cool look and feel though FWIW.","timestamp":"2007-09-04T20:51:27+00:00","score":2},{"role":"OP","user_id":"anon_2329820dac83fbbe","comment_id":"c2lrze","kind":"comment","text":"Ooh. Eek. Thanks. I'll have that fixed at once.\r\n\r\nEdit: And fixed. Funny how I make the stupidest Javascript logic errors when I'm working fast.","timestamp":"2007-09-04T20:51:57+00:00","score":2},{"role":"answerer","user_id":"anon_9f942e2ba086e8fd","comment_id":"c2ls0r","kind":"comment","text":"Since we're such good (free) testers, you mind sharing some details about your platform, tools, language(s), etc? Not trying to snipe your secret sauce, just curious.","timestamp":"2007-09-04T20:54:28+00:00","score":1},{"role":"OP","user_id":"anon_2329820dac83fbbe","comment_id":"c2ls23","kind":"comment","text":"You *are* good free testers. And I'm indebted to you. So, it's built on FreeBSD and Ruby on Rails and MySQL and Mongrel and Apache (front-end with mod-proxy-balancer) and Postfix and plenty of custom straight-up Ruby scripts.","timestamp":"2007-09-04T20:57:58+00:00","score":2},{"role":"answerer","user_id":"anon_9f942e2ba086e8fd","comment_id":"c2lsjw","kind":"comment","text":"A couple^H^H^H^H^H^Hbuncha notes:\r\n\r\n- Don't make me choose time zone if I feed you a valid Zip + State. Or only ask for time zone and not all 3.\r\n\r\n- Your captcha is giving me the same value it gave me earlier. It's fake isn't it? :)\r\n\r\n- You're requiring my phone number and email address. Do you really want a fake phone number?\r\n\r\n- Validation error on the missing elements above caused me to appear to lose my choice on the option box concerning 'did I hear about it from a current user'. Sure enough, that caused another validation error. \r\n\r\n- Email address validation is not occurring correctly. I was able to enter 'ADSF@asdf@asdf@.com' in the management information email field. (Yeah, I'm a bastard. :)\r\n\r\nLet me know when you're ready for me to break the fan data import. ;)","timestamp":"2007-09-04T21:44:49+00:00","score":1},{"role":"OP","user_id":"anon_2329820dac83fbbe","comment_id":"c2lsor","kind":"comment","text":"Nope, not a fake captcha. It's session-based, and obviously I'm not clearing/updating it when I should. Thanks for the feedback -- this is the kind of close scrutiny I was looking for.","timestamp":"2007-09-04T22:02:05+00:00","score":1},{"role":"answerer","user_id":"anon_9f942e2ba086e8fd","comment_id":"c2lspo","kind":"comment","text":"Hmm.. well I've had this instance of Firefox open all day, so you probably just need to expire your sessions periodically (or not; expired sessions can mean frustrated users).","timestamp":"2007-09-04T22:04:43+00:00","score":1},{"role":"OP","user_id":"anon_2329820dac83fbbe","comment_id":"c2lsri","kind":"comment","text":"I think what I need to do is generate a new captcha upon each signup form request. That would solve the problem.","timestamp":"2007-09-04T22:09:16+00:00","score":1},{"role":"answerer","user_id":"anon_9f942e2ba086e8fd","comment_id":"c2lt64","kind":"comment","text":"That's probably going to be safer against spam bots anyway. Otherwise someone could get a session going, get the captcha, then start a script with that as a parameter. Better to make 'em work at it.","timestamp":"2007-09-04T22:51:53+00:00","score":1}],"n_turns":10,"n_turns_after_thanks":7,"op_metadata":{"user_id":"anon_2329820dac83fbbe","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_9f942e2ba086e8fd","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c2lryy","thanks_reply_id":"c2lrze","post_score":0,"answer_score":2,"preferred_answer_is_top_level":false}}
{"user_id":"anon_c7075dee92023bc5","answerer_user_id":"anon_4e4b2e4726b04782","subreddit":"programming","timestamp":"2007-11-05T13:26:38+00:00","post_id":"5zux5","question":"Ask Reddit: Have you written any apps for your personal use on your mobile phone? If so, what have you written and how?","preferred_answer":"[Enjoy!](http://wiki.forum.nokia.com/index.php/Category:Code_Examples) All you need is a text editor and a memory card, [Installation Instructions](http://wiki.opensource.nokia.com/projects/Installing_PyS60) just in case something's unclear.","full_conversation":[{"role":"OP","user_id":"anon_c7075dee92023bc5","comment_id":"5zux5","kind":"post","text":"Ask Reddit: Have you written any apps for your personal use on your mobile phone? If so, what have you written and how?","timestamp":"2007-11-05T13:26:38+00:00","score":41},{"role":"answerer","user_id":"anon_4e4b2e4726b04782","comment_id":"c02dpm2","kind":"comment","text":"[Enjoy!](http://wiki.forum.nokia.com/index.php/Category:Code_Examples) All you need is a text editor and a memory card, [Installation Instructions](http://wiki.opensource.nokia.com/projects/Installing_PyS60) just in case something's unclear.","timestamp":"2007-11-05T14:35:24+00:00","score":10},{"role":"OP","user_id":"anon_c7075dee92023bc5","comment_id":"c02dpmy","kind":"comment","text":"Thank you. I'd never seen that resource before.","timestamp":"2007-11-05T14:40:12+00:00","score":3},{"role":"answerer","user_id":"anon_4e4b2e4726b04782","comment_id":"c02dpp1","kind":"comment","text":"Happy to help.","timestamp":"2007-11-05T14:48:13+00:00","score":5}],"n_turns":4,"n_turns_after_thanks":1,"op_metadata":{"user_id":"anon_c7075dee92023bc5","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_4e4b2e4726b04782","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c02dpm2","thanks_reply_id":"c02dpmy","post_score":41,"answer_score":10,"preferred_answer_is_top_level":false}}
{"user_id":"anon_a7a60ab44fd79a4a","answerer_user_id":"anon_c0c5a200d38e99fc","subreddit":"programming","timestamp":"2007-12-31T20:55:50+00:00","post_id":"648e7","question":"Yes, I have Vista. Guess what? I hate it. (Surprise) How do I switch to Linux?","preferred_answer":"1. Install Ubuntu.\n2. Call HP for a windows refund.","full_conversation":[{"role":"OP","user_id":"anon_a7a60ab44fd79a4a","comment_id":"648e7","kind":"post","text":"Yes, I have Vista. Guess what? I hate it. (Surprise) How do I switch to Linux?","timestamp":"2007-12-31T20:55:50+00:00","score":0},{"role":"answerer","user_id":"anon_c0c5a200d38e99fc","comment_id":"c02s8hk","kind":"comment","text":"1. Install Ubuntu.\n2. Call HP for a windows refund.","timestamp":"2007-12-31T20:59:48+00:00","score":10},{"role":"OP","user_id":"anon_a7a60ab44fd79a4a","comment_id":"c02s8jg","kind":"comment","text":"Ha, thanks. I have 2.5gb RAM, and vista runs slower than shit. Will it be even slower if I dual-boot?\n\nEdit: Can I seriously get a refund, or was that tongue-in-cheek?","timestamp":"2007-12-31T21:06:56+00:00","score":3},{"role":"answerer","user_id":"anon_c0c5a200d38e99fc","comment_id":"c02s8sj","kind":"comment","text":"I ordered my dell Inspiron 1520 laptop a week ago. Yesterday i called dell support and asked for windows refund, since i'm going to install linux on it. Like you I thought it would be impossible and i will waste a few hours and end up with nothing.\n\nTo my big surprise, in less than 5 minutes of talk, they agreed to refund me $50 for windows.\n\nAnd by the way, I got my laptop just a few minutes ago. Happy new Year!! :)","timestamp":"2007-12-31T21:39:22+00:00","score":2},{"role":"OP","user_id":"anon_a7a60ab44fd79a4a","comment_id":"c02s9lg","kind":"comment","text":"Mine was purchased through BestBuy as a gift from my SO 6 months back. I'll see what I can do, thanks again.","timestamp":"2007-12-31T23:36:22+00:00","score":1},{"role":"answerer","user_id":"anon_c0c5a200d38e99fc","comment_id":"c02sc7v","kind":"comment","text":"That would not work. It has to be new, and you cannot run it, otherwise you agreed on license.","timestamp":"2008-01-01T08:05:09+00:00","score":1}],"n_turns":6,"n_turns_after_thanks":3,"op_metadata":{"user_id":"anon_a7a60ab44fd79a4a","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_c0c5a200d38e99fc","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c02s8hk","thanks_reply_id":"c02s8jg","post_score":0,"answer_score":10,"preferred_answer_is_top_level":false}}
{"user_id":"anon_1a09e9adbe9f1f3f","answerer_user_id":"anon_fa8852efd8bd996d","subreddit":"programming","timestamp":"2008-02-09T17:02:32+00:00","post_id":"68755","question":"What programming language would you teach your children?","preferred_answer":"Yep, ignore rails (for now at least).\n\nThere's a good [tutorial](http://pine.fm/LearnToProgram/) for beginners. Most of it's online, and there is an expanded [book/pdf](http://www.pragprog.com/titles/fr_ltp) version.\n\nThere's also a very cool [interactive tutorial](http://tryruby.hobix.com/), that let's you get a sense of it fairly quickly (just type 'help' to get started).\n\nIt can't be too tough for you old folks to learn, I started with it about three years ago, when I was 40 ;)","full_conversation":[{"role":"OP","user_id":"anon_1a09e9adbe9f1f3f","comment_id":"68755","kind":"post","text":"What programming language would you teach your children?","timestamp":"2008-02-09T17:02:32+00:00","score":33},{"role":"answerer","user_id":"anon_fa8852efd8bd996d","comment_id":"c034x82","kind":"comment","text":"Yep, ignore rails (for now at least).\n\nThere's a good [tutorial](http://pine.fm/LearnToProgram/) for beginners. Most of it's online, and there is an expanded [book/pdf](http://www.pragprog.com/titles/fr_ltp) version.\n\nThere's also a very cool [interactive tutorial](http://tryruby.hobix.com/), that let's you get a sense of it fairly quickly (just type 'help' to get started).\n\nIt can't be too tough for you old folks to learn, I started with it about three years ago, when I was 40 ;)","timestamp":"2008-02-09T17:28:42+00:00","score":3},{"role":"OP","user_id":"anon_1a09e9adbe9f1f3f","comment_id":"c034xa7","kind":"comment","text":"Thanks, I'll take a look at those links. Ruby seems to have a powerful yet sparse syntax.","timestamp":"2008-02-09T17:37:36+00:00","score":2},{"role":"answerer","user_id":"anon_fa8852efd8bd996d","comment_id":"c034xde","kind":"comment","text":"Yep, that's what I like about it. Less typing, but still fairly easy to read a month later.","timestamp":"2008-02-09T17:46:46+00:00","score":2}],"n_turns":4,"n_turns_after_thanks":1,"op_metadata":{"user_id":"anon_1a09e9adbe9f1f3f","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_fa8852efd8bd996d","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c034x82","thanks_reply_id":"c034xa7","post_score":33,"answer_score":3,"preferred_answer_is_top_level":false}}
{"user_id":"anon_c2c3e32e5bc39fb9","answerer_user_id":"anon_d7efbdf1cd5bfb46","subreddit":"programming","timestamp":"2008-02-11T23:51:07+00:00","post_id":"68f8z","question":"Help a noob: Are there any languages/setups that can provide a Linux/Windows cross platform IDE with a GUI toolkit and builder and good packaging capability?","preferred_answer":"The java platform does this. You can use whatever language you want (Java, Scala, Groovy, Clojure, JRuby, Jython), and it runs on windows and linux (and mac, and solaris). Your app can be stored in an executable jar file, which is compressed and contains all the binary code and all the other resources the app could need, AND that jar file can be cryptographically signed to prove you made it. Netbean's GUI builder and Groovy's SwingBuilder can be used to build guis (and i'm sure the eclipse RCP offers one as well).\n\nIt's kind of cool that one of the major platforms actually meets your needs, fully, in a flexible way.","full_conversation":[{"role":"OP","user_id":"anon_c2c3e32e5bc39fb9","comment_id":"68f8z","kind":"post","text":"Help a noob: Are there any languages/setups that can provide a Linux/Windows cross platform IDE with a GUI toolkit and builder and good packaging capability?","timestamp":"2008-02-11T23:51:07+00:00","score":6},{"role":"answerer","user_id":"anon_d7efbdf1cd5bfb46","comment_id":"c035nhs","kind":"comment","text":"The java platform does this. You can use whatever language you want (Java, Scala, Groovy, Clojure, JRuby, Jython), and it runs on windows and linux (and mac, and solaris). Your app can be stored in an executable jar file, which is compressed and contains all the binary code and all the other resources the app could need, AND that jar file can be cryptographically signed to prove you made it. Netbean's GUI builder and Groovy's SwingBuilder can be used to build guis (and i'm sure the eclipse RCP offers one as well).\n\nIt's kind of cool that one of the major platforms actually meets your needs, fully, in a flexible way.","timestamp":"2008-02-11T23:59:52+00:00","score":13},{"role":"OP","user_id":"anon_c2c3e32e5bc39fb9","comment_id":"c035njl","kind":"comment","text":"Thanks for replying. I hear java is pretty resource intensive, but it certainly seems to be what I asked for. I appreciate your expertise. Also, what's jython? A rewrite of python so you can use the same syntax but get java's compatibility? I presume it comes at the cost of java's resource-intensiveness?","timestamp":"2008-02-12T00:06:07+00:00","score":1},{"role":"answerer","user_id":"anon_d7efbdf1cd5bfb46","comment_id":"c035obh","kind":"comment","text":"Modern Java's not resource intensive. It'll run on machines from 10 years ago.","timestamp":"2008-02-12T01:44:39+00:00","score":10}],"n_turns":4,"n_turns_after_thanks":1,"op_metadata":{"user_id":"anon_c2c3e32e5bc39fb9","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_d7efbdf1cd5bfb46","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c035nhs","thanks_reply_id":"c035njl","post_score":6,"answer_score":13,"preferred_answer_is_top_level":true}}
{"user_id":"anon_ee9ff70126257336","answerer_user_id":"anon_d78384ab32bffd3a","subreddit":"programming","timestamp":"2008-02-15T06:17:46+00:00","post_id":"68tr9","question":"Ask Proggit: a lisp with uncar and uncdr?","preferred_answer":"Not that I've heard of, but then, I'm really only familiar with Scheme, and mainly PLT-Scheme at that.","full_conversation":[{"role":"OP","user_id":"anon_ee9ff70126257336","comment_id":"68tr9","kind":"post","text":"Ask Proggit: a lisp with uncar and uncdr?","timestamp":"2008-02-15T06:17:46+00:00","score":0},{"role":"answerer","user_id":"anon_d78384ab32bffd3a","comment_id":"c038l8a","kind":"comment","text":"Not that I've heard of, but then, I'm really only familiar with Scheme, and mainly PLT-Scheme at that.","timestamp":"2008-02-21T03:49:48+00:00","score":1},{"role":"OP","user_id":"anon_ee9ff70126257336","comment_id":"c038loj","kind":"comment","text":"Okay, well, thanks for the input.","timestamp":"2008-02-21T04:36:20+00:00","score":1},{"role":"answerer","user_id":"anon_d78384ab32bffd3a","comment_id":"c038lr1","kind":"comment","text":"np","timestamp":"2008-02-21T04:44:53+00:00","score":1},{"role":"OP","user_id":"anon_ee9ff70126257336","comment_id":"c038x8d","kind":"comment","text":"I just realized the simple description of what I'm asking for: that lisp lists be doubly linked.","timestamp":"2008-02-22T05:13:46+00:00","score":1},{"role":"answerer","user_id":"anon_d78384ab32bffd3a","comment_id":"c038xha","kind":"comment","text":"Oooh, okay. Sure, you can construct doubly linked lists.","timestamp":"2008-02-22T05:53:17+00:00","score":1},{"role":"OP","user_id":"anon_ee9ff70126257336","comment_id":"c038ys8","kind":"comment","text":"I mean the list structure that underlies the sexps in lisp. Normally it is only accessible in singly linked form, as far as I can tell. \n\nWell, I'll stop bugging you now. Just thought I would resolve the discussion.","timestamp":"2008-02-22T10:03:39+00:00","score":1}],"n_turns":7,"n_turns_after_thanks":4,"op_metadata":{"user_id":"anon_ee9ff70126257336","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_d78384ab32bffd3a","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c038l8a","thanks_reply_id":"c038loj","post_score":0,"answer_score":1,"preferred_answer_is_top_level":false}}
{"user_id":"anon_27d9ed3439ca2983","answerer_user_id":"anon_84c845b2bfa8f3f8","subreddit":"programming","timestamp":"2008-03-15T20:25:39+00:00","post_id":"6c7ln","question":"Ask reddit: Where's the reddit API? How would you write your own?","preferred_answer":"When I needed it, I hacked some python. I never cleaned the code up, but if it's interesting, here it is:\n\n import re, urllib, cPickle, os\n from time import sleep\n \n list_stories = re.compile(r'
(\\d+) comments?|>comments?').findall(text)]\n \n url = \"http://reddit.com/r/programming/new?sort=new&after=%s\"\n \n if os.path.isfile(\"stories.pkl\"):\n stories = cPickle.load(file(\"stories.pkl\"))\n seed = stories[-1][0]\n else:\n stories = []\n seed = \"t3_6914u\"\n \n class LlimllibURLopener(urllib.FancyURLopener):\n version = \"user llimllib wants statistics\" #set the user-agent string\n urllib._urlopener = LlimllibURLopener()\n \n for i in range(1000):\n print \"opening page %s\" % url % seed\n text = urllib.urlopen(url % seed).read()\n s, c, d = list_stories(text), list_comments(text), list_dates(text)\n if (len(s), len(c), len(d)) != (25,25,25):\n print \"error parsing page: %s (%d) %s (%d) %s (%d)\" % \\\n (s, len(s), c, len(c), d, len(d))\n raise\n stories.extend(zip(s,c,d))\n seed = stories[-1][0]\n print \"last story from %s\" % stories[-1][2]\n sleep(.5)\n \n cPickle.dump(stories, file(\"stories.pkl\"))\n\nThen I wrote similar code to go to each story, and count the words per comment, to see if words per comment had changed over time. (It hadn't).","full_conversation":[{"role":"OP","user_id":"anon_27d9ed3439ca2983","comment_id":"6c7ln","kind":"post","text":"Ask reddit: Where's the reddit API? How would you write your own?","timestamp":"2008-03-15T20:25:39+00:00","score":0},{"role":"answerer","user_id":"anon_84c845b2bfa8f3f8","comment_id":"c03gcvc","kind":"comment","text":"When I needed it, I hacked some python. I never cleaned the code up, but if it's interesting, here it is:\n\n import re, urllib, cPickle, os\n from time import sleep\n \n list_stories = re.compile(r'
(\\d+) comments?|>comments?').findall(text)]\n \n url = \"http://reddit.com/r/programming/new?sort=new&after=%s\"\n \n if os.path.isfile(\"stories.pkl\"):\n stories = cPickle.load(file(\"stories.pkl\"))\n seed = stories[-1][0]\n else:\n stories = []\n seed = \"t3_6914u\"\n \n class LlimllibURLopener(urllib.FancyURLopener):\n version = \"user llimllib wants statistics\" #set the user-agent string\n urllib._urlopener = LlimllibURLopener()\n \n for i in range(1000):\n print \"opening page %s\" % url % seed\n text = urllib.urlopen(url % seed).read()\n s, c, d = list_stories(text), list_comments(text), list_dates(text)\n if (len(s), len(c), len(d)) != (25,25,25):\n print \"error parsing page: %s (%d) %s (%d) %s (%d)\" % \\\n (s, len(s), c, len(c), d, len(d))\n raise\n stories.extend(zip(s,c,d))\n seed = stories[-1][0]\n print \"last story from %s\" % stories[-1][2]\n sleep(.5)\n \n cPickle.dump(stories, file(\"stories.pkl\"))\n\nThen I wrote similar code to go to each story, and count the words per comment, to see if words per comment had changed over time. (It hadn't).","timestamp":"2008-03-15T20:53:09+00:00","score":5},{"role":"OP","user_id":"anon_27d9ed3439ca2983","comment_id":"c03gk8i","kind":"comment","text":"Thanks a lot! Any license on this code?","timestamp":"2008-03-16T17:37:46+00:00","score":1},{"role":"answerer","user_id":"anon_84c845b2bfa8f3f8","comment_id":"c03gk9o","kind":"comment","text":"[WTFPL v2](http://sam.zoy.org/wtfpl/)","timestamp":"2008-03-16T17:41:16+00:00","score":2}],"n_turns":4,"n_turns_after_thanks":1,"op_metadata":{"user_id":"anon_27d9ed3439ca2983","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_84c845b2bfa8f3f8","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c03gcvc","thanks_reply_id":"c03gk8i","post_score":0,"answer_score":5,"preferred_answer_is_top_level":false}}
{"user_id":"anon_ac82c508e7b0f77a","answerer_user_id":"anon_7c506be0eeb11814","subreddit":"programming","timestamp":"2008-04-14T20:09:25+00:00","post_id":"6frbc","question":"Where should I look to find an entry level C++ job?","preferred_answer":"http://www-03.ibm.com/employment/us/fi_search.shtml\n\nFollow the link, search for entry level C++ jobs. San Jose, Austin, Cambridge, Charlotte, Raleigh, Atlanta, Beaverton, Taiwan, New Zealand, ... over 100 positions in hardware, software, and research which are classified entry level and pull up with \"C++\". Stuff like working with the Cell processor, etc.","full_conversation":[{"role":"OP","user_id":"anon_ac82c508e7b0f77a","comment_id":"6frbc","kind":"post","text":"Where should I look to find an entry level C++ job?","timestamp":"2008-04-14T20:09:25+00:00","score":6},{"role":"answerer","user_id":"anon_7c506be0eeb11814","comment_id":"c03q3q7","kind":"comment","text":"http://www-03.ibm.com/employment/us/fi_search.shtml\n\nFollow the link, search for entry level C++ jobs. San Jose, Austin, Cambridge, Charlotte, Raleigh, Atlanta, Beaverton, Taiwan, New Zealand, ... over 100 positions in hardware, software, and research which are classified entry level and pull up with \"C++\". Stuff like working with the Cell processor, etc.","timestamp":"2008-04-15T14:14:25+00:00","score":2},{"role":"OP","user_id":"anon_ac82c508e7b0f77a","comment_id":"c03q3ut","kind":"comment","text":"Another great link. Thanks man!","timestamp":"2008-04-15T14:28:05+00:00","score":1},{"role":"answerer","user_id":"anon_7c506be0eeb11814","comment_id":"c03q44t","kind":"comment","text":"Unfortunately the search for \"C++\" is not as good as it could be; some jobs *are* C++ jobs, others may be for other languages but give C++ as an example of a desired skill. In particular the San Jose jobs I saw were the ones which were most C++ specific.\n\n> large-ish mid-western state university\n\nPurdue?","timestamp":"2008-04-15T14:53:44+00:00","score":2}],"n_turns":4,"n_turns_after_thanks":1,"op_metadata":{"user_id":"anon_ac82c508e7b0f77a","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_7c506be0eeb11814","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c03q3q7","thanks_reply_id":"c03q3ut","post_score":6,"answer_score":2,"preferred_answer_is_top_level":false}}
{"user_id":"anon_8275e7f0d0113df5","answerer_user_id":"anon_491bd7a610603a81","subreddit":"programming","timestamp":"2008-04-16T20:19:42+00:00","post_id":"6g18f","question":"What is the best webhost for a personal playground and source repository?","preferred_answer":"Try Slicehost, they give you a VPS with full root access. They also have howtos to get you started on configuring your own server.","full_conversation":[{"role":"OP","user_id":"anon_8275e7f0d0113df5","comment_id":"6g18f","kind":"post","text":"What is the best webhost for a personal playground and source repository?","timestamp":"2008-04-16T20:19:42+00:00","score":0},{"role":"answerer","user_id":"anon_491bd7a610603a81","comment_id":"c03qmga","kind":"comment","text":"Try Slicehost, they give you a VPS with full root access. They also have howtos to get you started on configuring your own server.","timestamp":"2008-04-16T20:38:31+00:00","score":7},{"role":"OP","user_id":"anon_8275e7f0d0113df5","comment_id":"c03qmh6","kind":"comment","text":"Wow, thanks for the heads up. Their costs don't seem too bad either considering the flexibility.","timestamp":"2008-04-16T20:40:16+00:00","score":2},{"role":"answerer","user_id":"anon_491bd7a610603a81","comment_id":"c03qs9d","kind":"comment","text":"You're welcome. They also have forums if you get into trouble.","timestamp":"2008-04-17T07:58:31+00:00","score":2},{"role":"OP","user_id":"anon_8275e7f0d0113df5","comment_id":"c03quge","kind":"comment","text":"Do you have any recommendations on who to buy the domain name from? I was thinking gandi.net.\n\nI'm asking because I don't want to support a company like Network Solutions for example.","timestamp":"2008-04-17T14:11:31+00:00","score":1}],"n_turns":5,"n_turns_after_thanks":2,"op_metadata":{"user_id":"anon_8275e7f0d0113df5","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_491bd7a610603a81","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c03qmga","thanks_reply_id":"c03qmh6","post_score":0,"answer_score":7,"preferred_answer_is_top_level":true}}
{"user_id":"anon_b1e6d2a52ca0e97b","answerer_user_id":"anon_a59a47428e2fa45f","subreddit":"programming","timestamp":"2008-05-12T14:14:37+00:00","post_id":"6j2ex","question":"GPGPUs: Neat Idea or Disruptive Technology?","preferred_answer":"You can simulate double-floats and quad-floats using unevaluated sums of paired or quadrupled single-precision floats. If I remember right there is also some work done for multiprecision arithmetic. Helps with speeding up RSA encryption. \n\nhttp://portal.acm.org/citation.cfm?doid=1198555.1198768\n\nThere is of course speed penalty for doing all this. I don't know how economic that solution is now. \n\nI have only seen when one guy implemented in house SVM (Support Vector Machine) implementation using graphics card with single precision floats. Damn it was fast. Instant 150X speedup.","full_conversation":[{"role":"OP","user_id":"anon_b1e6d2a52ca0e97b","comment_id":"6j2ex","kind":"post","text":"GPGPUs: Neat Idea or Disruptive Technology?","timestamp":"2008-05-12T14:14:37+00:00","score":0},{"role":"answerer","user_id":"anon_a59a47428e2fa45f","comment_id":"c03zir8","kind":"comment","text":"You can simulate double-floats and quad-floats using unevaluated sums of paired or quadrupled single-precision floats. If I remember right there is also some work done for multiprecision arithmetic. Helps with speeding up RSA encryption. \n\nhttp://portal.acm.org/citation.cfm?doid=1198555.1198768\n\nThere is of course speed penalty for doing all this. I don't know how economic that solution is now. \n\nI have only seen when one guy implemented in house SVM (Support Vector Machine) implementation using graphics card with single precision floats. Damn it was fast. Instant 150X speedup.","timestamp":"2008-05-12T18:53:49+00:00","score":1},{"role":"OP","user_id":"anon_b1e6d2a52ca0e97b","comment_id":"c03zqq3","kind":"comment","text":"Thanks for the link, very interesting. Did that guy publish anything on his SVM implementation?","timestamp":"2008-05-13T07:41:25+00:00","score":1},{"role":"answerer","user_id":"anon_a59a47428e2fa45f","comment_id":"c03zqse","kind":"comment","text":"Nope. It was for data mining company and strictly trade secret (150X speedup means that you can increase data set sizes almost that much for the cost of GPU and some hard drives).\n\nThere is article about similar results with neural networks in the net somewhere.","timestamp":"2008-05-13T07:54:36+00:00","score":2}],"n_turns":4,"n_turns_after_thanks":1,"op_metadata":{"user_id":"anon_b1e6d2a52ca0e97b","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_a59a47428e2fa45f","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c03zir8","thanks_reply_id":"c03zqq3","post_score":0,"answer_score":1,"preferred_answer_is_top_level":false}}
{"user_id":"anon_52fb323d2559daf5","answerer_user_id":"anon_d13585895a3e0bd6","subreddit":"programming","timestamp":"2008-06-11T19:02:25+00:00","post_id":"6mz4u","question":"Ask Reddit: Multiplayer Card Game Hardware Needs?","preferred_answer":"The only reasonable answer is \"it depends\".\n\nI'd seriously consider Erlang for this, even if you don't already know it. You only need it for the core backend, the web site itself and everything else can be built in some other language you know. How many servers it would take is still an \"it depends\" situation (what the dependencies are, etc), but the scaling story is much better; you should get more games on one server and it'll be easier to add your second server (and third, and fourth...) if you start out either backing to a normal database or using Mnesia. (You can implement a way for your web site to query Mnesia for data without too much hassle.)","full_conversation":[{"role":"OP","user_id":"anon_52fb323d2559daf5","comment_id":"6mz4u","kind":"post","text":"Ask Reddit: Multiplayer Card Game Hardware Needs?","timestamp":"2008-06-11T19:02:25+00:00","score":0},{"role":"answerer","user_id":"anon_d13585895a3e0bd6","comment_id":"c04bjaw","kind":"comment","text":"The only reasonable answer is \"it depends\".\n\nI'd seriously consider Erlang for this, even if you don't already know it. You only need it for the core backend, the web site itself and everything else can be built in some other language you know. How many servers it would take is still an \"it depends\" situation (what the dependencies are, etc), but the scaling story is much better; you should get more games on one server and it'll be easier to add your second server (and third, and fourth...) if you start out either backing to a normal database or using Mnesia. (You can implement a way for your web site to query Mnesia for data without too much hassle.)","timestamp":"2008-06-11T19:07:45+00:00","score":2},{"role":"OP","user_id":"anon_52fb323d2559daf5","comment_id":"c04bjeh","kind":"comment","text":"Thanks. I'm not familiar with Erlang at all. What makes it more appropriate for this application?","timestamp":"2008-06-11T19:13:27+00:00","score":1},{"role":"answerer","user_id":"anon_d13585895a3e0bd6","comment_id":"c04bjin","kind":"comment","text":"You're looking to have a lot of intercommunicating processes; one socket per user (I'm assuming you want to use Flash to get a real socket and not go through HTTP for every request, which adds a ___lot___ of overhead), and with each of the users talking to each other and/or a central game process a whole lot.\n\nIn Erlang, you'll be able to naturally model this as one process per connection, one process per game (running the central rules), and each of these can communicate in a very natural manner. And, best of all, this \"natural manner\" of communication is also what you'll need to scale up; getting that all working in Java will be a good deal harder. (With only a bit of foresight, you can decouple the user's game state and the process managing the socket connection, so if their connection drops you can try to re-establish it right away with no state loss.)\n\nUsing Mnesia to store the main game data also means you can scale up fairly easily with more machines, and these machines will be easily (not quite \"trivially\", but \"easily\") clusterable, and you won't even have to think about whether the player sockets are all on the same machine as the main game process.\n\nFinally, you'll be able to use a real multi-threading solution, instead of shared memory, with full support in the language runtime.\n\nYou probably won't mind the focus on reliability, either, and live code upgrades may interest you too.\n\nBasically, it plays right into the strengths of Erlang and right into some of the weaknesses of Java. While you _can_ get around all of these issues in Java, I think that if you're the only programmer on the project you're going to blow a lot of time just assembling the necessary stack (if it even exists) and fighting with threading issues and locking issues and all kinds of other crap, whereas in Erlang, once you get past the \"learn the language\" step (which I won't lie, it will take a bit), you'll actually be solving your problem relatively quickly, and I would estimate you'll recover your time spent learning Erlang in a matter of weeks.\n\nBut just something to think about; if Java is what you want, go for it. I do think it's a bad idea, but you gotta do what you gotta do. (I don't want to sound like I'm pressuring you or anything.)","timestamp":"2008-06-11T19:21:14+00:00","score":2},{"role":"OP","user_id":"anon_52fb323d2559daf5","comment_id":"c04bk60","kind":"comment","text":"Cool, thanks for the well thought out reply.\r\n\r\nMy original plan was to use PHP ;) (still not over HTTP, just running the socket server as a standalone process), so I am moving towards something resembling an intelligent decision. I'm going to get the client working first, then I'll take care of the server side stuff.","timestamp":"2008-06-11T19:57:39+00:00","score":1}],"n_turns":5,"n_turns_after_thanks":2,"op_metadata":{"user_id":"anon_52fb323d2559daf5","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_d13585895a3e0bd6","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c04bjaw","thanks_reply_id":"c04bjeh","post_score":0,"answer_score":2,"preferred_answer_is_top_level":false}}
{"user_id":"anon_3412a6c800dd9c14","answerer_user_id":"anon_9960e099ca5b1b6a","subreddit":"programming","timestamp":"2008-06-30T16:12:31+00:00","post_id":"6pmis","question":"But what if I want to write a bytecode-based VM? What should I read?","preferred_answer":"Anything by [Anton Ertl](http://liinwww.ira.uka.de/csbib/Compiler/Inst.Computersprachen.TUWien?query=Ertl&partial=off&case=on&maxnum=200&sort=year) and [David Gregg](https://www.cs.tcd.ie/David.Gregg/pubs.html) for starters. Their papers are generally easy to read and always come with numbers. Or just use [vmgen](http://www.complang.tuwien.ac.at/anton/vmgen/) and call it a day; make sure to read the paper on it.\n\nIf you want a JIT on top of that, read some of [Michael Franz' papers](http://www.ics.uci.edu/%7Efranz/Site/publications.html). Don't forget that a decent JIT depends on a fast interpreter to find hotspots, so you can't skimp on the interpreter.\n\nIf you want a GC, try the Garbage Collection book by Jones & Lins. Or just read the plethora of newer publications on _that_ topic too.","full_conversation":[{"role":"OP","user_id":"anon_3412a6c800dd9c14","comment_id":"6pmis","kind":"post","text":"But what if I want to write a bytecode-based VM? What should I read?","timestamp":"2008-06-30T16:12:31+00:00","score":34},{"role":"answerer","user_id":"anon_9960e099ca5b1b6a","comment_id":"c04j9ex","kind":"comment","text":"Anything by [Anton Ertl](http://liinwww.ira.uka.de/csbib/Compiler/Inst.Computersprachen.TUWien?query=Ertl&partial=off&case=on&maxnum=200&sort=year) and [David Gregg](https://www.cs.tcd.ie/David.Gregg/pubs.html) for starters. Their papers are generally easy to read and always come with numbers. Or just use [vmgen](http://www.complang.tuwien.ac.at/anton/vmgen/) and call it a day; make sure to read the paper on it.\n\nIf you want a JIT on top of that, read some of [Michael Franz' papers](http://www.ics.uci.edu/%7Efranz/Site/publications.html). Don't forget that a decent JIT depends on a fast interpreter to find hotspots, so you can't skimp on the interpreter.\n\nIf you want a GC, try the Garbage Collection book by Jones & Lins. Or just read the plethora of newer publications on _that_ topic too.","timestamp":"2008-06-30T18:44:38+00:00","score":12},{"role":"OP","user_id":"anon_3412a6c800dd9c14","comment_id":"c04j9uc","kind":"comment","text":"Thanks, lots of pointers. Actually I just ordered the GC book from Jones & Lins before posting here.","timestamp":"2008-06-30T19:12:24+00:00","score":1},{"role":"answerer","user_id":"anon_9960e099ca5b1b6a","comment_id":"c04j9w2","kind":"comment","text":"I ought to point out that [this](http://www.complang.tuwien.ac.at/anton/euroforth/ef01/ertl01.pdf) paper by Ertl is a good overview of the various styles of threaded code.\n\nEven if you read most of the papers listed above, it's worth looking at vmgen. You _can_ write more efficient interpreters than it can generate, but it's not worth the effort.","timestamp":"2008-06-30T19:15:50+00:00","score":2},{"role":"OP","user_id":"anon_3412a6c800dd9c14","comment_id":"c04ja0l","kind":"comment","text":"My chief interest is in learning the subject, so I'll probably end up with a half-done Scheme compiler + VM. :-)","timestamp":"2008-06-30T19:23:51+00:00","score":1}],"n_turns":5,"n_turns_after_thanks":2,"op_metadata":{"user_id":"anon_3412a6c800dd9c14","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_9960e099ca5b1b6a","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c04j9ex","thanks_reply_id":"c04j9uc","post_score":34,"answer_score":12,"preferred_answer_is_top_level":true}}
{"user_id":"anon_730a1f319bb791bd","answerer_user_id":"anon_006ef77e1afdb6c1","subreddit":"programming","timestamp":"2008-06-30T18:32:30+00:00","post_id":"6pnb6","question":"AskReddit: How do I prevent a program from taking up extra memory in a Vista's environment?","preferred_answer":"Depends on what you want to do. If you are okay with generic, commercial, web-based software (for which there is a huge demand right now), Java (J2EE), PHP, Ruby, HTML / XML, JavaScript, C#, ASP, .NET, etc., with general knowledge of SQL stuff are all pretty safe bets.\n\nI just graduated and was promoted from intern to full-time developer at my company. We do web-based automotive end-of-line production testing / reporting (as well as some other apps). The majority of the work I do is Java (J2EE) and SQL. Every so often I get a smattering of C++ (when working on one of our older apps), HTML, and JavaScript... so I have pretty okay knowledge of all of those.\n\nIf I wanted to get a job elsewhere, I'd grab a PHP book, and maybe some stuff about Ruby and C#.","full_conversation":[{"role":"OP","user_id":"anon_730a1f319bb791bd","comment_id":"6pnb6","kind":"post","text":"AskReddit: How do I prevent a program from taking up extra memory in a Vista's environment?","timestamp":"2008-06-30T18:32:30+00:00","score":0},{"role":"answerer","user_id":"anon_006ef77e1afdb6c1","comment_id":"c04j9gw","kind":"comment","text":"Depends on what you want to do. If you are okay with generic, commercial, web-based software (for which there is a huge demand right now), Java (J2EE), PHP, Ruby, HTML / XML, JavaScript, C#, ASP, .NET, etc., with general knowledge of SQL stuff are all pretty safe bets.\n\nI just graduated and was promoted from intern to full-time developer at my company. We do web-based automotive end-of-line production testing / reporting (as well as some other apps). The majority of the work I do is Java (J2EE) and SQL. Every so often I get a smattering of C++ (when working on one of our older apps), HTML, and JavaScript... so I have pretty okay knowledge of all of those.\n\nIf I wanted to get a job elsewhere, I'd grab a PHP book, and maybe some stuff about Ruby and C#.","timestamp":"2008-06-30T18:48:33+00:00","score":1},{"role":"OP","user_id":"anon_730a1f319bb791bd","comment_id":"c04ja9e","kind":"comment","text":"thanks, urm, why did you get downmodded?","timestamp":"2008-06-30T19:39:04+00:00","score":1},{"role":"answerer","user_id":"anon_006ef77e1afdb6c1","comment_id":"c04jaqj","kind":"comment","text":"Not sure. Seems to be a fairly common theme nowadays where people downmod for no apparent reason and don't explain why.\n\nOh well. If I helped you out and all, I'm happy about it.","timestamp":"2008-06-30T20:10:58+00:00","score":1}],"n_turns":4,"n_turns_after_thanks":1,"op_metadata":{"user_id":"anon_730a1f319bb791bd","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_006ef77e1afdb6c1","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c04j9gw","thanks_reply_id":"c04ja9e","post_score":0,"answer_score":1,"preferred_answer_is_top_level":false}}
{"user_id":"anon_b4c868a39f4fe615","answerer_user_id":"anon_fa39223abacabf18","subreddit":"programming","timestamp":"2008-07-04T08:12:41+00:00","post_id":"6q8jq","question":"AskReddit: Experience/Suggestions programming with cheap webcams?","preferred_answer":"quickcam 9000 pro from logitech. To bad it doesn't fit in your price range, but it makes nice hires-videos (sth. like 1024x768) and works plug-and-play like under linux.\nSome years ago i bought a cheap quickcam express, it worked without any problems under linux but the image quality is very poor (besides the low resolution, QVGA 320x240).","full_conversation":[{"role":"OP","user_id":"anon_b4c868a39f4fe615","comment_id":"6q8jq","kind":"post","text":"AskReddit: Experience/Suggestions programming with cheap webcams?","timestamp":"2008-07-04T08:12:41+00:00","score":0},{"role":"answerer","user_id":"anon_fa39223abacabf18","comment_id":"c04kyox","kind":"comment","text":"quickcam 9000 pro from logitech. To bad it doesn't fit in your price range, but it makes nice hires-videos (sth. like 1024x768) and works plug-and-play like under linux.\nSome years ago i bought a cheap quickcam express, it worked without any problems under linux but the image quality is very poor (besides the low resolution, QVGA 320x240).","timestamp":"2008-07-04T14:18:19+00:00","score":2},{"role":"OP","user_id":"anon_b4c868a39f4fe615","comment_id":"c04l244","kind":"comment","text":"Thanks for the suggestion. Do you have any suggestions about how I meant start learning how to control it from (say) a C program? I've never worked with USB before, but I'm willing to learn :)","timestamp":"2008-07-04T19:30:41+00:00","score":1},{"role":"answerer","user_id":"anon_fa39223abacabf18","comment_id":"c04l8pt","kind":"comment","text":"> how to control it from (say) a C program?\n\nThis is fairly easy under linux. You don't even need USB knowledge. \nThe camera drivers provide a /dev/video device where you send commands using ioctl and receive image data as a stream or through shared memory.\nThe APl is called \"video 4 Linux\" and there are 2 versions of it (v4l and v4l2 for short), look at: http://linux.bytesex.org/v4l2/ for docs. (played with v4l and common lisp some time ago)","timestamp":"2008-07-05T10:01:47+00:00","score":2},{"role":"OP","user_id":"anon_b4c868a39f4fe615","comment_id":"c04ldxy","kind":"comment","text":"Great, thanks for your help! This looks like a good starting point.","timestamp":"2008-07-05T21:18:11+00:00","score":1}],"n_turns":5,"n_turns_after_thanks":2,"op_metadata":{"user_id":"anon_b4c868a39f4fe615","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_fa39223abacabf18","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c04kyox","thanks_reply_id":"c04l244","post_score":0,"answer_score":2,"preferred_answer_is_top_level":false}}
{"user_id":"anon_e5d84c248c220c51","answerer_user_id":"anon_6d17a4d28e386249","subreddit":"programming","timestamp":"2008-07-04T08:26:23+00:00","post_id":"6q8lc","question":"Ask Proggit: What is the best free/open source continuous build automation tool?","preferred_answer":"There's [buildbot](http://buildbot.sf.net/).","full_conversation":[{"role":"OP","user_id":"anon_e5d84c248c220c51","comment_id":"6q8lc","kind":"post","text":"Ask Proggit: What is the best free/open source continuous build automation tool?","timestamp":"2008-07-04T08:26:23+00:00","score":0},{"role":"answerer","user_id":"anon_6d17a4d28e386249","comment_id":"c04kymt","kind":"comment","text":"There's [buildbot](http://buildbot.sf.net/).","timestamp":"2008-07-04T14:12:41+00:00","score":2},{"role":"OP","user_id":"anon_e5d84c248c220c51","comment_id":"c04l8id","kind":"comment","text":"Thanks for the line. \n\nI should have mentioned it in the comment, that I was mainly looking for a solution to Windows, as we must build our thing in Windows. \n\nIt seems to me buildbot is *nix oriented.","timestamp":"2008-07-05T09:16:38+00:00","score":1},{"role":"answerer","user_id":"anon_6d17a4d28e386249","comment_id":"c04ladq","kind":"comment","text":"It runs on Windows.","timestamp":"2008-07-05T15:15:17+00:00","score":2}],"n_turns":4,"n_turns_after_thanks":1,"op_metadata":{"user_id":"anon_e5d84c248c220c51","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_6d17a4d28e386249","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c04kymt","thanks_reply_id":"c04l8id","post_score":0,"answer_score":2,"preferred_answer_is_top_level":true}}
{"user_id":"anon_5b338e8d75f116e3","answerer_user_id":"anon_7bac166cc272de7a","subreddit":"programming","timestamp":"2008-08-09T09:37:42+00:00","post_id":"6vl0z","question":"Ask Reddit: Steps and libraries to migrate away from C# into C++?","preferred_answer":"So it's a complete rewriting. the libraries depends of what's your current code is doing.\n\nBut you can take a look at [Boost](http://boost.org)","full_conversation":[{"role":"OP","user_id":"anon_5b338e8d75f116e3","comment_id":"6vl0z","kind":"post","text":"Ask Reddit: Steps and libraries to migrate away from C# into C++?","timestamp":"2008-08-09T09:37:42+00:00","score":0},{"role":"answerer","user_id":"anon_7bac166cc272de7a","comment_id":"c04zeqa","kind":"comment","text":"So it's a complete rewriting. the libraries depends of what's your current code is doing.\n\nBut you can take a look at [Boost](http://boost.org)","timestamp":"2008-08-09T10:19:18+00:00","score":2},{"role":"OP","user_id":"anon_5b338e8d75f116e3","comment_id":"c04zeqv","kind":"comment","text":"Thanks!!\r\n\r\nWhat would you use for communication instead of WCF and remoting?","timestamp":"2008-08-09T10:25:17+00:00","score":1},{"role":"answerer","user_id":"anon_7bac166cc272de7a","comment_id":"c04zeup","kind":"comment","text":"http://en.wikipedia.org/wiki/XML-RPC","timestamp":"2008-08-09T10:56:12+00:00","score":1}],"n_turns":4,"n_turns_after_thanks":1,"op_metadata":{"user_id":"anon_5b338e8d75f116e3","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_7bac166cc272de7a","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c04zeqa","thanks_reply_id":"c04zeqv","post_score":0,"answer_score":2,"preferred_answer_is_top_level":false}}
{"user_id":"anon_a7c156a70e967176","answerer_user_id":"anon_be12453c8b82aca3","subreddit":"programming","timestamp":"2008-08-11T16:28:38+00:00","post_id":"6vu4u","question":"Ask proggit: I'm an undergraduate making career plans. AI, graphics, speech recognition, and games are all fascinating. Is a CS Master's important?","preferred_answer":"I'd recommend checking out machine learning. It's broadly applicable and covers most of what you're interested in some way:\n\n * It's broadly used in Natural Language Processing / Computational Linguistics\n * It's AI that actually works :-)\n * Probably useful in Game AI (I have no experience in game programming)\n\nI'm not sure that many schools offer a degree in just that, but several schools have computer science programs with professors who are big in the field.\n\nYou said you're not interested in a PhD, but the Machine Learning PhD program at Carnagie Mellon is probably great:\n\nhttp://www.ml.cmu.edu/prospective_students/phd_programs.html\n\nOtherwise, like I said, you can enroll for a master's in a university that offer some classes in machine learning.\n\nYou can get some idea of who's who in the machine learning world by looking at the people involved in (or have publications/presentations at) these two conferences:\n\n * [NIPS](http://nips.cc/)\n * [ICML](http://icml2008.cs.helsinki.fi/)","full_conversation":[{"role":"OP","user_id":"anon_a7c156a70e967176","comment_id":"6vu4u","kind":"post","text":"Ask proggit: I'm an undergraduate making career plans. AI, graphics, speech recognition, and games are all fascinating. Is a CS Master's important?","timestamp":"2008-08-11T16:28:38+00:00","score":5},{"role":"answerer","user_id":"anon_be12453c8b82aca3","comment_id":"c05083i","kind":"comment","text":"I'd recommend checking out machine learning. It's broadly applicable and covers most of what you're interested in some way:\n\n * It's broadly used in Natural Language Processing / Computational Linguistics\n * It's AI that actually works :-)\n * Probably useful in Game AI (I have no experience in game programming)\n\nI'm not sure that many schools offer a degree in just that, but several schools have computer science programs with professors who are big in the field.\n\nYou said you're not interested in a PhD, but the Machine Learning PhD program at Carnagie Mellon is probably great:\n\nhttp://www.ml.cmu.edu/prospective_students/phd_programs.html\n\nOtherwise, like I said, you can enroll for a master's in a university that offer some classes in machine learning.\n\nYou can get some idea of who's who in the machine learning world by looking at the people involved in (or have publications/presentations at) these two conferences:\n\n * [NIPS](http://nips.cc/)\n * [ICML](http://icml2008.cs.helsinki.fi/)","timestamp":"2008-08-11T17:59:59+00:00","score":4},{"role":"OP","user_id":"anon_a7c156a70e967176","comment_id":"c05087s","kind":"comment","text":"Thank you. Those links will be helpful. I actually did some machine learning research last summer, and I agree that it's a (perhaps the only) good middle ground between my interests. I guess I just don't know anyone employed to do machine learning outside of academia.\n\nNothing against academia (I've had some wonderful professors) but at the moment, I don't see myself ending up there.","timestamp":"2008-08-11T18:08:48+00:00","score":1},{"role":"answerer","user_id":"anon_be12453c8b82aca3","comment_id":"c0509rb","kind":"comment","text":"> I guess I just don't know anyone employed to do machine learning outside of academia.\n\nI wouldn't look at it as \"doing machine learning,\" but rather applying machine learning to some particular domain.\n\nI'd imagine many interesting problems today could be approached with an ML-bent.\n\nFor instance, I bet:\n\n * A lot of serious players in Wall Street would surely look quite favorably on people with machine learning skills to fill their 'quant' positions.\n\n * As an example of above, [D E Shaw](http://www.deshaw.com/) could be somewhere in the \"upper echelon\" of what you could shoot for.\n\n * Google will love you\n\n * Look at the machine learning group at [NEC Labs](http://www.nec-labs.com/research/machine/index.php)\n\n * The chief scientist at [Sense Networks](http://www.sensenetworks.com/) is *the* machine learning guy at Columbia University. I could imagine much of the social-web 2.0 is hungry for ML skills\n\n * Anyone doing bioinformatics could benefit from machine learning\n\nI guess my point is that you don't have to stay in academia if you don't want to once you get some good training.\n\nOf course this is all conjecture as I'm still in academia ... but it does seem reasonable to me :-)","timestamp":"2008-08-11T19:53:19+00:00","score":1}],"n_turns":4,"n_turns_after_thanks":1,"op_metadata":{"user_id":"anon_a7c156a70e967176","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_be12453c8b82aca3","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c05083i","thanks_reply_id":"c05087s","post_score":5,"answer_score":4,"preferred_answer_is_top_level":false}}
{"user_id":"anon_624c930b4b8c6e24","answerer_user_id":"anon_b18f32d0234f935e","subreddit":"programming","timestamp":"2008-08-14T09:56:13+00:00","post_id":"6wa4i","question":"Now that the java platform is finally open source, and with jython being compatible with python 2.5, java finally sounds interesting again. What books should I get to refresh my java skills?","preferred_answer":"Personally I'm very partial to [Design Patterns: Elements of Reusable Object-Oriented Software](http://www.amazon.com/Design-Patterns-Object-Oriented-Addison-Wesley-Professional/dp/0201633612/ref=pd_bbs_sr_1?ie=UTF8&s=books&qid=1218756346&sr=8-1). I see Java more and more as a software engineering, rather than a programming language. You can do programming more effectively in Python/Jython or (J)Ruby, but Java for me still is king for developing type-safe, robust libraries and unit testing.\r\n\r\nYou might also want to read up on Eclipse or another decent IDE. Eclipse reduces the amount of monkey typing that all Java developers must endure dramatically with things like templates, getter/setter generation, delegate method generation etc. Since the editor parses the code as you type and keeps an AST in memory, refactoring support is excellent and you'll spend less time worrying about minor design issues when starting a new project. Code is compiled on the fly so startup times are minimal. It's also able to produce very descriptive and useful information about any errors you might have in your code (unlike GCC, for instance:)\r\n\r\nIf you want to know a bit more about how the JVM itself works, read [The JavaTM Virtual Machine Specification, Second Edition](http://java.sun.com/docs/books/jvms/second_edition/html/VMSpecTOC.doc.html) which is online and free. It'll give you a bit more insight into why some crappy things are as crappy as they are (backwards compatibility with Java 1.1). Read books that are recent enough to include language features of 1.5 and 1.6, such as static imports, enums, generics, varargs and so on, and decompile some Java code to see how the compiler implements them.","full_conversation":[{"role":"OP","user_id":"anon_624c930b4b8c6e24","comment_id":"6wa4i","kind":"post","text":"Now that the java platform is finally open source, and with jython being compatible with python 2.5, java finally sounds interesting again. What books should I get to refresh my java skills?","timestamp":"2008-08-14T09:56:13+00:00","score":3},{"role":"answerer","user_id":"anon_b18f32d0234f935e","comment_id":"c051r6l","kind":"comment","text":"Personally I'm very partial to [Design Patterns: Elements of Reusable Object-Oriented Software](http://www.amazon.com/Design-Patterns-Object-Oriented-Addison-Wesley-Professional/dp/0201633612/ref=pd_bbs_sr_1?ie=UTF8&s=books&qid=1218756346&sr=8-1). I see Java more and more as a software engineering, rather than a programming language. You can do programming more effectively in Python/Jython or (J)Ruby, but Java for me still is king for developing type-safe, robust libraries and unit testing.\r\n\r\nYou might also want to read up on Eclipse or another decent IDE. Eclipse reduces the amount of monkey typing that all Java developers must endure dramatically with things like templates, getter/setter generation, delegate method generation etc. Since the editor parses the code as you type and keeps an AST in memory, refactoring support is excellent and you'll spend less time worrying about minor design issues when starting a new project. Code is compiled on the fly so startup times are minimal. It's also able to produce very descriptive and useful information about any errors you might have in your code (unlike GCC, for instance:)\r\n\r\nIf you want to know a bit more about how the JVM itself works, read [The JavaTM Virtual Machine Specification, Second Edition](http://java.sun.com/docs/books/jvms/second_edition/html/VMSpecTOC.doc.html) which is online and free. It'll give you a bit more insight into why some crappy things are as crappy as they are (backwards compatibility with Java 1.1). Read books that are recent enough to include language features of 1.5 and 1.6, such as static imports, enums, generics, varargs and so on, and decompile some Java code to see how the compiler implements them.","timestamp":"2008-08-14T23:40:07+00:00","score":1},{"role":"OP","user_id":"anon_624c930b4b8c6e24","comment_id":"c051voz","kind":"comment","text":"Thanks for your comment. I don't know why you get downvoted, it was a good comment.","timestamp":"2008-08-15T07:27:58+00:00","score":1},{"role":"answerer","user_id":"anon_b18f32d0234f935e","comment_id":"c051vsi","kind":"comment","text":"Heh, no worries. This is Reddit, after all. People will downvote posts simply because they don't agree, it's easier than actually coming up with a good counterargument :)","timestamp":"2008-08-15T07:41:55+00:00","score":2}],"n_turns":4,"n_turns_after_thanks":1,"op_metadata":{"user_id":"anon_624c930b4b8c6e24","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_b18f32d0234f935e","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c051r6l","thanks_reply_id":"c051voz","post_score":3,"answer_score":1,"preferred_answer_is_top_level":true}}
{"user_id":"anon_1e70c4e0331a26b8","answerer_user_id":"anon_7c506be0eeb11814","subreddit":"programming","timestamp":"2008-08-15T14:06:01+00:00","post_id":"6wglz","question":"Ask Reddit: I'm hoping to write my own programming language for comp sci what sort of features should it have?","preferred_answer":"> What language?\n\nHaskell is pretty much designed for doing this. See: [Writing A Lisp Interpreter In Haskell](http://www.defmacro.org/ramblings/lisp-in-haskell.html) for a one-page example. The main reason still to use C is (to me) if you really, really want to one-to-one map over specific C libraries (particularly threads, signals, and networking) and system calls.\n\n> What types\n\nArrays? Lists? Maps?\n\n> feature suggestsions\n\nImplicit lazy parallelism.\n\n> Any name suggestions?\n\nI think \"FaceL\" is available. To go along the \"Faceless\" moniker, maybe implement [Katahdin](http://www.chrisseaton.com/katahdin/) in something other than C# -- it is a language whose syntax can be defined on the fly.","full_conversation":[{"role":"OP","user_id":"anon_1e70c4e0331a26b8","comment_id":"6wglz","kind":"post","text":"Ask Reddit: I'm hoping to write my own programming language for comp sci what sort of features should it have?","timestamp":"2008-08-15T14:06:01+00:00","score":3},{"role":"answerer","user_id":"anon_7c506be0eeb11814","comment_id":"c051zo3","kind":"comment","text":"> What language?\n\nHaskell is pretty much designed for doing this. See: [Writing A Lisp Interpreter In Haskell](http://www.defmacro.org/ramblings/lisp-in-haskell.html) for a one-page example. The main reason still to use C is (to me) if you really, really want to one-to-one map over specific C libraries (particularly threads, signals, and networking) and system calls.\n\n> What types\n\nArrays? Lists? Maps?\n\n> feature suggestsions\n\nImplicit lazy parallelism.\n\n> Any name suggestions?\n\nI think \"FaceL\" is available. To go along the \"Faceless\" moniker, maybe implement [Katahdin](http://www.chrisseaton.com/katahdin/) in something other than C# -- it is a language whose syntax can be defined on the fly.","timestamp":"2008-08-15T15:26:16+00:00","score":3},{"role":"OP","user_id":"anon_1e70c4e0331a26b8","comment_id":"c052dki","kind":"comment","text":"I completely forgot about arrays and lists thanks. I'll definitely need those. Lazy parellelism is one of those concepts that is just a little beyond my understanding if I can understand it better I'll try and see where it goes. The Katahdin idea seems good though I'm not sure how well I'll be able to implement it.","timestamp":"2008-08-16T17:39:30+00:00","score":2},{"role":"answerer","user_id":"anon_7c506be0eeb11814","comment_id":"c052dls","kind":"comment","text":"I haven't taken too deep a look at the source, but it should be implementable in other languages. To do a more direct mapping, the likelihood is that another object oriented language would be most suited.","timestamp":"2008-08-16T17:43:25+00:00","score":1}],"n_turns":4,"n_turns_after_thanks":1,"op_metadata":{"user_id":"anon_1e70c4e0331a26b8","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_7c506be0eeb11814","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c051zo3","thanks_reply_id":"c052dki","post_score":3,"answer_score":3,"preferred_answer_is_top_level":false}}
{"user_id":"anon_479037a5647b9497","answerer_user_id":"anon_6a4b00ef1953668c","subreddit":"programming","timestamp":"2008-08-19T17:19:04+00:00","post_id":"6x0vo","question":"Ask Proggit: Am I Screwed?","preferred_answer":"I'm in the home stretch of a similar project. This codebase wasn't \"huge\" (~150kloc) but it's taken over a year to dig ourselves out from underneath the mess we were handed with. Very little of the original code now remains.\n\nTactics that worked for us:\n\n * you cannot rewrite it from scratch right away, so don't even think about it. The code has to keep working.\n\n * software process tools are very helpful here. Your first goal above all needs to be the simplification and automation of the build & deployment of your project. You need to be able to cut a new release in at most ONE step. It would be best if you had a continuous integration server keyed to version control which builds, deploys, and tests your product whenever new changes are committed, and emails you if something goes wrong.\n\n * audit the existing code. Develop a feeling for where the trouble spots are, which modules don't meet standards, where the error handling is weak or nonexistent, etc.\n\n * moving forward your main line of thinking should be reducing the level of interconnectedness between your software components. It's my experience that software complexity rises with the square of the degree of connectedness of your module interference graph. Legacy codebases (especially those written by hacks) can be completely unmanageable Gordian knots. Do rewrite, but at the module/subsystem level. Gradually tease apart the spaghetti into small, self-contained, easily testable functional components. Once you've rewritten/refactored enough subsystems, you can usually hew away the rest of the garbage and be left with a much smaller, more manageable, functional codebase.\n\n * Make a priority queue for maintenance items and fix the stinkiest crap first. Keep in mind that the business people will expect you to be producing new features in parallel with any ongoing maintenance work.\n\n * The more automated testing you have, the better. Introducing testing \"in the large\" to a legacy codebase that was not designed for testability is not likely to work too well, although a black box testing framework like Selenium could be a big help.","full_conversation":[{"role":"OP","user_id":"anon_479037a5647b9497","comment_id":"6x0vo","kind":"post","text":"Ask Proggit: Am I Screwed?","timestamp":"2008-08-19T17:19:04+00:00","score":0},{"role":"answerer","user_id":"anon_6a4b00ef1953668c","comment_id":"c053k0t","kind":"comment","text":"I'm in the home stretch of a similar project. This codebase wasn't \"huge\" (~150kloc) but it's taken over a year to dig ourselves out from underneath the mess we were handed with. Very little of the original code now remains.\n\nTactics that worked for us:\n\n * you cannot rewrite it from scratch right away, so don't even think about it. The code has to keep working.\n\n * software process tools are very helpful here. Your first goal above all needs to be the simplification and automation of the build & deployment of your project. You need to be able to cut a new release in at most ONE step. It would be best if you had a continuous integration server keyed to version control which builds, deploys, and tests your product whenever new changes are committed, and emails you if something goes wrong.\n\n * audit the existing code. Develop a feeling for where the trouble spots are, which modules don't meet standards, where the error handling is weak or nonexistent, etc.\n\n * moving forward your main line of thinking should be reducing the level of interconnectedness between your software components. It's my experience that software complexity rises with the square of the degree of connectedness of your module interference graph. Legacy codebases (especially those written by hacks) can be completely unmanageable Gordian knots. Do rewrite, but at the module/subsystem level. Gradually tease apart the spaghetti into small, self-contained, easily testable functional components. Once you've rewritten/refactored enough subsystems, you can usually hew away the rest of the garbage and be left with a much smaller, more manageable, functional codebase.\n\n * Make a priority queue for maintenance items and fix the stinkiest crap first. Keep in mind that the business people will expect you to be producing new features in parallel with any ongoing maintenance work.\n\n * The more automated testing you have, the better. Introducing testing \"in the large\" to a legacy codebase that was not designed for testability is not likely to work too well, although a black box testing framework like Selenium could be a big help.","timestamp":"2008-08-19T17:57:48+00:00","score":10},{"role":"OP","user_id":"anon_479037a5647b9497","comment_id":"c053k5v","kind":"comment","text":"Thanks, \n\nCan you elaborate more on the testing/testing frameworks you found helpful?\n\nI've been thinking I should research continuous integration more. Our current QA approach, is all-too-often waiting until customers start complaining.","timestamp":"2008-08-19T18:05:41+00:00","score":2},{"role":"answerer","user_id":"anon_6a4b00ef1953668c","comment_id":"c053kez","kind":"comment","text":"Re: testing, that may be too big an issue to get into here. The \"software testing\" page on wikipedia might be a good launching point for your own research here. Also many books have been written on this subject.\n\nSomeone else posted a link to the \"Joel on Software Test\", which has some good advice, although I wouldn't consider it the last word on software process. Some items in his list are bigger wins than others.\n\nWhen I started my current project, I made a lot of software process changes. Continuous integration (and the build/deployment improvements you need to make in order to get it to work) has been the biggest improvement, by far.","timestamp":"2008-08-19T18:20:31+00:00","score":2}],"n_turns":4,"n_turns_after_thanks":1,"op_metadata":{"user_id":"anon_479037a5647b9497","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_6a4b00ef1953668c","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c053k0t","thanks_reply_id":"c053k5v","post_score":0,"answer_score":10,"preferred_answer_is_top_level":false}}
{"user_id":"anon_bcc4113dbf695eb4","answerer_user_id":"anon_7ab0d7c289329b53","subreddit":"programming","timestamp":"2008-08-26T07:41:19+00:00","post_id":"6y0zn","question":"What is the best (python) library for creating interactive maps that incorporate GIS data sets?","preferred_answer":"Did you check out what they used for whrrl.com?\n\nI lost the original company, but you might get some help here:\n\nhttp://gislounge.com/python-and-gis-resources/","full_conversation":[{"role":"OP","user_id":"anon_bcc4113dbf695eb4","comment_id":"6y0zn","kind":"post","text":"What is the best (python) library for creating interactive maps that incorporate GIS data sets?","timestamp":"2008-08-26T07:41:19+00:00","score":0},{"role":"answerer","user_id":"anon_7ab0d7c289329b53","comment_id":"c056aba","kind":"comment","text":"Did you check out what they used for whrrl.com?\n\nI lost the original company, but you might get some help here:\n\nhttp://gislounge.com/python-and-gis-resources/","timestamp":"2008-08-26T07:52:42+00:00","score":1},{"role":"OP","user_id":"anon_bcc4113dbf695eb4","comment_id":"c056eyh","kind":"comment","text":"Thanks for the link, it looks good. As for whrrl it looks like they just use google maps and plot points on the map. I want to use my own elevation map instead, and I'm a little lost on how to start. I'll try sifting through the link you sent.\n\ncheers","timestamp":"2008-08-26T16:00:59+00:00","score":1},{"role":"answerer","user_id":"anon_7ab0d7c289329b53","comment_id":"c056puo","kind":"comment","text":"Oh nice - the best use of elevation data mashed with reality and google maps is from these guys:\n\nhttp://www.enkin.net\n\nAre you using the NASA elevation data?","timestamp":"2008-08-27T04:18:08+00:00","score":1}],"n_turns":4,"n_turns_after_thanks":1,"op_metadata":{"user_id":"anon_bcc4113dbf695eb4","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_7ab0d7c289329b53","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c056aba","thanks_reply_id":"c056eyh","post_score":0,"answer_score":1,"preferred_answer_is_top_level":false}}
{"user_id":"anon_b0f143ad97a799da","answerer_user_id":"anon_8ee7075e7fff3cdd","subreddit":"programming","timestamp":"2008-09-16T02:57:06+00:00","post_id":"71nhh","question":"Ask Proggit: What's missing from programming languages?","preferred_answer":"Gah, I really need to put a monitoring script on that (putting it on a proper server would probably help too). Should be back up around 6:30 Eastern Time.\n\nIn the meantime, the download page is still up: http://www.retrodev.com/rhope.html There's a zip that contains some heavily commented (but relatively trivial) examples which will at least give you an idea of what the language currently looks like.","full_conversation":[{"role":"OP","user_id":"anon_b0f143ad97a799da","comment_id":"71nhh","kind":"post","text":"Ask Proggit: What's missing from programming languages?","timestamp":"2008-09-16T02:57:06+00:00","score":12},{"role":"answerer","user_id":"anon_8ee7075e7fff3cdd","comment_id":"c05ghuy","kind":"comment","text":"Gah, I really need to put a monitoring script on that (putting it on a proper server would probably help too). Should be back up around 6:30 Eastern Time.\n\nIn the meantime, the download page is still up: http://www.retrodev.com/rhope.html There's a zip that contains some heavily commented (but relatively trivial) examples which will at least give you an idea of what the language currently looks like.","timestamp":"2008-09-16T20:21:54+00:00","score":1},{"role":"OP","user_id":"anon_b0f143ad97a799da","comment_id":"c05gifs","kind":"comment","text":"cool, thanks. do you develop this on the side? or is this your full-time thing?","timestamp":"2008-09-16T20:55:44+00:00","score":1},{"role":"answerer","user_id":"anon_8ee7075e7fff3cdd","comment_id":"c05gkn3","kind":"comment","text":"On the side. I am largely a PHP developer by day.\n\nWeb site should be back up now. I must have knocked the video card loose when I was fiddling with cables last night (the machine hosting the site doesn't currently have a case).","timestamp":"2008-09-16T23:24:48+00:00","score":2}],"n_turns":4,"n_turns_after_thanks":1,"op_metadata":{"user_id":"anon_b0f143ad97a799da","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_8ee7075e7fff3cdd","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c05ghuy","thanks_reply_id":"c05gifs","post_score":12,"answer_score":1,"preferred_answer_is_top_level":false}}
{"user_id":"anon_6cedc1f27002261f","answerer_user_id":"anon_60c2a8911901bb24","subreddit":"programming","timestamp":"2008-09-23T16:16:13+00:00","post_id":"731xl","question":"Hey Programmers: I'd like to transition from QA to development- What steps should I take?","preferred_answer":"The logical next step, career-wise, is to learn a scripting language and start automating your current job. Much easier (from a job market POV) to transition that way than to try and make the jump all at once.\n\nYou'll probably want to supplement it with some self-study and independent projects, though, as automating QA stuff involves:\n\n* Easy 'programming' -- your programs will probably all be very linear, step one-two-three things with no data structure/algorithms work at all. (e.g.: \"Uninstall old version, check that the system is clean, download latest build, install it, check that it was installed properly.\")\n* Difficult, fiddly, and frustrating API/integration work; 99% of the effort will be in finding the right libraries/languages/etc to use and getting it to work correctly. And often the right tool to use is one that rots your brain -- I've written a fair number of continuous-integration tools in VBA of all things.\n\nAnother simple next step, if it's allowed: Start supplementing your QA with code reading. Try and find a bug or two in new code *before* you actually test it... ((The thing that has probably helped me the most as a programmer was the realization that you cannot read code like a novel; you have to approach it like an academic math paper, which for difficult topics, or unfamiliar ones, means upwards of an hour-per-paragraph with lots of cross referencing. Of course I first had to realize that you can't read an academic paper like a novel ... ))","full_conversation":[{"role":"OP","user_id":"anon_6cedc1f27002261f","comment_id":"731xl","kind":"post","text":"Hey Programmers: I'd like to transition from QA to development- What steps should I take?","timestamp":"2008-09-23T16:16:13+00:00","score":0},{"role":"answerer","user_id":"anon_60c2a8911901bb24","comment_id":"c05jpl5","kind":"comment","text":"The logical next step, career-wise, is to learn a scripting language and start automating your current job. Much easier (from a job market POV) to transition that way than to try and make the jump all at once.\n\nYou'll probably want to supplement it with some self-study and independent projects, though, as automating QA stuff involves:\n\n* Easy 'programming' -- your programs will probably all be very linear, step one-two-three things with no data structure/algorithms work at all. (e.g.: \"Uninstall old version, check that the system is clean, download latest build, install it, check that it was installed properly.\")\n* Difficult, fiddly, and frustrating API/integration work; 99% of the effort will be in finding the right libraries/languages/etc to use and getting it to work correctly. And often the right tool to use is one that rots your brain -- I've written a fair number of continuous-integration tools in VBA of all things.\n\nAnother simple next step, if it's allowed: Start supplementing your QA with code reading. Try and find a bug or two in new code *before* you actually test it... ((The thing that has probably helped me the most as a programmer was the realization that you cannot read code like a novel; you have to approach it like an academic math paper, which for difficult topics, or unfamiliar ones, means upwards of an hour-per-paragraph with lots of cross referencing. Of course I first had to realize that you can't read an academic paper like a novel ... ))","timestamp":"2008-09-23T16:42:48+00:00","score":2},{"role":"OP","user_id":"anon_6cedc1f27002261f","comment_id":"c05jq9v","kind":"comment","text":"Thanks for the suggestions. Unfortunately most of my testing is manual, everytime we try to adopt new QA software- the project gets abandoned and forgotten. I work on websites, so I can view the front-end code. Maybe as I get better I'll ask to look at some of the back-end code... thanks for the suggestions.","timestamp":"2008-09-23T17:16:48+00:00","score":1},{"role":"answerer","user_id":"anon_60c2a8911901bb24","comment_id":"c05jr3c","kind":"comment","text":"Try experimenting a bit with something like [selenium](http://selenium.openqa.org/)? I haven't used it myself but it seems rather slick.\n\nIt's important to never turn this sort of thing into a project: projects never go anywhere. Puttering around a bit and experimenting, however, does.\n\nAnd remember the point is to start to build in programming tasks as you go, so make sure to exercise w/ that as opposed to just recording-and-playing-back tests...","timestamp":"2008-09-23T17:58:39+00:00","score":1}],"n_turns":4,"n_turns_after_thanks":1,"op_metadata":{"user_id":"anon_6cedc1f27002261f","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_60c2a8911901bb24","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c05jpl5","thanks_reply_id":"c05jq9v","post_score":0,"answer_score":2,"preferred_answer_is_top_level":false}}
{"user_id":"anon_38107385fa988411","answerer_user_id":"anon_f9fa0339174da098","subreddit":"programming","timestamp":"2008-10-02T06:13:38+00:00","post_id":"74rnz","question":"Ask Reddit: How much should I charge for contract programming work?","preferred_answer":"Without knowing anything more than the description of the project and your experience, you should be asking for more like $60 or $75/hr. In my experience most of the time people don't question rates, but need to know them for budgeting reasons.\n\nAlso, I wouldn't recommend taking a contract with such a short turnaround time. Maybe it's common in some contexts, but 3 days and $200, not to mention an hour-based requirement on the initial request, seems a bit shady to me.","full_conversation":[{"role":"OP","user_id":"anon_38107385fa988411","comment_id":"74rnz","kind":"post","text":"Ask Reddit: How much should I charge for contract programming work?","timestamp":"2008-10-02T06:13:38+00:00","score":15},{"role":"answerer","user_id":"anon_f9fa0339174da098","comment_id":"c05o8ii","kind":"comment","text":"Without knowing anything more than the description of the project and your experience, you should be asking for more like $60 or $75/hr. In my experience most of the time people don't question rates, but need to know them for budgeting reasons.\n\nAlso, I wouldn't recommend taking a contract with such a short turnaround time. Maybe it's common in some contexts, but 3 days and $200, not to mention an hour-based requirement on the initial request, seems a bit shady to me.","timestamp":"2008-10-02T07:13:44+00:00","score":12},{"role":"OP","user_id":"anon_38107385fa988411","comment_id":"c05o8kl","kind":"comment","text":"Thanks much for your input, and I would definitely agree on the turnaround time. I was a little put off from the urgency they conveyed, but I didn't negotiate a fair price and I can see now that I was *severely* underpaid. By anywheres from $50-$70 an *hour*.","timestamp":"2008-10-02T07:21:11+00:00","score":2},{"role":"answerer","user_id":"anon_f9fa0339174da098","comment_id":"c05o8l4","kind":"comment","text":"The good news: you now have something to show future clients, and if the project ends well you have a good reference. I got most of my initial leads by doing pro-bono work, so you beat me by $200!\n\nEdit: The general rule of thumb is to think of the highest number you could reasonably expect to get paid and double it. There's nothing wrong with a bit of haggling up front, either, and for that you have to start high.","timestamp":"2008-10-02T07:23:35+00:00","score":5}],"n_turns":4,"n_turns_after_thanks":1,"op_metadata":{"user_id":"anon_38107385fa988411","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_f9fa0339174da098","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c05o8ii","thanks_reply_id":"c05o8kl","post_score":15,"answer_score":12,"preferred_answer_is_top_level":false}}
{"user_id":"anon_8e2e46ae9a795dd1","answerer_user_id":"anon_bf5fcb839c8f4827","subreddit":"programming","timestamp":"2008-10-07T03:02:45+00:00","post_id":"75mh6","question":"What's So Evil About Mono? - Linux Today Blog","preferred_answer":"It stands in the way of sexual intercourse.","full_conversation":[{"role":"OP","user_id":"anon_8e2e46ae9a795dd1","comment_id":"75mh6","kind":"post","text":"What's So Evil About Mono? - Linux Today Blog","timestamp":"2008-10-07T03:02:45+00:00","score":56},{"role":"answerer","user_id":"anon_bf5fcb839c8f4827","comment_id":"c05qmjj","kind":"comment","text":"It stands in the way of sexual intercourse.","timestamp":"2008-10-07T03:03:39+00:00","score":-15},{"role":"OP","user_id":"anon_8e2e46ae9a795dd1","comment_id":"c05qmk0","kind":"comment","text":"Thank you for making Reddit feel a little more like Digg.","timestamp":"2008-10-07T03:05:01+00:00","score":7},{"role":"answerer","user_id":"anon_bf5fcb839c8f4827","comment_id":"c05qmxk","kind":"comment","text":"hey, you was asking for it.","timestamp":"2008-10-07T03:31:18+00:00","score":-12}],"n_turns":4,"n_turns_after_thanks":1,"op_metadata":{"user_id":"anon_8e2e46ae9a795dd1","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_bf5fcb839c8f4827","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c05qmjj","thanks_reply_id":"c05qmk0","post_score":56,"answer_score":-15,"preferred_answer_is_top_level":true}}
{"user_id":"anon_5df1008403daaef6","answerer_user_id":"anon_732adc283a4318c0","subreddit":"programming","timestamp":"2008-10-07T18:12:39+00:00","post_id":"75r92","question":"Ask a game dev: Anything you ever wanted to ask a console game programmer?","preferred_answer":">I didn't think the hardware was really powerful enough for that.\n\nIt's not. It wasn't my choice to use lua and I fought all I could to keep it out.","full_conversation":[{"role":"OP","user_id":"anon_5df1008403daaef6","comment_id":"75r92","kind":"post","text":"Ask a game dev: Anything you ever wanted to ask a console game programmer?","timestamp":"2008-10-07T18:12:39+00:00","score":220},{"role":"answerer","user_id":"anon_732adc283a4318c0","comment_id":"c05r009","kind":"comment","text":">I didn't think the hardware was really powerful enough for that.\n\nIt's not. It wasn't my choice to use lua and I fought all I could to keep it out.","timestamp":"2008-10-07T19:46:51+00:00","score":12},{"role":"OP","user_id":"anon_5df1008403daaef6","comment_id":"c05r01k","kind":"comment","text":"Ouch. Thanks for the heads up then. I'll keep that in mind.","timestamp":"2008-10-07T19:48:36+00:00","score":11},{"role":"answerer","user_id":"anon_732adc283a4318c0","comment_id":"c05r09y","kind":"comment","text":"Just to let you know. I don't work at the company where I made DS games anymore. I've moved onto another game studio.\n\nI left that company after the CEO insisted..no commanded that I use floating point arithmetics on the DS to \"make the code cleaner and faster\". Seriously. \n\nI quit before I can really see how much that would hurt on the next game.","timestamp":"2008-10-07T19:59:56+00:00","score":12},{"role":"OP","user_id":"anon_5df1008403daaef6","comment_id":"c05r0fw","kind":"comment","text":"Holy shit.\n\nWhat games did you make before you left? Any I'd know?","timestamp":"2008-10-07T20:07:22+00:00","score":5},{"role":"answerer","user_id":"anon_732adc283a4318c0","comment_id":"c05r0m2","kind":"comment","text":"Honestly, I'm not too proud of them so I'd rather not say.","timestamp":"2008-10-07T20:15:45+00:00","score":5},{"role":"OP","user_id":"anon_5df1008403daaef6","comment_id":"c05r0r3","kind":"comment","text":"Ouch. Fair enough. There's no shame in making My Little Pony Fashion Design Kit 2006 if it pays the bills.","timestamp":"2008-10-07T20:22:27+00:00","score":8},{"role":"answerer","user_id":"anon_732adc283a4318c0","comment_id":"c05r13k","kind":"comment","text":"Let me just say this: My friend, who left the company 3 years ago, did the mistake of telling his new coworkers what games he worked on and he *still* hasn't lived it down.\n\nI haven't told anybody. Not my coworkers, not my friends, and not anybody who might remotely have a chance of knowing somebody I work with.","timestamp":"2008-10-07T20:40:00+00:00","score":10}],"n_turns":8,"n_turns_after_thanks":5,"op_metadata":{"user_id":"anon_5df1008403daaef6","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_732adc283a4318c0","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c05r009","thanks_reply_id":"c05r01k","post_score":220,"answer_score":12,"preferred_answer_is_top_level":false}}
{"user_id":"anon_ae0470f0ef8211ef","answerer_user_id":"anon_e1c04ab98fefbcdd","subreddit":"programming","timestamp":"2008-10-24T19:34:56+00:00","post_id":"7974q","question":"Ask proggit: Good fluxbox-based distributions?","preferred_answer":"distro should help you install new packages and admin your system, yet you remind me of my uncle who tried dozens of livecds and chose distro that had prettiest desktop background and widget theme.","full_conversation":[{"role":"OP","user_id":"anon_ae0470f0ef8211ef","comment_id":"7974q","kind":"post","text":"Ask proggit: Good fluxbox-based distributions?","timestamp":"2008-10-24T19:34:56+00:00","score":0},{"role":"answerer","user_id":"anon_e1c04ab98fefbcdd","comment_id":"c060icz","kind":"comment","text":"distro should help you install new packages and admin your system, yet you remind me of my uncle who tried dozens of livecds and chose distro that had prettiest desktop background and widget theme.","timestamp":"2008-10-24T21:02:40+00:00","score":3},{"role":"OP","user_id":"anon_ae0470f0ef8211ef","comment_id":"c060j3l","kind":"comment","text":"that worked happily enough under gentoo and descendants, but ubuntu really does fight you if you stray from the gnome way.","timestamp":"2008-10-24T21:42:55+00:00","score":1},{"role":"answerer","user_id":"anon_e1c04ab98fefbcdd","comment_id":"c060jbf","kind":"comment","text":"than stay with gentoo. if your wifi works under any other distro it can work under gentoo too. and there are plenty of people on forums.gentoo.org that will help you to make it work.","timestamp":"2008-10-24T21:56:02+00:00","score":2}],"n_turns":4,"n_turns_after_thanks":1,"op_metadata":{"user_id":"anon_ae0470f0ef8211ef","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_e1c04ab98fefbcdd","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c060icz","thanks_reply_id":"c060j3l","post_score":0,"answer_score":3,"preferred_answer_is_top_level":true}}
{"user_id":"anon_5356538e0fe43405","answerer_user_id":"anon_ce362ce3178609e9","subreddit":"programming","timestamp":"2008-10-28T16:12:38+00:00","post_id":"79veo","question":"Is Code Coverage Really All That Useful?","preferred_answer":"The second example is great. Not only did he typo 'return', the code cannot crash because it does floating-point division, which can handle division by zero just fine and in a well-defined manner.\n\nNot to belittle the article, though it's a bit devoid of content: he's right, 100% code coverage is, unsurprisingly enough, not proof that the code works.","full_conversation":[{"role":"OP","user_id":"anon_5356538e0fe43405","comment_id":"79veo","kind":"post","text":"Is Code Coverage Really All That Useful?","timestamp":"2008-10-28T16:12:38+00:00","score":7},{"role":"answerer","user_id":"anon_ce362ce3178609e9","comment_id":"c062e98","kind":"comment","text":"The second example is great. Not only did he typo 'return', the code cannot crash because it does floating-point division, which can handle division by zero just fine and in a well-defined manner.\n\nNot to belittle the article, though it's a bit devoid of content: he's right, 100% code coverage is, unsurprisingly enough, not proof that the code works.","timestamp":"2008-10-28T16:46:35+00:00","score":5},{"role":"OP","user_id":"anon_5356538e0fe43405","comment_id":"c062fv4","kind":"comment","text":"Fixed the typo. Thanks for the correction.\n\nAs for content, I respectfully disagree. The point may be simple, even intuitive to some, but that doesn't change the fact that there are programmers and managers out there who view code coverage as a useful way to gauge how well-tested their applications are when in fact it provides very little information to that. I will agree with some of the other commenters, however, that code coverage does encourage developers to think more about testing different use cases.","timestamp":"2008-10-28T18:01:56+00:00","score":-1},{"role":"answerer","user_id":"anon_ce362ce3178609e9","comment_id":"c062g3t","kind":"comment","text":"> Fixed the typo. Thanks for the correction.\n\nIt's still doing floating point division, which isn't problematic in the way you describe.\n\n> The point may be simple, even intuitive to some, but that doesn't change the fact that there are programmers and managers out there who view code coverage as a useful way to gauge how well-tested their applications are when in fact it provides very little information to that.\n\nFortunately, I have yet to encounter such people. :-) (Although I haven't much discussed code coverage with people, either.)","timestamp":"2008-10-28T18:13:58+00:00","score":2}],"n_turns":4,"n_turns_after_thanks":1,"op_metadata":{"user_id":"anon_5356538e0fe43405","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_ce362ce3178609e9","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c062e98","thanks_reply_id":"c062fv4","post_score":7,"answer_score":5,"preferred_answer_is_top_level":true}}
{"user_id":"anon_f1dc63b1240da3b4","answerer_user_id":"anon_1cd048c1f88f02ef","subreddit":"programming","timestamp":"2008-11-04T20:49:22+00:00","post_id":"7bc1q","question":"I want to learn a programming language for web. Where do I start, Reddit?","preferred_answer":"PHP is that special combination of Popular and Easy To Hate that leads to a fair amount of ranting and snark. I myself am responsible for plenty of both.\n\nPHP's popularity, wide utilization, and laundry list of viable projects do actually point at some merits, many of which have to do with its accessibility to entry-level coders. Despite this, I'm just about certain that a beginner will be better served by other languages and environments.\n\nIn no particular order:\n\n* Culture, culture, culture. There are PHP best practices and (theoretically) style conventions. The language offers, some quirks aside, plenty of features which can help keep things tidy. The dominant culture of PHP is to ignore all of these things.\n* Habits. This is probably only a restatement of \"culture\", but all things being equal, you will be a better programmer with more portable skills sooner if you're exposed primarily to better code, better practices, better conventions, and better documentation.\n* If you _need_ to write PHP after learning any reasonable modern language, you'll be fine (you'll be frustrated too, but that's a separate issue). It's cake to pick up. There is, however, a higher than average risk that if you learn what seems to be a satisfactory amount of PHP, you're going to find yourself at sea in other environments.\n\nI could go on for a while in this vein, but I think I'm essentially repeating myself.\n\nEdit: And I'm willing to admit that I could be wrong in a pretty important way. Maybe for lots of people the most important thing is that they can _get traction with something_. PHP certainly seems to enable a lot of people to do just that.","full_conversation":[{"role":"OP","user_id":"anon_f1dc63b1240da3b4","comment_id":"7bc1q","kind":"post","text":"I want to learn a programming language for web. Where do I start, Reddit?","timestamp":"2008-11-04T20:49:22+00:00","score":2},{"role":"answerer","user_id":"anon_1cd048c1f88f02ef","comment_id":"c067fzc","kind":"comment","text":"PHP is that special combination of Popular and Easy To Hate that leads to a fair amount of ranting and snark. I myself am responsible for plenty of both.\n\nPHP's popularity, wide utilization, and laundry list of viable projects do actually point at some merits, many of which have to do with its accessibility to entry-level coders. Despite this, I'm just about certain that a beginner will be better served by other languages and environments.\n\nIn no particular order:\n\n* Culture, culture, culture. There are PHP best practices and (theoretically) style conventions. The language offers, some quirks aside, plenty of features which can help keep things tidy. The dominant culture of PHP is to ignore all of these things.\n* Habits. This is probably only a restatement of \"culture\", but all things being equal, you will be a better programmer with more portable skills sooner if you're exposed primarily to better code, better practices, better conventions, and better documentation.\n* If you _need_ to write PHP after learning any reasonable modern language, you'll be fine (you'll be frustrated too, but that's a separate issue). It's cake to pick up. There is, however, a higher than average risk that if you learn what seems to be a satisfactory amount of PHP, you're going to find yourself at sea in other environments.\n\nI could go on for a while in this vein, but I think I'm essentially repeating myself.\n\nEdit: And I'm willing to admit that I could be wrong in a pretty important way. Maybe for lots of people the most important thing is that they can _get traction with something_. PHP certainly seems to enable a lot of people to do just that.","timestamp":"2008-11-05T21:29:49+00:00","score":3},{"role":"OP","user_id":"anon_f1dc63b1240da3b4","comment_id":"c067iq7","kind":"comment","text":"Thanks for all the advice. But I'm not really sure what you're saying, since you say both good and bad things about PHP. Are you saying I shouldn't bother jumping into this first, because I'll easily pick it up later when I learn better code practices?","timestamp":"2008-11-05T23:13:11+00:00","score":1},{"role":"answerer","user_id":"anon_1cd048c1f88f02ef","comment_id":"c067j46","kind":"comment","text":"Pretty much, with a touch of \"if you're lucky you'll never need it\" and some \"but I'm not feeling especially strident about this today\".","timestamp":"2008-11-05T23:29:51+00:00","score":1}],"n_turns":4,"n_turns_after_thanks":1,"op_metadata":{"user_id":"anon_f1dc63b1240da3b4","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_1cd048c1f88f02ef","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c067fzc","thanks_reply_id":"c067iq7","post_score":2,"answer_score":3,"preferred_answer_is_top_level":false}}
{"user_id":"anon_e52defe27dbdb99a","answerer_user_id":"anon_6a91a70ea4a08b66","subreddit":"programming","timestamp":"2008-11-09T18:47:04+00:00","post_id":"7cbbx","question":"Ask proggit: What are the best books or reources for a programmer (without a good sense of style) to learn to make good looking websites?","preferred_answer":"Simple is elegant, just sketch something simple and use a colour scheme from [colorlovers](http://www.colourlovers.com/).\r\n\r\nIt's not as difficult as some people would have you believe.","full_conversation":[{"role":"OP","user_id":"anon_e52defe27dbdb99a","comment_id":"7cbbx","kind":"post","text":"Ask proggit: What are the best books or reources for a programmer (without a good sense of style) to learn to make good looking websites?","timestamp":"2008-11-09T18:47:04+00:00","score":21},{"role":"answerer","user_id":"anon_6a91a70ea4a08b66","comment_id":"c069stt","kind":"comment","text":"Simple is elegant, just sketch something simple and use a colour scheme from [colorlovers](http://www.colourlovers.com/).\r\n\r\nIt's not as difficult as some people would have you believe.","timestamp":"2008-11-09T19:46:44+00:00","score":9},{"role":"OP","user_id":"anon_e52defe27dbdb99a","comment_id":"c069sxg","kind":"comment","text":"Thanks for the link, that's an interesting site and the kind of thing I'd never find on my own.","timestamp":"2008-11-09T19:53:57+00:00","score":3},{"role":"answerer","user_id":"anon_6a91a70ea4a08b66","comment_id":"c069t55","kind":"comment","text":"Why not just adapt an open source [template](http://www.google.com/search?client=opera&rls=en&q=open+source+web+templates).","timestamp":"2008-11-09T20:09:26+00:00","score":3},{"role":"OP","user_id":"anon_e52defe27dbdb99a","comment_id":"c069tib","kind":"comment","text":"I think those are nice as a reference. One problem is that I know many of those suck, and I don't know why they suck. I also know that what I will prefer isn't going to be what the typical user will (who probably won't have the mind of a programmer/mathematician/internet troll).\n\nI know from many other life experiences that there are a _lot_ of areas where you have to search really hard to find what the general principles are, and people will scream at you that there's no such thing, and people will give you the wrong idea, but nonetheless the general principles _do_ exist, and they are fantastically effective when you find them.","timestamp":"2008-11-09T20:30:55+00:00","score":3},{"role":"answerer","user_id":"anon_6a91a70ea4a08b66","comment_id":"c069trg","kind":"comment","text":"Dude. The general principle is to keep it simple. As long as you're not building an ajax application, that's fairly easy to acheive. A header, a navigation, a content box and a good easy on the eye colour scheme is my personal preference. Minimal CSS, minimal bitmap trickery, minimal JavaScript.\r\n\r\nIf you really need inspiration, don't go looking for books and resources, try to adapt one from real life or something.","timestamp":"2008-11-09T20:46:03+00:00","score":1}],"n_turns":6,"n_turns_after_thanks":3,"op_metadata":{"user_id":"anon_e52defe27dbdb99a","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_6a91a70ea4a08b66","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c069stt","thanks_reply_id":"c069sxg","post_score":21,"answer_score":9,"preferred_answer_is_top_level":true}}
{"user_id":"anon_44fd86fd966f9ddf","answerer_user_id":"anon_482f776db38438b5","subreddit":"programming","timestamp":"2008-11-17T11:50:09+00:00","post_id":"7duum","question":"I've built this site to help people split bills between friends. What do you think?","preferred_answer":"I was a bit dubious at first, but actually I really like it. There are ten of us going to a house in the country in two weeks and we split the food and accommodation between us. I can see this being a great way to help us work who owes who what.\n\nThough the ability to add more fields for extra people would be great.","full_conversation":[{"role":"OP","user_id":"anon_44fd86fd966f9ddf","comment_id":"7duum","kind":"post","text":"I've built this site to help people split bills between friends. What do you think?","timestamp":"2008-11-17T11:50:09+00:00","score":0},{"role":"answerer","user_id":"anon_482f776db38438b5","comment_id":"c06eaae","kind":"comment","text":"I was a bit dubious at first, but actually I really like it. There are ten of us going to a house in the country in two weeks and we split the food and accommodation between us. I can see this being a great way to help us work who owes who what.\n\nThough the ability to add more fields for extra people would be great.","timestamp":"2008-11-17T12:16:16+00:00","score":2},{"role":"OP","user_id":"anon_44fd86fd966f9ddf","comment_id":"c06eadp","kind":"comment","text":"Thanks! I think I'll add a '+'-button so you can add more people to the list. \n\nBut I was wondering - why do you felt it was dubious at first?","timestamp":"2008-11-17T12:28:01+00:00","score":2},{"role":"answerer","user_id":"anon_482f776db38438b5","comment_id":"c06eaih","kind":"comment","text":"Just because I thought, what's the point, I can divide 458 by 8 if I want to. It was only later I realised its real beauty is it evens out contributions. \n\nOr in other words, the value to me is not splitting a bill in a restaurant, but making it easy to work out whether person A has over-contributed and, if so, how much person B owes him.","timestamp":"2008-11-17T12:43:14+00:00","score":2},{"role":"OP","user_id":"anon_44fd86fd966f9ddf","comment_id":"c06ealy","kind":"comment","text":"In that case I guess we have some work to do. The site was built exactly for the purpose you describe, but apparently it fails to communicate that. I think I'll look into re-wording and re-writing some text to make this more clear.\n\nBut anyway, thanks for the thumbs up! \n\nPS: Did you know we use a fancy algorithm derived from distributed computing to calculate this? The given answer is the optimal solution - the solution where an equilibrium is reached with a minimum number of transactions of minimum size. Cool huh? :D","timestamp":"2008-11-17T12:55:24+00:00","score":5}],"n_turns":5,"n_turns_after_thanks":2,"op_metadata":{"user_id":"anon_44fd86fd966f9ddf","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_482f776db38438b5","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c06eaae","thanks_reply_id":"c06eadp","post_score":0,"answer_score":2,"preferred_answer_is_top_level":true}}
{"user_id":"anon_006ef77e1afdb6c1","answerer_user_id":"anon_8cc312a6c76382c1","subreddit":"programming","timestamp":"2008-12-02T00:45:56+00:00","post_id":"7grhr","question":"So... I got laid off today. Thanks, recession. Any ideas for getting another job again quick?","preferred_answer":"Update your resume, don't just say what you did, also add how it benefited the people you work for. \n\nAre you on linked in? Start digging through dice/monster. Call local recruiters. Start applying with major defense contractors. \n\nAll of this might land you some action before the end of the year, but if it doesn't don't let that get you down, budgets are low this time of year, and there's lots of people with use it or lose it vacation. \n\nSo in the mean time, learn another language. e.g. Python, Clojure, Erlang. Start contributing to an open source project. Volunteer. Relax. Decompress. Read a book.","full_conversation":[{"role":"OP","user_id":"anon_006ef77e1afdb6c1","comment_id":"7grhr","kind":"post","text":"So... I got laid off today. Thanks, recession. Any ideas for getting another job again quick?","timestamp":"2008-12-02T00:45:56+00:00","score":54},{"role":"answerer","user_id":"anon_8cc312a6c76382c1","comment_id":"c06m4gn","kind":"comment","text":"Update your resume, don't just say what you did, also add how it benefited the people you work for. \n\nAre you on linked in? Start digging through dice/monster. Call local recruiters. Start applying with major defense contractors. \n\nAll of this might land you some action before the end of the year, but if it doesn't don't let that get you down, budgets are low this time of year, and there's lots of people with use it or lose it vacation. \n\nSo in the mean time, learn another language. e.g. Python, Clojure, Erlang. Start contributing to an open source project. Volunteer. Relax. Decompress. Read a book.","timestamp":"2008-12-02T02:43:08+00:00","score":14},{"role":"OP","user_id":"anon_006ef77e1afdb6c1","comment_id":"c06m4kx","kind":"comment","text":"Thanks. This is really good advice.\n\n>learn another language. Python, Clojure, Erlang.\n\nRecommendations? I don't know any of those. Where should I start?\n\n>Start contributing to an open source project.\n\nRecommendations?\n\n>Read a book.\n\nRecommendations?\n\n;)","timestamp":"2008-12-02T02:50:12+00:00","score":5},{"role":"answerer","user_id":"anon_8cc312a6c76382c1","comment_id":"c06m5h8","kind":"comment","text":"Language? Python (python.org) is the most practical. Clojure (clojure.org) sounds like the most interesting.\n\nProject? Something that interests you.\n\nBook? beats me. Do you like Stephen King?","timestamp":"2008-12-02T04:25:37+00:00","score":4},{"role":"OP","user_id":"anon_006ef77e1afdb6c1","comment_id":"c06m5l7","kind":"comment","text":"Douglas Adams is my favorite author. I enjoy Robert Asprin, David Sedaris, Kurt Vonnegut, Nick Hornby, Arthur Conan Doyle to name a few.","timestamp":"2008-12-02T04:31:38+00:00","score":2}],"n_turns":5,"n_turns_after_thanks":2,"op_metadata":{"user_id":"anon_006ef77e1afdb6c1","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_8cc312a6c76382c1","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c06m4gn","thanks_reply_id":"c06m4kx","post_score":54,"answer_score":14,"preferred_answer_is_top_level":true}}
{"user_id":"anon_639c3c899d367f32","answerer_user_id":"anon_c8097364d595b4da","subreddit":"programming","timestamp":"2008-12-05T21:00:27+00:00","post_id":"7hnxf","question":"Need help from programming reddit for process watching","preferred_answer":"Take a look at this:\n\nhttp://msdn.microsoft.com/en-us/library/ms257355%28VS.80%29.aspx","full_conversation":[{"role":"OP","user_id":"anon_639c3c899d367f32","comment_id":"7hnxf","kind":"post","text":"Need help from programming reddit for process watching","timestamp":"2008-12-05T21:00:27+00:00","score":0},{"role":"answerer","user_id":"anon_c8097364d595b4da","comment_id":"c06ojfz","kind":"comment","text":"Take a look at this:\n\nhttp://msdn.microsoft.com/en-us/library/ms257355%28VS.80%29.aspx","timestamp":"2008-12-05T21:36:39+00:00","score":2},{"role":"OP","user_id":"anon_639c3c899d367f32","comment_id":"c06ojkk","kind":"comment","text":"This is exactly what I'm doing. The problem is that in order for this to work, you need to put the poll on a loop. Every time the query is run, the CPU usage spikes.","timestamp":"2008-12-05T21:43:02+00:00","score":1},{"role":"answerer","user_id":"anon_c8097364d595b4da","comment_id":"c06okac","kind":"comment","text":"> This is exactly what I'm doing. The problem is that in order for this to work, you need to put the poll on a loop. Every time the query is run, the CPU usage spikes.\n\nIn the example, the program waits for an event, so it shouldn't have to loop. But you can also receive events asynchronously:\n\nhttp://msdn.microsoft.com/en-us/library/ms257360%28VS.80%29.aspx","timestamp":"2008-12-05T22:15:55+00:00","score":2},{"role":"OP","user_id":"anon_639c3c899d367f32","comment_id":"c06oket","kind":"comment","text":"Interestingly enough, this is what I am currently doing after I figured out I needed to watch multiple processes. Go figure :)","timestamp":"2008-12-05T22:21:45+00:00","score":1}],"n_turns":5,"n_turns_after_thanks":2,"op_metadata":{"user_id":"anon_639c3c899d367f32","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_c8097364d595b4da","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c06ojfz","thanks_reply_id":"c06ojkk","post_score":0,"answer_score":2,"preferred_answer_is_top_level":false}}
{"user_id":"anon_d48145299de7952d","answerer_user_id":"anon_7c506be0eeb11814","subreddit":"programming","timestamp":"2008-12-08T18:48:46+00:00","post_id":"7i5ot","question":"Ask Reddit: I need a VPS hosting solution for a small MSSQL Server 2005-based web-app; what are your recommendations?","preferred_answer":"Tektonic or VPSVillage (by GrokThis). Both were fine to work with in my limited experience.","full_conversation":[{"role":"OP","user_id":"anon_d48145299de7952d","comment_id":"7i5ot","kind":"post","text":"Ask Reddit: I need a VPS hosting solution for a small MSSQL Server 2005-based web-app; what are your recommendations?","timestamp":"2008-12-08T18:48:46+00:00","score":0},{"role":"answerer","user_id":"anon_7c506be0eeb11814","comment_id":"c06pztd","kind":"comment","text":"Tektonic or VPSVillage (by GrokThis). Both were fine to work with in my limited experience.","timestamp":"2008-12-08T19:03:28+00:00","score":1},{"role":"OP","user_id":"anon_d48145299de7952d","comment_id":"c06q1kd","kind":"comment","text":"Thanks for the help. Unfortunately I can't use Linux OS's... so nix on the Tektonic and the VPSVillage. :/","timestamp":"2008-12-08T20:25:03+00:00","score":1},{"role":"answerer","user_id":"anon_7c506be0eeb11814","comment_id":"c06q2li","kind":"comment","text":"Ah, sorry, I missed the \"Windows\" in your comment. Anyway, I thought Tektonic did offer Windows VPS, though I have only used Linux there.\n\nedit: it appears that they no longer sell Windows VPS, though they used to. I'm really not sure, you may want to just ask:\n\nhttp://tektonic.net/forum/showthread.php?t=2100","timestamp":"2008-12-08T21:06:30+00:00","score":1},{"role":"OP","user_id":"anon_d48145299de7952d","comment_id":"c06q2m9","kind":"comment","text":"If they do, they've hidden it awfully well.","timestamp":"2008-12-08T21:07:33+00:00","score":1}],"n_turns":5,"n_turns_after_thanks":2,"op_metadata":{"user_id":"anon_d48145299de7952d","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_7c506be0eeb11814","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c06pztd","thanks_reply_id":"c06q1kd","post_score":0,"answer_score":1,"preferred_answer_is_top_level":false}}
{"user_id":"anon_902ef56bf02db2c5","answerer_user_id":"anon_bb5875941fda3d41","subreddit":"programming","timestamp":"2008-12-11T05:15:52+00:00","post_id":"7iqtv","question":"Have they really done it? Scalable transactions?","preferred_answer":"Hi jsnx. I'm one of the developers of P2PS. Unfortunately, the code you downloaded from the site does not contain the transaction layer that Monkeyget mentioned. The students work for the project using the [nightly SVN snapshot](http://gforge.info.ucl.ac.be/scm/?group_id=15). It's true that the documentation is very very thin, but we are actually working on a reimplementation of the whole system, and then we will provide better docs.\n\nAnyway, there are [some slides](http://www.info.ucl.ac.be/Enseignement/Cours/SINF2345/lectures/p2ps.pdf) with a summary of the API that the students used that might help. Transactions are done using the same Paxos-consensus algorithm of Scalaris, which relies on the majority of the peers holding the replicas, with replicated transaction managers as well, so it's more reliable that two-phase commit.\n\ncheers","full_conversation":[{"role":"OP","user_id":"anon_902ef56bf02db2c5","comment_id":"7iqtv","kind":"post","text":"Have they really done it? Scalable transactions?","timestamp":"2008-12-11T05:15:52+00:00","score":26},{"role":"answerer","user_id":"anon_bb5875941fda3d41","comment_id":"1fmq","kind":"comment","text":"Hi jsnx. I'm one of the developers of P2PS. Unfortunately, the code you downloaded from the site does not contain the transaction layer that Monkeyget mentioned. The students work for the project using the [nightly SVN snapshot](http://gforge.info.ucl.ac.be/scm/?group_id=15). It's true that the documentation is very very thin, but we are actually working on a reimplementation of the whole system, and then we will provide better docs.\n\nAnyway, there are [some slides](http://www.info.ucl.ac.be/Enseignement/Cours/SINF2345/lectures/p2ps.pdf) with a summary of the API that the students used that might help. Transactions are done using the same Paxos-consensus algorithm of Scalaris, which relies on the majority of the peers holding the replicas, with replicated transaction managers as well, so it's more reliable that two-phase commit.\n\ncheers","timestamp":"2008-12-20T12:32:42+00:00","score":1},{"role":"OP","user_id":"anon_902ef56bf02db2c5","comment_id":"2cws","kind":"comment","text":"Thank you for the slides -- I've read them with interest. I look forward to learning more about what you are doing.","timestamp":"2008-12-22T05:51:10+00:00","score":1},{"role":"answerer","user_id":"anon_bb5875941fda3d41","comment_id":"2scn","kind":"comment","text":"Good to hear you found it interesting. As I said, we are planning to rebuild the whole system with what we have learned after the first implementation and the feedback from our students working on the project.\n\nWe will update the website of p2ps during january with more information. And we will document more about how transactions are implemented. I gave already some explanation in another reply.\n\ncheers","timestamp":"2008-12-22T22:45:27+00:00","score":1}],"n_turns":4,"n_turns_after_thanks":1,"op_metadata":{"user_id":"anon_902ef56bf02db2c5","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_bb5875941fda3d41","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"1fmq","thanks_reply_id":"2cws","post_score":26,"answer_score":1,"preferred_answer_is_top_level":false}}
{"user_id":"anon_4da22c3369910b7d","answerer_user_id":"anon_792dfb96b27bd18c","subreddit":"programming","timestamp":"2008-12-14T14:24:52+00:00","post_id":"7je9r","question":"AskProgramming: What's the best (free) program to manage code snippets?","preferred_answer":"Don't manage code snippets, study them so you understand what the snippet does, then you can reproduce it whenever you want and (if applicable) in whatever language you want.","full_conversation":[{"role":"OP","user_id":"anon_4da22c3369910b7d","comment_id":"7je9r","kind":"post","text":"AskProgramming: What's the best (free) program to manage code snippets?","timestamp":"2008-12-14T14:24:52+00:00","score":20},{"role":"answerer","user_id":"anon_792dfb96b27bd18c","comment_id":"c06ti67","kind":"comment","text":"Don't manage code snippets, study them so you understand what the snippet does, then you can reproduce it whenever you want and (if applicable) in whatever language you want.","timestamp":"2008-12-14T14:43:57+00:00","score":-2},{"role":"OP","user_id":"anon_4da22c3369910b7d","comment_id":"c06ti6z","kind":"comment","text":"True, but what if I spent an entire afternoon creating the PERFECT regex to check for e-mail addresses? I wouldn't remember it when I needed it again, which is where a code snippets database comes in handy.","timestamp":"2008-12-14T14:46:48+00:00","score":3},{"role":"answerer","user_id":"anon_792dfb96b27bd18c","comment_id":"c06tit5","kind":"comment","text":"That's called bookmarking web sites. If you want to become a decent programmer, you've got to learn what things do and how, not that you have some code somewhere that does what you want.","timestamp":"2008-12-14T15:51:01+00:00","score":-1}],"n_turns":4,"n_turns_after_thanks":1,"op_metadata":{"user_id":"anon_4da22c3369910b7d","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_792dfb96b27bd18c","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c06ti67","thanks_reply_id":"c06ti6z","post_score":20,"answer_score":-2,"preferred_answer_is_top_level":true}}
{"user_id":"anon_78ec39c0adf097f0","answerer_user_id":"anon_48bcfd4617c9cce3","subreddit":"programming","timestamp":"2008-12-17T03:53:42+00:00","post_id":"7jzm0","question":"Can someone recommend a good textbook for learning how to develop web apps?","preferred_answer":"The best way is to pick a programming language you want to use. Then pick one of the predominant web libararies...\n\nPython: Django( http://www.djangoproject.com/ ) Web.py ( http://webpy.org/ ) \n\nRuby: Ruby on Rails ( http://www.rubyonrails.org/ ) \n\nC#: ASP.net ( http://www.asp.net/default.aspx?wwwaspnetrdirset=1 ) \n\nPHP\n\nAll these languages can do very well on their own without the framework but it helps. \n\nFollow one of the many THOUSAND web application tutorials for all of these frameworks and build away. Nothing will help better then a good background in programming though.\n\nGOODLUCK","full_conversation":[{"role":"OP","user_id":"anon_78ec39c0adf097f0","comment_id":"7jzm0","kind":"post","text":"Can someone recommend a good textbook for learning how to develop web apps?","timestamp":"2008-12-17T03:53:42+00:00","score":0},{"role":"answerer","user_id":"anon_48bcfd4617c9cce3","comment_id":"c06v6tn","kind":"comment","text":"The best way is to pick a programming language you want to use. Then pick one of the predominant web libararies...\n\nPython: Django( http://www.djangoproject.com/ ) Web.py ( http://webpy.org/ ) \n\nRuby: Ruby on Rails ( http://www.rubyonrails.org/ ) \n\nC#: ASP.net ( http://www.asp.net/default.aspx?wwwaspnetrdirset=1 ) \n\nPHP\n\nAll these languages can do very well on their own without the framework but it helps. \n\nFollow one of the many THOUSAND web application tutorials for all of these frameworks and build away. Nothing will help better then a good background in programming though.\n\nGOODLUCK","timestamp":"2008-12-17T04:12:46+00:00","score":4},{"role":"OP","user_id":"anon_78ec39c0adf097f0","comment_id":"c06v7nn","kind":"comment","text":"Thanks so much! This is very helpful. I am looking for a way to link blocks of texts using tags.","timestamp":"2008-12-17T05:02:31+00:00","score":0},{"role":"answerer","user_id":"anon_48bcfd4617c9cce3","comment_id":"c06vd0s","kind":"comment","text":"Good luck.","timestamp":"2008-12-17T13:40:46+00:00","score":0}],"n_turns":4,"n_turns_after_thanks":1,"op_metadata":{"user_id":"anon_78ec39c0adf097f0","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_48bcfd4617c9cce3","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c06v6tn","thanks_reply_id":"c06v7nn","post_score":0,"answer_score":4,"preferred_answer_is_top_level":true}}
{"user_id":"anon_7a6825728e62dac9","answerer_user_id":"anon_e666be39437448ca","subreddit":"programming","timestamp":"2008-12-17T17:29:33+00:00","post_id":"7k4k1","question":"OK Reddit, everyone takes the piss out of PHP. What programming language should I learn instead to create web apps?","preferred_answer":"Never mind the language, get something with a better model of programming web applications. Current PHP frameworks show that this seems to be the major problem, they try to use traditional MVC approaches and have to go against the language quite often.\n\nJavaScript should definitely be in your portfolia, as lots of apps nowadays can use nothing but this for most of their user interface, served by a backend (preferably REST) using whatever language you like.\n\nRuby/sinatra would make for a nice backend stack if you want to have a lightweight, rather traditional solution. Java/Hibernate/Spring would be the enterprisey choice, and by having a different frontend you'll avoid the hurt the usual MVC systems encourage. Stuff like Terracotta and NIO is rather great for big applications. Optionally, add clojure for easier wiring.\n\nFor something more mind-blowing, Erlang/Mnesia could definitely be worthwile.","full_conversation":[{"role":"OP","user_id":"anon_7a6825728e62dac9","comment_id":"7k4k1","kind":"post","text":"OK Reddit, everyone takes the piss out of PHP. What programming language should I learn instead to create web apps?","timestamp":"2008-12-17T17:29:33+00:00","score":0},{"role":"answerer","user_id":"anon_e666be39437448ca","comment_id":"c06vi8z","kind":"comment","text":"Never mind the language, get something with a better model of programming web applications. Current PHP frameworks show that this seems to be the major problem, they try to use traditional MVC approaches and have to go against the language quite often.\n\nJavaScript should definitely be in your portfolia, as lots of apps nowadays can use nothing but this for most of their user interface, served by a backend (preferably REST) using whatever language you like.\n\nRuby/sinatra would make for a nice backend stack if you want to have a lightweight, rather traditional solution. Java/Hibernate/Spring would be the enterprisey choice, and by having a different frontend you'll avoid the hurt the usual MVC systems encourage. Stuff like Terracotta and NIO is rather great for big applications. Optionally, add clojure for easier wiring.\n\nFor something more mind-blowing, Erlang/Mnesia could definitely be worthwile.","timestamp":"2008-12-17T18:03:07+00:00","score":1},{"role":"OP","user_id":"anon_7a6825728e62dac9","comment_id":"c06vkac","kind":"comment","text":"Thanks for your comment...\r\n\r\nWe use an MVC approach with PHP in house and i've also used Cake in the past. Your advice is good thought and i'd recommend learning to use an MVC approach to anyone who doesn't.\r\n\r\nI use JavaScript on a day to day basis so that's all good. On top of javascript i'd suggest looking at JQuery which will allow you to build amazing interfaces will very little effort.\r\n\r\nI'm really looking for a server side system.","timestamp":"2008-12-17T19:24:38+00:00","score":1},{"role":"answerer","user_id":"anon_e666be39437448ca","comment_id":"c06vl4y","kind":"comment","text":"I think the two main problems PHP has when you apply it to all parts of MVC is code organization and the execution model. So most frameworks end up using the front controller approach, and either paying the price in performance or going through some loops to ensure that it's still fast enough.\n\nNothing of that is actually inherent in the PHP *language*, but creating some kind of memory-retained application server is an ungrateful task, as this would really not play to PHP's strengths. \n\nUsing some kind of REST backend, retaining state wouldn't actually be neccessary, and with opcode caches you could actually apply enough abstraction without paying a huge price. This would be a good migration path for those shops employing a large number of PHP programmers.\n\nIf it's a backend system for a single person or small team, it's a matter of taste. I'd recommend playing around with some possible solutions. Make a single-page AJAX application, where the backend mainly has to provide JSON or XML messages, maybe a simple shop, a recipe collection or a wiki. Then just recreate the backend with some likely candidates.\n\nA lot of PHP5 programmers are easily able to wrap their minds around Java, as the object-model is pretty similar and it mostly uses the same kinds of loops. The problem is that most books go straight for the heavy-weight environments, which kinda clouds the issue. The MVC frameworks are rather huge, so there's way too much to learn at the beginning. If you're going for a REST approach, use something like Restlet or Jersey, this will make the backend that much easier. Maybe start out with coding the SQL manually in JDB and migrate to Hibernate after everything else comes together.\n\nI've already mentioned Ruby and Sinatra. Coupled with Sequel, this is a really leightweight solution. It almost makes one feel guilty about the size of the code involved... Avoid Rails, as again, this kinda clouds the issue whether the language is suitable or just the framework.\n\nErlang and Mnesia is the odd duck here, some people are kinda enlightened after trying out functional languages, others just don't see the point. It is definitely worth trying, but not as the first option and surely not when you're in a hurry.","timestamp":"2008-12-17T20:00:51+00:00","score":1}],"n_turns":4,"n_turns_after_thanks":1,"op_metadata":{"user_id":"anon_7a6825728e62dac9","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_e666be39437448ca","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c06vi8z","thanks_reply_id":"c06vkac","post_score":0,"answer_score":1,"preferred_answer_is_top_level":true}}
{"user_id":"anon_a10c75bd192d0cb6","answerer_user_id":"anon_c4296d8e193cf31e","subreddit":"programming","timestamp":"2008-12-18T17:49:05+00:00","post_id":"7kda0","question":"Have you made PDF files with hi-dpi images using PHP?","preferred_answer":"I'm not sure how well it handles hi-dpi images, but where I work we use Jasper Reports for all our PDF needs. It's java based, but you just link to the right place and it generates the report automatically. Worth a look.","full_conversation":[{"role":"OP","user_id":"anon_a10c75bd192d0cb6","comment_id":"7kda0","kind":"post","text":"Have you made PDF files with hi-dpi images using PHP?","timestamp":"2008-12-18T17:49:05+00:00","score":0},{"role":"answerer","user_id":"anon_c4296d8e193cf31e","comment_id":"9tw","kind":"comment","text":"I'm not sure how well it handles hi-dpi images, but where I work we use Jasper Reports for all our PDF needs. It's java based, but you just link to the right place and it generates the report automatically. Worth a look.","timestamp":"2008-12-18T17:54:25+00:00","score":1},{"role":"OP","user_id":"anon_a10c75bd192d0cb6","comment_id":"cd4","kind":"comment","text":"Thanks for the pointer but the environment I'm in is bound to PHP. Fun.","timestamp":"2008-12-18T19:43:03+00:00","score":1},{"role":"answerer","user_id":"anon_c4296d8e193cf31e","comment_id":"cgl","kind":"comment","text":"You call the Jasper Report from within PHP, all you need is the Java Path and you're done. [This](http://www.rjohnson.id.au/wordpress/2007/10/27/bullet-proof-jasper-reports-and-php/) has an example, but I don't have time at the moment to hunt for a better one.","timestamp":"2008-12-18T19:47:21+00:00","score":1},{"role":"OP","user_id":"anon_a10c75bd192d0cb6","comment_id":"l7p","kind":"comment","text":"Ended up putting the image into a PDF and using Zend to load it in a put text on top. Thanks for the suggestion but this particular problem is solved.","timestamp":"2008-12-19T02:37:56+00:00","score":1}],"n_turns":5,"n_turns_after_thanks":2,"op_metadata":{"user_id":"anon_a10c75bd192d0cb6","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_c4296d8e193cf31e","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"9tw","thanks_reply_id":"cd4","post_score":0,"answer_score":1,"preferred_answer_is_top_level":false}}
{"user_id":"anon_2dad3a11d57828df","answerer_user_id":"anon_02ea4bb125ae211c","subreddit":"programming","timestamp":"2009-01-08T01:18:14+00:00","post_id":"7o5hv","question":"200 students, divide into 10 classes of 20. Balance for gender, ethnicity, ability level, other factors. How would you do it?","preferred_answer":"Gotcha. This is a well understood problem in experimental design. What you're looking for is called Block Tools: [http://cran.r-project.org/web/packages/blockTools/blockTools.pdf](http://cran.r-project.org/web/packages/blockTools/blockTools.pdf). It's an R package that will create the groups.","full_conversation":[{"role":"OP","user_id":"anon_2dad3a11d57828df","comment_id":"7o5hv","kind":"post","text":"200 students, divide into 10 classes of 20. Balance for gender, ethnicity, ability level, other factors. How would you do it?","timestamp":"2009-01-08T01:18:14+00:00","score":23},{"role":"answerer","user_id":"anon_02ea4bb125ae211c","comment_id":"c06wrl6","kind":"comment","text":"Gotcha. This is a well understood problem in experimental design. What you're looking for is called Block Tools: [http://cran.r-project.org/web/packages/blockTools/blockTools.pdf](http://cran.r-project.org/web/packages/blockTools/blockTools.pdf). It's an R package that will create the groups.","timestamp":"2009-01-08T19:02:21+00:00","score":4},{"role":"OP","user_id":"anon_2dad3a11d57828df","comment_id":"c06wse8","kind":"comment","text":"Thanks dggoldst. Do you have any other references on the underlying technique? I confess I'm not familiar with the domain, so the terminology is a challenge.","timestamp":"2009-01-08T19:29:10+00:00","score":1},{"role":"answerer","user_id":"anon_02ea4bb125ae211c","comment_id":"c06x0d0","kind":"comment","text":"Kefex, sure, check out this paper [\nOptimal multivariate matching before randomization](http://biostatistics.oxfordjournals.org/cgi/reprint/5/2/263) by Greevy, Lu, Silber, & Rosenbaum. It includes a case study. This paper is a very [in depth treatment with examples](http://sekhon.berkeley.edu/papers/MatchingJSS.pdf).","timestamp":"2009-01-08T23:57:14+00:00","score":3}],"n_turns":4,"n_turns_after_thanks":1,"op_metadata":{"user_id":"anon_2dad3a11d57828df","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_02ea4bb125ae211c","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c06wrl6","thanks_reply_id":"c06wse8","post_score":23,"answer_score":4,"preferred_answer_is_top_level":true}}
{"user_id":"anon_86943c5b279b701e","answerer_user_id":"anon_a381963ffe71cc8d","subreddit":"programming","timestamp":"2009-01-14T23:55:46+00:00","post_id":"7ps9w","question":"Which for a newb to learn? I like what I know of Python, but VB would be useful in my work.","preferred_answer":"I agree with that. It's like learning a verbal language, it's hard to do unless you are actively practicing it.","full_conversation":[{"role":"OP","user_id":"anon_86943c5b279b701e","comment_id":"7ps9w","kind":"post","text":"Which for a newb to learn? I like what I know of Python, but VB would be useful in my work.","timestamp":"2009-01-14T23:55:46+00:00","score":0},{"role":"answerer","user_id":"anon_a381963ffe71cc8d","comment_id":"c071lq6","kind":"comment","text":"I agree with that. It's like learning a verbal language, it's hard to do unless you are actively practicing it.","timestamp":"2009-01-15T00:05:06+00:00","score":0},{"role":"OP","user_id":"anon_86943c5b279b701e","comment_id":"c071njc","kind":"comment","text":"Probably VB then. Thanks. \nIt wont ruin my brain will it?","timestamp":"2009-01-15T01:16:20+00:00","score":1},{"role":"answerer","user_id":"anon_a381963ffe71cc8d","comment_id":"c071o8v","kind":"comment","text":"The only problem with using VB is that you can no longer call yourself a programmer.","timestamp":"2009-01-15T01:46:20+00:00","score":2}],"n_turns":4,"n_turns_after_thanks":1,"op_metadata":{"user_id":"anon_86943c5b279b701e","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_a381963ffe71cc8d","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c071lq6","thanks_reply_id":"c071njc","post_score":0,"answer_score":0,"preferred_answer_is_top_level":false}}
{"user_id":"anon_403290e4ffcfabf2","answerer_user_id":"anon_6288347aec11da27","subreddit":"programming","timestamp":"2009-01-19T18:35:50+00:00","post_id":"7qvgt","question":"Can you recommend a book on game physics in 2d?","preferred_answer":"Physics for game developers by Davig Bourg","full_conversation":[{"role":"OP","user_id":"anon_403290e4ffcfabf2","comment_id":"7qvgt","kind":"post","text":"Can you recommend a book on game physics in 2d?","timestamp":"2009-01-19T18:35:50+00:00","score":31},{"role":"answerer","user_id":"anon_6288347aec11da27","comment_id":"c0752yu","kind":"comment","text":"Physics for game developers by Davig Bourg","timestamp":"2009-01-19T19:33:40+00:00","score":7},{"role":"OP","user_id":"anon_403290e4ffcfabf2","comment_id":"c075vla","kind":"comment","text":"I have ordered this book. This is exactly what I was looking for. I am not math addict, so I'll have to learn while I read. A novel idea, huh?","timestamp":"2009-01-20T19:29:50+00:00","score":1},{"role":"answerer","user_id":"anon_6288347aec11da27","comment_id":"c075vmt","kind":"comment","text":"The math is not difficult at all, and is backed up with good old C code. I think we programmers better understand with code.","timestamp":"2009-01-20T19:31:17+00:00","score":1},{"role":"OP","user_id":"anon_403290e4ffcfabf2","comment_id":"c075vpu","kind":"comment","text":"Agreed","timestamp":"2009-01-20T19:33:56+00:00","score":1}],"n_turns":5,"n_turns_after_thanks":2,"op_metadata":{"user_id":"anon_403290e4ffcfabf2","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_6288347aec11da27","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c0752yu","thanks_reply_id":"c075vla","post_score":31,"answer_score":7,"preferred_answer_is_top_level":true}}
{"user_id":"anon_34efc6d3abf4dead","answerer_user_id":"anon_cb3195e852b962aa","subreddit":"programming","timestamp":"2009-01-27T01:23:08+00:00","post_id":"7sn0c","question":"hey reddit, kudos for switching to jQuery, I love it too... but can you please fix Socialite or let the author know that it doesn't longer works?","preferred_answer":"Hey redditor, kudos for using Socialite, I love it too... but can you please spend a bit of time googling or searching on reddit to find out there's a version that works?\n\nhttp://www.reddit.com/r/socialite/comments/7o7xm/socialite_124pre4_released_now_with_full_support/","full_conversation":[{"role":"OP","user_id":"anon_34efc6d3abf4dead","comment_id":"7sn0c","kind":"post","text":"hey reddit, kudos for switching to jQuery, I love it too... but can you please fix Socialite or let the author know that it doesn't longer works?","timestamp":"2009-01-27T01:23:08+00:00","score":2},{"role":"answerer","user_id":"anon_cb3195e852b962aa","comment_id":"c07aluy","kind":"comment","text":"Hey redditor, kudos for using Socialite, I love it too... but can you please spend a bit of time googling or searching on reddit to find out there's a version that works?\n\nhttp://www.reddit.com/r/socialite/comments/7o7xm/socialite_124pre4_released_now_with_full_support/","timestamp":"2009-01-27T03:01:49+00:00","score":0},{"role":"OP","user_id":"anon_34efc6d3abf4dead","comment_id":"c07aw6s","kind":"comment","text":"thanks for you irony, but I searched and don't found anything... anyway thanks for the link","timestamp":"2009-01-27T14:48:05+00:00","score":-1},{"role":"answerer","user_id":"anon_cb3195e852b962aa","comment_id":"c07awot","kind":"comment","text":"Apparently not all that hard:\n\nhttp://flickr.com/photos/wfarr/3230866063/sizes/o/\n\nAlso, down-voting people for stating the blatantly obvious (search before asking)? Is this really what proggit has come to?","timestamp":"2009-01-27T15:12:49+00:00","score":1}],"n_turns":4,"n_turns_after_thanks":1,"op_metadata":{"user_id":"anon_34efc6d3abf4dead","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_cb3195e852b962aa","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c07aluy","thanks_reply_id":"c07aw6s","post_score":2,"answer_score":0,"preferred_answer_is_top_level":true}}
{"user_id":"anon_c198335ca93f3c44","answerer_user_id":"anon_1ba34b81f6f13e75","subreddit":"programming","timestamp":"2009-01-27T17:21:47+00:00","post_id":"7stcv","question":"I'm a developer and I have been programming since 1981, but I learned BASIC first and suck at OOP. What's the best source for total beginner info on Eclipse and Java?","preferred_answer":"OMG... Have you tried Googling it (java and eclipse for total beginners)?? \n\nHere's exactly what you are looking for... Video tutorials.\n\nhttp://eclipsetutorial.sourceforge.net/totalbeginner.html","full_conversation":[{"role":"OP","user_id":"anon_c198335ca93f3c44","comment_id":"7stcv","kind":"post","text":"I'm a developer and I have been programming since 1981, but I learned BASIC first and suck at OOP. What's the best source for total beginner info on Eclipse and Java?","timestamp":"2009-01-27T17:21:47+00:00","score":0},{"role":"answerer","user_id":"anon_1ba34b81f6f13e75","comment_id":"c07bb1t","kind":"comment","text":"OMG... Have you tried Googling it (java and eclipse for total beginners)?? \n\nHere's exactly what you are looking for... Video tutorials.\n\nhttp://eclipsetutorial.sourceforge.net/totalbeginner.html","timestamp":"2009-01-28T00:24:15+00:00","score":2},{"role":"OP","user_id":"anon_c198335ca93f3c44","comment_id":"c07bfnl","kind":"comment","text":"Thanks. I appreciate the urge to get all high and mighty about my apparent lack of ability to google, but I genuinely thought this might be something others would be interested in as well.\n\nApparently not.\n\nEdit: The good news is that my failed submission attempt wasn't a lame Eminem video on youtube and I didn't try submitting it again the first time nobody cared.","timestamp":"2009-01-28T04:02:03+00:00","score":1},{"role":"answerer","user_id":"anon_1ba34b81f6f13e75","comment_id":"c07c3yy","kind":"comment","text":":O ... you really got me there :P. \n\nJust wanted to point you out what first reflex you should probably have as a programmer... Although I understand your point.","timestamp":"2009-01-29T00:46:45+00:00","score":1},{"role":"OP","user_id":"anon_c198335ca93f3c44","comment_id":"c07caon","kind":"comment","text":"<3\n<3\n\nBFF?","timestamp":"2009-01-29T06:40:19+00:00","score":1}],"n_turns":5,"n_turns_after_thanks":2,"op_metadata":{"user_id":"anon_c198335ca93f3c44","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_1ba34b81f6f13e75","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c07bb1t","thanks_reply_id":"c07bfnl","post_score":0,"answer_score":2,"preferred_answer_is_top_level":true}}
{"user_id":"anon_becf7302ab608d5c","answerer_user_id":"anon_1a8905677b5e6d76","subreddit":"programming","timestamp":"2009-02-06T23:54:24+00:00","post_id":"7vi2z","question":"My boss wants to \"hand roll\" his own WSDL file and then have me create a Web Service. I want to create the business logic and have NetBeans create the WSDL. Which one of us is less wrong?","preferred_answer":"I'm bucking the majority opinion here but your boss is saying \"let me specify the interface and you write the service that offers it\" while you are saying \"let me write the service and the interface will fall out of it\".\n\nGiven that it sounds like your your boss knows exactly what the caller needs, I would suggest going his way unless you know for a fact that your generated WSDL is 100% compatible with his requirement.\n\nEDIT: you can compromise (or test) by taking his WSDL and comparing it to what comes out of your generator. If they don't match, he is not the one that's wrong if you catch my drift.","full_conversation":[{"role":"OP","user_id":"anon_becf7302ab608d5c","comment_id":"7vi2z","kind":"post","text":"My boss wants to \"hand roll\" his own WSDL file and then have me create a Web Service. I want to create the business logic and have NetBeans create the WSDL. Which one of us is less wrong?","timestamp":"2009-02-06T23:54:24+00:00","score":0},{"role":"answerer","user_id":"anon_1a8905677b5e6d76","comment_id":"c07itol","kind":"comment","text":"I'm bucking the majority opinion here but your boss is saying \"let me specify the interface and you write the service that offers it\" while you are saying \"let me write the service and the interface will fall out of it\".\n\nGiven that it sounds like your your boss knows exactly what the caller needs, I would suggest going his way unless you know for a fact that your generated WSDL is 100% compatible with his requirement.\n\nEDIT: you can compromise (or test) by taking his WSDL and comparing it to what comes out of your generator. If they don't match, he is not the one that's wrong if you catch my drift.","timestamp":"2009-02-07T02:38:28+00:00","score":7},{"role":"OP","user_id":"anon_becf7302ab608d5c","comment_id":"c07iusp","kind":"comment","text":"Thanks for the replys. I realize you don't have the whole story. Sheesh that would be boring as hell.\r\n\r\nTo clarify. There is an existing EJB.\r\n\r\nHere is the honest to goodness details.\r\n\r\nI am to relay to the boss how the EJB works, it's inputs and outputs.\r\n\r\nHe will create a WSDL.\r\n\r\nI will use the WSDL to create a Web Service (in netbeans) to expose the EJB.\r\n\r\nAll I want to do is right click on the EJB method and say \"create web service\".\r\n\r\nThat is the truth.","timestamp":"2009-02-07T03:41:56+00:00","score":2},{"role":"answerer","user_id":"anon_1a8905677b5e6d76","comment_id":"c07iwvo","kind":"comment","text":"I'm not an expert on the tools but from what you've said, it sounds trivial (<4 hr) to create that service including the WSDL. If so, there is really no harm in including the autogenerated WSDL as part of the documentation that he has requested to specify the actual WSDL. This would also help to identify any differences between what the bean currently does and what he needs it to do.","timestamp":"2009-02-07T05:56:37+00:00","score":1}],"n_turns":4,"n_turns_after_thanks":1,"op_metadata":{"user_id":"anon_becf7302ab608d5c","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_1a8905677b5e6d76","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c07itol","thanks_reply_id":"c07iusp","post_score":0,"answer_score":7,"preferred_answer_is_top_level":true}}
{"user_id":"anon_22d2af7471bf4515","answerer_user_id":"anon_edac16a67be5aa08","subreddit":"programming","timestamp":"2009-02-18T07:32:11+00:00","post_id":"7ya5e","question":"Hey proggit! Can you figure out why curl does not work with this page?","preferred_answer":"Alright, I have it. \n\nThe server is looking for an accept-language header;\n\n Accept-Language: en-us,en;q=0.5\n\nworks for me\n\nEDIT:\n curl -H \"Accept-Language: en-us,en;q=0.5\" http://www.diasorin.com/en/investors/press\ntoo","full_conversation":[{"role":"OP","user_id":"anon_22d2af7471bf4515","comment_id":"7ya5e","kind":"post","text":"Hey proggit! Can you figure out why curl does not work with this page?","timestamp":"2009-02-18T07:32:11+00:00","score":0},{"role":"answerer","user_id":"anon_edac16a67be5aa08","comment_id":"c07qit1","kind":"comment","text":"Alright, I have it. \n\nThe server is looking for an accept-language header;\n\n Accept-Language: en-us,en;q=0.5\n\nworks for me\n\nEDIT:\n curl -H \"Accept-Language: en-us,en;q=0.5\" http://www.diasorin.com/en/investors/press\ntoo","timestamp":"2009-02-18T08:18:59+00:00","score":1},{"role":"OP","user_id":"anon_22d2af7471bf4515","comment_id":"c07qiuw","kind":"comment","text":"Thanks! :D","timestamp":"2009-02-18T08:22:50+00:00","score":1},{"role":"answerer","user_id":"anon_edac16a67be5aa08","comment_id":"c07qpru","kind":"comment","text":"anytime!","timestamp":"2009-02-18T16:20:46+00:00","score":1}],"n_turns":4,"n_turns_after_thanks":1,"op_metadata":{"user_id":"anon_22d2af7471bf4515","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_edac16a67be5aa08","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c07qit1","thanks_reply_id":"c07qiuw","post_score":0,"answer_score":1,"preferred_answer_is_top_level":false}}
{"user_id":"anon_38d374a0227ccbd9","answerer_user_id":"anon_1a477758ff6a5f89","subreddit":"programming","timestamp":"2009-02-18T14:03:30+00:00","post_id":"7ycgs","question":"Noob with no programming experience AT ALL just got a TEENSY USB dev. board. Trying to get it to turn on an LED. Any Redditors feeling mentor-ly today?","preferred_answer":"I would start looking for example projects.\n\nI think they recommend using winavr with it. Never used it but I think it allows you to edit source code and program the device.\n\nhttp://sourceforge.net/project/showfiles.php?group_id=68108\n\nI know you just bought this, but if you want easy you should get an arduino. They have lots of support in the forums. http://arduino.cc\n\n\n\nEDIT: I just noticed you can install some code to the teensy that will let you use it as if it were an arduino.\nhttp://www.pjrc.com/teensy/teensyduino.html","full_conversation":[{"role":"OP","user_id":"anon_38d374a0227ccbd9","comment_id":"7ycgs","kind":"post","text":"Noob with no programming experience AT ALL just got a TEENSY USB dev. board. Trying to get it to turn on an LED. Any Redditors feeling mentor-ly today?","timestamp":"2009-02-18T14:03:30+00:00","score":1},{"role":"answerer","user_id":"anon_1a477758ff6a5f89","comment_id":"c07qn3y","kind":"comment","text":"I would start looking for example projects.\n\nI think they recommend using winavr with it. Never used it but I think it allows you to edit source code and program the device.\n\nhttp://sourceforge.net/project/showfiles.php?group_id=68108\n\nI know you just bought this, but if you want easy you should get an arduino. They have lots of support in the forums. http://arduino.cc\n\n\n\nEDIT: I just noticed you can install some code to the teensy that will let you use it as if it were an arduino.\nhttp://www.pjrc.com/teensy/teensyduino.html","timestamp":"2009-02-18T14:29:02+00:00","score":2},{"role":"OP","user_id":"anon_38d374a0227ccbd9","comment_id":"c07qnkb","kind":"comment","text":"Cool. Thanks. I just noticed the teensyduino myself. Looking into it now...","timestamp":"2009-02-18T14:50:04+00:00","score":2},{"role":"answerer","user_id":"anon_1a477758ff6a5f89","comment_id":"c07rldu","kind":"comment","text":"You should also have a look at these. They're $20 as well.\n\nhttp://en.wikipedia.org/wiki/AVR_Butterfly","timestamp":"2009-02-19T17:41:32+00:00","score":1}],"n_turns":4,"n_turns_after_thanks":1,"op_metadata":{"user_id":"anon_38d374a0227ccbd9","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_1a477758ff6a5f89","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c07qn3y","thanks_reply_id":"c07qnkb","post_score":1,"answer_score":2,"preferred_answer_is_top_level":true}}
{"user_id":"anon_ff0cfe98a5f836d8","answerer_user_id":"anon_fc949df5670da01f","subreddit":"programming","timestamp":"2009-02-27T05:08:23+00:00","post_id":"80o9t","question":"Is there anything on the internet to help me a complete programming noob understand coding?","preferred_answer":"As silly as it sounds, for some basics check out yootoob and googlevideo - after that just do a google search for programming documents (there's actually a whoooooole lot of info out there) If youre still stuck let me know","full_conversation":[{"role":"OP","user_id":"anon_ff0cfe98a5f836d8","comment_id":"80o9t","kind":"post","text":"Is there anything on the internet to help me a complete programming noob understand coding?","timestamp":"2009-02-27T05:08:23+00:00","score":0},{"role":"answerer","user_id":"anon_fc949df5670da01f","comment_id":"c07xbqa","kind":"comment","text":"As silly as it sounds, for some basics check out yootoob and googlevideo - after that just do a google search for programming documents (there's actually a whoooooole lot of info out there) If youre still stuck let me know","timestamp":"2009-02-27T05:13:25+00:00","score":2},{"role":"OP","user_id":"anon_ff0cfe98a5f836d8","comment_id":"c07xc58","kind":"comment","text":"ok thanks alot man I'll give that a try","timestamp":"2009-02-27T05:34:02+00:00","score":0},{"role":"answerer","user_id":"anon_fc949df5670da01f","comment_id":"c07xdv5","kind":"comment","text":"[This might help](http://computer.howstuffworks.com/computer-programming-channel.htm) I'm not too sure what kind of noob you are so this is a pretty basic launchpad for a few different branches of programming. All the best, don't get overwhelmed and if you want someone to do some alpha-testing down the track let me know! (Google alpha testing):P","timestamp":"2009-02-27T07:08:42+00:00","score":1},{"role":"OP","user_id":"anon_ff0cfe98a5f836d8","comment_id":"c07xiwk","kind":"comment","text":"well I'm looking for some one knows visual basic to help with our game","timestamp":"2009-02-27T14:24:35+00:00","score":1}],"n_turns":5,"n_turns_after_thanks":2,"op_metadata":{"user_id":"anon_ff0cfe98a5f836d8","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_fc949df5670da01f","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c07xbqa","thanks_reply_id":"c07xc58","post_score":0,"answer_score":2,"preferred_answer_is_top_level":false}}
{"user_id":"anon_7440fca0edf8d308","answerer_user_id":"anon_1bf4efece1d5423d","subreddit":"programming","timestamp":"2009-03-02T06:06:27+00:00","post_id":"81ce7","question":"JQuery Help Newbie: How To Iterate Table Rows?","preferred_answer":"Yeah, you're right, now that I found his original post. I just read the title of the post, not his comment inside it.\n\nBut hey, you taught me something in your post. Didn't realize I could do it like that.\n\nSo, he needs to find all rows with checked checkboxes in a table, and iterate on those column values.\n\n $('#mytable input:checked').parent().parent().children('TD').each(function() {\n alert('value=' + $(this).val());\n });","full_conversation":[{"role":"OP","user_id":"anon_7440fca0edf8d308","comment_id":"81ce7","kind":"post","text":"JQuery Help Newbie: How To Iterate Table Rows?","timestamp":"2009-03-02T06:06:27+00:00","score":0},{"role":"answerer","user_id":"anon_1bf4efece1d5423d","comment_id":"c07zbj7","kind":"comment","text":"Yeah, you're right, now that I found his original post. I just read the title of the post, not his comment inside it.\n\nBut hey, you taught me something in your post. Didn't realize I could do it like that.\n\nSo, he needs to find all rows with checked checkboxes in a table, and iterate on those column values.\n\n $('#mytable input:checked').parent().parent().children('TD').each(function() {\n alert('value=' + $(this).val());\n });","timestamp":"2009-03-02T06:47:14+00:00","score":2},{"role":"OP","user_id":"anon_7440fca0edf8d308","comment_id":"c0809s7","kind":"comment","text":"Thanks. You were the closest. Here's what I was able to get working:\n\n var updateStatus = function() {\n $('#queue input:checked').parent().parent().each(function() {\n //debugger;\n var id = this.children(1).innerText;\n var type = this.children(2).innerText;\n var amount = this.children(3).innerText;\n var createddtm = this.children(4).innerText;\n this.children(5).innerHTML = \"Processing...\";\n });\n }","timestamp":"2009-03-03T14:25:41+00:00","score":2},{"role":"answerer","user_id":"anon_1bf4efece1d5423d","comment_id":"c080alr","kind":"comment","text":"Excellent. And I guess that's why someone downmodded me to 0? Very strange. Could use a boost, I guess.","timestamp":"2009-03-03T15:07:32+00:00","score":2},{"role":"OP","user_id":"anon_7440fca0edf8d308","comment_id":"c080gfv","kind":"comment","text":"Boosted :) I never care about those things anymore. They used to mean something but now I believe that if people dont like something you have said, they just click your name link, and downmod anything you have posted in the last month, especially if it involves Israel or Palestine :)","timestamp":"2009-03-03T18:44:23+00:00","score":2}],"n_turns":5,"n_turns_after_thanks":2,"op_metadata":{"user_id":"anon_7440fca0edf8d308","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_1bf4efece1d5423d","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c07zbj7","thanks_reply_id":"c0809s7","post_score":0,"answer_score":2,"preferred_answer_is_top_level":false}}
{"user_id":"anon_ad7b742ccd3bfb86","answerer_user_id":"anon_c7065a3407012a8a","subreddit":"programming","timestamp":"2009-03-10T19:51:02+00:00","post_id":"83m8b","question":"shared mutable state but with actors?","preferred_answer":"I think you are conflating two separate issues here. One is the concurrency management and the other is transaction management. Logical transactions need to be operated on together whether you're using message passing or STM. \nYour bank account example has to do with transactions because you're saying one account has to be debited when another account is credited at the same time to preserve the consistency of the system. If the debit or credit fail to occur, then both these operations need to be thrown out or retried as a single unit.\n\nHowever, when you start talking about critical sections, it's a different problem. Here, two separate blocks of code need to use the same resource or to debit the same bank account at precisely the same time. When this situation arises, you have to find a way to make sure that these two processes each get access to the bank account and are able to accomplish their task without conflicting with one another. \n\nCritical sections in the STM are a problem because one thread still has to wait for other threads to release the resource. Yes, STM's handle the locking and releasing of resources for you, but this imposes a significant performance penalty when lots of threads have to wait to sequentially access a common resource.","full_conversation":[{"role":"OP","user_id":"anon_ad7b742ccd3bfb86","comment_id":"83m8b","kind":"post","text":"shared mutable state but with actors?","timestamp":"2009-03-10T19:51:02+00:00","score":0},{"role":"answerer","user_id":"anon_c7065a3407012a8a","comment_id":"c086kdk","kind":"comment","text":"I think you are conflating two separate issues here. One is the concurrency management and the other is transaction management. Logical transactions need to be operated on together whether you're using message passing or STM. \nYour bank account example has to do with transactions because you're saying one account has to be debited when another account is credited at the same time to preserve the consistency of the system. If the debit or credit fail to occur, then both these operations need to be thrown out or retried as a single unit.\n\nHowever, when you start talking about critical sections, it's a different problem. Here, two separate blocks of code need to use the same resource or to debit the same bank account at precisely the same time. When this situation arises, you have to find a way to make sure that these two processes each get access to the bank account and are able to accomplish their task without conflicting with one another. \n\nCritical sections in the STM are a problem because one thread still has to wait for other threads to release the resource. Yes, STM's handle the locking and releasing of resources for you, but this imposes a significant performance penalty when lots of threads have to wait to sequentially access a common resource.","timestamp":"2009-03-12T00:47:01+00:00","score":2},{"role":"OP","user_id":"anon_ad7b742ccd3bfb86","comment_id":"c086lpd","kind":"comment","text":"oh, right, i think that helped! thank you.\n\nso there are some things which are done in shared-mutable-state code that use locks and things which are only there because of the issue of sharing that resource. those locks go away in the actor model because the actor sequences things safely.\n\nwhich doesn't magically take care of 'larger' operations which logically have to go together for some reason -- those would need some kind of transaction in either approach (e.g. mnesia i guess in erlang).","timestamp":"2009-03-12T01:49:31+00:00","score":1},{"role":"answerer","user_id":"anon_c7065a3407012a8a","comment_id":"c0870xs","kind":"comment","text":"You're mostly correct in your description here.\n\nActors don't so much sequence things correctly as they protect their internal state from direct access by other actors. Two threads that want to update an object in memory or to use a resource such as a file handle can only do so indirectly by sending a message. The message recipient changes its internal variables or accesses a resource it manages on behalf of the sender. If the message calls for a response, the recipient will send back a message in reply with updated information after executing such a change.\n\nBecause a message recipient can only do one thing at a time, the operations are sequenced and conflicts are avoided without locks, but there are no ordering guarantees of when an action will execute as a result of a message. An actor simply reads messages from a queue and processes them (out of order processing is not prohibited).\n\nSystems built out of actors can suffer from the same sorts of 'critical region' problems as STMs. If many parts of the system rely on sending messages to one or a few actors to perform some action or actions. Then the sequential processing of messages by that actor becomes a bottleneck to the system. This is no different than an STM-system heavily relying on frequent manipulation to one or several key objects in the system - each change requires those objects to be locked, an action performed, and then unlocked. Actors here should be a bit more efficient because the locking and unlocking can be expensive.","timestamp":"2009-03-12T17:02:00+00:00","score":1},{"role":"OP","user_id":"anon_ad7b742ccd3bfb86","comment_id":"c0876sn","kind":"comment","text":"(yes, by sequence i didn't intend to imply the actor knew anything special about order, only that it prevents the two things from interfering and screwing up the resource. thanks for the clarification.)\n\nso what do people do about multiple-resource coordination in actor systems? just use mnesia?","timestamp":"2009-03-12T20:24:48+00:00","score":1},{"role":"answerer","user_id":"anon_c7065a3407012a8a","comment_id":"c0882fr","kind":"comment","text":"Have a different actor each manage a single resource. Remember in these systems spawning off new threads is fairly cheap.","timestamp":"2009-03-13T23:12:17+00:00","score":1},{"role":"OP","user_id":"anon_ad7b742ccd3bfb86","comment_id":"c089u8m","kind":"comment","text":"sorry, i'm not speaking well - i meant the case that one resource has multiple users to be coordinated e.g. complicated financial transaction, more than the need for lots of actors (because i agree and understand that the actors are meant to be cheap enough).","timestamp":"2009-03-16T20:32:08+00:00","score":1},{"role":"answerer","user_id":"anon_c7065a3407012a8a","comment_id":"c08art7","kind":"comment","text":"In this situation, you do not allow any of your users to interact directly with the shared resource. Instead, you encapsulate the resource by a single actor. All of your users simply send messages to the actor managing the shared resource. The shared resource manager in turn processes incoming messages and makes changes to the resource it protects on behalf of all other actors in the system. It isn't a perfect solution, but it is a bit simpler than the alternative approaches.","timestamp":"2009-03-17T23:20:00+00:00","score":1}],"n_turns":8,"n_turns_after_thanks":5,"op_metadata":{"user_id":"anon_ad7b742ccd3bfb86","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_c7065a3407012a8a","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c086kdk","thanks_reply_id":"c086lpd","post_score":0,"answer_score":2,"preferred_answer_is_top_level":false}}
{"user_id":"anon_339c93c15d8b300d","answerer_user_id":"anon_006ef77e1afdb6c1","subreddit":"programming","timestamp":"2009-03-12T14:55:11+00:00","post_id":"8447k","question":"Apache/Subversion Question: \"svnsync: Error resolving case of: http:\\\\xxx.xxx.xxx\" What does it mean!?","preferred_answer":"Looks like a bad link to me.\n\n1) It's \"http:**//**\".\n\n2) \"http://xxx.xxx.xxx\" is not a valid URL.","full_conversation":[{"role":"OP","user_id":"anon_339c93c15d8b300d","comment_id":"8447k","kind":"post","text":"Apache/Subversion Question: \"svnsync: Error resolving case of: http:\\\\xxx.xxx.xxx\" What does it mean!?","timestamp":"2009-03-12T14:55:11+00:00","score":0},{"role":"answerer","user_id":"anon_006ef77e1afdb6c1","comment_id":"c086xs6","kind":"comment","text":"Looks like a bad link to me.\n\n1) It's \"http:**//**\".\n\n2) \"http://xxx.xxx.xxx\" is not a valid URL.","timestamp":"2009-03-12T15:05:36+00:00","score":3},{"role":"OP","user_id":"anon_339c93c15d8b300d","comment_id":"c086xx6","kind":"comment","text":"heh...heh...I am ashamed. Thanks!","timestamp":"2009-03-12T15:10:37+00:00","score":2},{"role":"answerer","user_id":"anon_006ef77e1afdb6c1","comment_id":"c086xyr","kind":"comment","text":"I do what I can.\n\nINTERNET SUPERHERO AWWAAAAYYYYYYY!!!!!!","timestamp":"2009-03-12T15:12:06+00:00","score":2},{"role":"OP","user_id":"anon_339c93c15d8b300d","comment_id":"c086y5d","kind":"comment","text":"Ok, got another one.\nWhen I try to run the initialization I get:\n>svnsync: Couldn't get lock on destination repos after 10 attempts\n\n\nthey are two completely empty repos so they shouldn't be locked. I ran \n>svn propdel svn:sync-lock --revprop -r 0 \"http://xxx.xxx.xxx.xxx/ \nanyways, but I still get the same error.","timestamp":"2009-03-12T15:19:22+00:00","score":1},{"role":"answerer","user_id":"anon_006ef77e1afdb6c1","comment_id":"c086ygc","kind":"comment","text":"Give these a shot:\n\nsvn pdel --revprop -r 0 svn:sync-lock \n\nsvn pdel --revprop -r 0 svn:sync-lock --username ","timestamp":"2009-03-12T15:30:45+00:00","score":1},{"role":"OP","user_id":"anon_339c93c15d8b300d","comment_id":"c086yr7","kind":"comment","text":"Nada :(","timestamp":"2009-03-12T15:43:08+00:00","score":1},{"role":"answerer","user_id":"anon_006ef77e1afdb6c1","comment_id":"c086yup","kind":"comment","text":"Sorry man. I suggest google.","timestamp":"2009-03-12T15:46:19+00:00","score":1},{"role":"OP","user_id":"anon_339c93c15d8b300d","comment_id":"c086z1p","kind":"comment","text":"The Google let me down. I appreciate the help though :)","timestamp":"2009-03-12T15:53:18+00:00","score":1}],"n_turns":9,"n_turns_after_thanks":6,"op_metadata":{"user_id":"anon_339c93c15d8b300d","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_006ef77e1afdb6c1","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c086xs6","thanks_reply_id":"c086xx6","post_score":0,"answer_score":3,"preferred_answer_is_top_level":true}}
{"user_id":"anon_cfa9d2d3e4c218d1","answerer_user_id":"anon_4c9ba98ecef93998","subreddit":"programming","timestamp":"2009-03-18T11:28:00+00:00","post_id":"85kmv","question":"[Ask Proggit]: Fixed point or integer linear algebra in C/C++?","preferred_answer":"Are you sure this is what you want to do? The GSL is definitely not well optimized (depending on the size of the matrices, try an optimized Lapack/BLAS or something like Eigen2) and dense linear algebra can be very effectively put on a GPU.","full_conversation":[{"role":"OP","user_id":"anon_cfa9d2d3e4c218d1","comment_id":"85kmv","kind":"post","text":"[Ask Proggit]: Fixed point or integer linear algebra in C/C++?","timestamp":"2009-03-18T11:28:00+00:00","score":2},{"role":"answerer","user_id":"anon_4c9ba98ecef93998","comment_id":"c08b3bo","kind":"comment","text":"Are you sure this is what you want to do? The GSL is definitely not well optimized (depending on the size of the matrices, try an optimized Lapack/BLAS or something like Eigen2) and dense linear algebra can be very effectively put on a GPU.","timestamp":"2009-03-18T12:16:54+00:00","score":3},{"role":"OP","user_id":"anon_cfa9d2d3e4c218d1","comment_id":"c08b3qj","kind":"comment","text":"Thanks for the advice. I probably will try GPU at some stage.\n\nThis is a research project so it's a bit pie in the sky and I would like to investigate the FPGA solution as there is also potential for a lot of parallelism.\n\nI like the look of eigen2 though so I will have a look at that. Know anything about [ATLAS](http://math-atlas.sourceforge.net/)?","timestamp":"2009-03-18T12:45:25+00:00","score":1},{"role":"answerer","user_id":"anon_4c9ba98ecef93998","comment_id":"c08b3y7","kind":"comment","text":"ATLAS is okay as a default BLAS/Lapack, but it's performance is pretty bad on recent hardware. For tuned BLAS on x86(-64) look at MKL, ACML, and GOTO. With CUDA there is CUBLAS.\n\nBLAS/Lapack is definitely the wrong way to go for relatively small matrices. Eigen2 is a C++ template library that provides [remarkably](http://eigen.tuxfamily.org/index.php?title=Benchmark) competitive (relative to vendor BLAS) performance for large sizes and usually much better performance for small sizes.\n\nMaybe you can give more details about what you're doing, but from what you've said so far, I think your time would be better spent with CUDA.","timestamp":"2009-03-18T12:59:28+00:00","score":2},{"role":"OP","user_id":"anon_cfa9d2d3e4c218d1","comment_id":"c08b4to","kind":"comment","text":"Thankyou for the comprehensive and awesome advice.\n\nOk. So I have a system to optimise. This requires repeatedly (potentially many billions of iterations) solving a square system Ax=b. It's a dense system.\n\nThe problem I am investigating varies in size from 2x2 - 100x100. At the minute I'm using a QR\\_decomp and QR\\_solve from the GSL.\n\nI'm looking for potential real performance improvements in my simulation setup via a faster linear algebra library or GPU via CUBLAS. This is mostly interesting from a practical perspective as I can run my simulations hella faster.\n\nFrom the research perspective I am interested in a FPGA based solution. There is a lot of parallelism that can be exploited (i.e. solve the linear system many times with different inputs in parallel). This is why I want to try a transformation to fixed point to test the sensitivity of the system to a fixed point transformation and get a handle on potential performance gains.\n\nIs that any clearer? Thanks again for the advice.","timestamp":"2009-03-18T13:46:10+00:00","score":1},{"role":"answerer","user_id":"anon_4c9ba98ecef93998","comment_id":"c08b5im","kind":"comment","text":"I assume the matrices are different each time? If not, you should look into solving multiple right hand sides at once (huge performance gains are possible). If they are different every time, how are you creating them? Why are you using QR? It's more stable but slower than LU. For the small sizes (less than 20 or so) BLAS will typically be quite bad, the implementations just aren't tuned for such sizes.\n\nI'll guess that you can get an order of magnitude improvement by using better algorithms/implementation on your current hardware, and perhaps a couple more orders of magnitude by moving it to a GPU. I'm doubtful that a hypothetical FPGA implementation using fixed-point math would get anywhere close to this.","timestamp":"2009-03-18T14:18:38+00:00","score":2}],"n_turns":6,"n_turns_after_thanks":3,"op_metadata":{"user_id":"anon_cfa9d2d3e4c218d1","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_4c9ba98ecef93998","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c08b3bo","thanks_reply_id":"c08b3qj","post_score":2,"answer_score":3,"preferred_answer_is_top_level":false}}
{"user_id":"anon_47eeb6faede384ac","answerer_user_id":"anon_3c4bbb1749540b6a","subreddit":"programming","timestamp":"2009-03-18T15:30:34+00:00","post_id":"85mln","question":"Ask Proggit: Please give me feedback on my side project, Mancala Time?","preferred_answer":"Absolutely, with so many free flash games sites that don't ask for registration, I wouldn't want to create an account on yours. Permit unregistered playing, but add features for registered users like high scores, stats, and playing against other registered users.","full_conversation":[{"role":"OP","user_id":"anon_47eeb6faede384ac","comment_id":"85mln","kind":"post","text":"Ask Proggit: Please give me feedback on my side project, Mancala Time?","timestamp":"2009-03-18T15:30:34+00:00","score":0},{"role":"answerer","user_id":"anon_3c4bbb1749540b6a","comment_id":"c08bbfo","kind":"comment","text":"Absolutely, with so many free flash games sites that don't ask for registration, I wouldn't want to create an account on yours. Permit unregistered playing, but add features for registered users like high scores, stats, and playing against other registered users.","timestamp":"2009-03-18T18:08:04+00:00","score":2},{"role":"OP","user_id":"anon_47eeb6faede384ac","comment_id":"c08bbvf","kind":"comment","text":"You convinced me. I just added a \"try it\" option. Thanks again for your feedback.","timestamp":"2009-03-18T18:25:14+00:00","score":1},{"role":"answerer","user_id":"anon_3c4bbb1749540b6a","comment_id":"c08bc23","kind":"comment","text":"No problem :) I'm going to try it now ;)","timestamp":"2009-03-18T18:33:03+00:00","score":2}],"n_turns":4,"n_turns_after_thanks":1,"op_metadata":{"user_id":"anon_47eeb6faede384ac","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_3c4bbb1749540b6a","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c08bbfo","thanks_reply_id":"c08bbvf","post_score":0,"answer_score":2,"preferred_answer_is_top_level":false}}
{"user_id":"anon_7ee1d20a9b18d89e","answerer_user_id":"anon_65b5b8a58baa699a","subreddit":"programming","timestamp":"2009-03-20T22:19:39+00:00","post_id":"86ai3","question":"Ask progreddit: can I build an allocator on top of mmap()?","preferred_answer":"http://www.openbsd.org/cgi-bin/cvsweb/src/lib/libc/stdlib/malloc.c?rev=1.115;content-type=text%2Fx-cvsweb-markup this is OpenBSD's new malloc for 4.4 (actually this is the head for 4.5 so there have been evolutions since 4.4 release), there are several calls of mmap (7 through the MMAP and MMAPA macros) in it. I don't know jack about C so I don't know what those mmaps are used for, and if it's only part of the strategy but you can probably understand how it's used by reading the code.","full_conversation":[{"role":"OP","user_id":"anon_7ee1d20a9b18d89e","comment_id":"86ai3","kind":"post","text":"Ask progreddit: can I build an allocator on top of mmap()?","timestamp":"2009-03-20T22:19:39+00:00","score":2},{"role":"answerer","user_id":"anon_65b5b8a58baa699a","comment_id":"c08d1l5","kind":"comment","text":"http://www.openbsd.org/cgi-bin/cvsweb/src/lib/libc/stdlib/malloc.c?rev=1.115;content-type=text%2Fx-cvsweb-markup this is OpenBSD's new malloc for 4.4 (actually this is the head for 4.5 so there have been evolutions since 4.4 release), there are several calls of mmap (7 through the MMAP and MMAPA macros) in it. I don't know jack about C so I don't know what those mmaps are used for, and if it's only part of the strategy but you can probably understand how it's used by reading the code.","timestamp":"2009-03-20T22:29:48+00:00","score":2},{"role":"OP","user_id":"anon_7ee1d20a9b18d89e","comment_id":"c08d1tw","kind":"comment","text":"Thanks, this is why OpenBSD does it this way: http://en.wikipedia.org/wiki/Malloc#OpenBSD.27s_malloc","timestamp":"2009-03-20T22:42:27+00:00","score":2},{"role":"answerer","user_id":"anon_65b5b8a58baa699a","comment_id":"c08d2az","kind":"comment","text":"I note that under that there's a mention of [Hoard's allocator](http://en.wikipedia.org/wiki/Hoard_memory_allocator) which is also based on malloc but is focused on performances. Probably a better source of inspiration for your goal.","timestamp":"2009-03-20T23:04:19+00:00","score":3}],"n_turns":4,"n_turns_after_thanks":1,"op_metadata":{"user_id":"anon_7ee1d20a9b18d89e","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_65b5b8a58baa699a","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c08d1l5","thanks_reply_id":"c08d1tw","post_score":2,"answer_score":2,"preferred_answer_is_top_level":false}}
{"user_id":"anon_f9bd8127d115c7a3","answerer_user_id":"anon_b564eb33caa8100d","subreddit":"programming","timestamp":"2009-03-24T21:33:17+00:00","post_id":"8772f","question":"Is there any way to disable the \"page flow\" bookmark window in Safari 4?","preferred_answer":"It's in the preferences... change the drop down so that new windows and new tabs do not open by default to \"Top Sites\" and then if you want you can also go to View/Customize Toolbar and remove the icon for it from the toolbar as well. Doing those steps effectively removes the feature.","full_conversation":[{"role":"OP","user_id":"anon_f9bd8127d115c7a3","comment_id":"8772f","kind":"post","text":"Is there any way to disable the \"page flow\" bookmark window in Safari 4?","timestamp":"2009-03-24T21:33:17+00:00","score":0},{"role":"answerer","user_id":"anon_b564eb33caa8100d","comment_id":"c08fnyz","kind":"comment","text":"It's in the preferences... change the drop down so that new windows and new tabs do not open by default to \"Top Sites\" and then if you want you can also go to View/Customize Toolbar and remove the icon for it from the toolbar as well. Doing those steps effectively removes the feature.","timestamp":"2009-03-24T21:37:48+00:00","score":2},{"role":"OP","user_id":"anon_f9bd8127d115c7a3","comment_id":"c08fqfr","kind":"comment","text":"MANY THANKS, woodeye! Much appreciated.\n \nReddit rocks. :)","timestamp":"2009-03-24T23:13:27+00:00","score":1},{"role":"answerer","user_id":"anon_b564eb33caa8100d","comment_id":"c08frcu","kind":"comment","text":"You are very much welcome :)","timestamp":"2009-03-24T23:55:49+00:00","score":1}],"n_turns":4,"n_turns_after_thanks":1,"op_metadata":{"user_id":"anon_f9bd8127d115c7a3","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_b564eb33caa8100d","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c08fnyz","thanks_reply_id":"c08fqfr","post_score":0,"answer_score":2,"preferred_answer_is_top_level":true}}
{"user_id":"anon_5eb0f5712d6dea9c","answerer_user_id":"anon_1039a46c82d342ef","subreddit":"programming","timestamp":"2009-03-31T21:35:57+00:00","post_id":"88zyd","question":"Django or Pylons - which should I go for?","preferred_answer":"We at reddit went with Pylons because it was easier to customize. We already knew the problem domain very well and knew exactly what we wanted to do.\n\nIf I were personally starting another site from scratch I'd probably go with Django: better documentation and more support.","full_conversation":[{"role":"OP","user_id":"anon_5eb0f5712d6dea9c","comment_id":"88zyd","kind":"post","text":"Django or Pylons - which should I go for?","timestamp":"2009-03-31T21:35:57+00:00","score":27},{"role":"answerer","user_id":"anon_1039a46c82d342ef","comment_id":"c08l0dp","kind":"comment","text":"We at reddit went with Pylons because it was easier to customize. We already knew the problem domain very well and knew exactly what we wanted to do.\n\nIf I were personally starting another site from scratch I'd probably go with Django: better documentation and more support.","timestamp":"2009-03-31T22:12:12+00:00","score":37},{"role":"OP","user_id":"anon_5eb0f5712d6dea9c","comment_id":"c08l0og","kind":"comment","text":"Thanks for the input - you don't think Django is overly 'bloated' then?\n\nEdit: This question is based on an article I read that stated too much is being put in to make things too simple.","timestamp":"2009-03-31T22:24:43+00:00","score":1},{"role":"answerer","user_id":"anon_1039a46c82d342ef","comment_id":"c08l1h5","kind":"comment","text":"Yes, I do think Django is overly complex, but I think it depends on the nature of the project whether that is a bad thing. If you already know what you're doing, it'll just get in your way. If you're just starting out, it might save you some time.","timestamp":"2009-03-31T22:57:28+00:00","score":3}],"n_turns":4,"n_turns_after_thanks":1,"op_metadata":{"user_id":"anon_5eb0f5712d6dea9c","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_1039a46c82d342ef","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c08l0dp","thanks_reply_id":"c08l0og","post_score":27,"answer_score":37,"preferred_answer_is_top_level":true}}
{"user_id":"anon_ad7b742ccd3bfb86","answerer_user_id":"anon_7c506be0eeb11814","subreddit":"programming","timestamp":"2009-04-03T18:17:39+00:00","post_id":"89scp","question":"best syntax extension approach?","preferred_answer":"Also things like Katahdin:\n\nhttp://www.chrisseaton.com/katahdin/","full_conversation":[{"role":"OP","user_id":"anon_ad7b742ccd3bfb86","comment_id":"89scp","kind":"post","text":"best syntax extension approach?","timestamp":"2009-04-03T18:17:39+00:00","score":1},{"role":"answerer","user_id":"anon_7c506be0eeb11814","comment_id":"c08myg6","kind":"comment","text":"Also things like Katahdin:\n\nhttp://www.chrisseaton.com/katahdin/","timestamp":"2009-04-03T19:05:33+00:00","score":2},{"role":"OP","user_id":"anon_ad7b742ccd3bfb86","comment_id":"c08n36j","kind":"comment","text":"hah! thanks, i was looking for that (couldn't recall the name) before posting on reddit :-)","timestamp":"2009-04-03T21:58:28+00:00","score":1},{"role":"answerer","user_id":"anon_7c506be0eeb11814","comment_id":"c08n724","kind":"comment","text":"One of these days (*shakes fist*) I finally will port that awesome project from C# to Java.","timestamp":"2009-04-04T01:16:00+00:00","score":1}],"n_turns":4,"n_turns_after_thanks":1,"op_metadata":{"user_id":"anon_ad7b742ccd3bfb86","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_7c506be0eeb11814","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c08myg6","thanks_reply_id":"c08n36j","post_score":1,"answer_score":2,"preferred_answer_is_top_level":false}}
{"user_id":"anon_a5a1c9eb6ed98a60","answerer_user_id":"anon_28a42d0528feef73","subreddit":"programming","timestamp":"2009-04-06T03:57:40+00:00","post_id":"8a9bi","question":"Any tips for finding programming work using Elance, Guru, etc?","preferred_answer":"bid low :D","full_conversation":[{"role":"OP","user_id":"anon_a5a1c9eb6ed98a60","comment_id":"8a9bi","kind":"post","text":"Any tips for finding programming work using Elance, Guru, etc?","timestamp":"2009-04-06T03:57:40+00:00","score":0},{"role":"answerer","user_id":"anon_28a42d0528feef73","comment_id":"c08oke8","kind":"comment","text":"bid low :D","timestamp":"2009-04-06T10:32:50+00:00","score":1},{"role":"OP","user_id":"anon_a5a1c9eb6ed98a60","comment_id":"c08okhk","kind":"comment","text":"The bar seems to be set pretty low already thanks to competition from outside the US.","timestamp":"2009-04-06T10:41:21+00:00","score":3},{"role":"answerer","user_id":"anon_28a42d0528feef73","comment_id":"c08ov8x","kind":"comment","text":"well, what with the population of the US being less than 5% of the world population, that's to be expected.. :D\n\n[http://en.wikipedia.org/wiki/World_population](http://en.wikipedia.org/wiki/World_population)\n\nand hard as that may be, that's just natural behavior for any marketplace, at least for an auction house, unless someone comes up with better system/scales that can measure and reward your work by its quality..","timestamp":"2009-04-06T19:17:21+00:00","score":1},{"role":"OP","user_id":"anon_a5a1c9eb6ed98a60","comment_id":"c08owku","kind":"comment","text":"Well, until then I'm stuck with the problem of how to pay my bills :)","timestamp":"2009-04-06T20:03:49+00:00","score":1}],"n_turns":5,"n_turns_after_thanks":2,"op_metadata":{"user_id":"anon_a5a1c9eb6ed98a60","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_28a42d0528feef73","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c08oke8","thanks_reply_id":"c08okhk","post_score":0,"answer_score":1,"preferred_answer_is_top_level":true}}
{"user_id":"anon_71ec151aabcd9b22","answerer_user_id":"anon_eba93e5811cc57b1","subreddit":"programming","timestamp":"2009-04-07T21:10:02+00:00","post_id":"8arks","question":"Ask Proggit: Is a computer science degree really worth it?","preferred_answer":"I guess it's not really fair, but so far it's worked to my advantage. I have a CS degree, but I've never had much passion for programming. An impressive-looking degree is my only edge.","full_conversation":[{"role":"OP","user_id":"anon_71ec151aabcd9b22","comment_id":"8arks","kind":"post","text":"Ask Proggit: Is a computer science degree really worth it?","timestamp":"2009-04-07T21:10:02+00:00","score":0},{"role":"answerer","user_id":"anon_eba93e5811cc57b1","comment_id":"c08ptv2","kind":"comment","text":"I guess it's not really fair, but so far it's worked to my advantage. I have a CS degree, but I've never had much passion for programming. An impressive-looking degree is my only edge.","timestamp":"2009-04-07T22:00:27+00:00","score":2},{"role":"OP","user_id":"anon_71ec151aabcd9b22","comment_id":"c08pv9g","kind":"comment","text":"This is exactly my point. Shouldn't someone who absolutely loves programming, and who's just as good or better, be the one with your job, regardless of whether or not they dealt with college?","timestamp":"2009-04-07T22:58:56+00:00","score":2},{"role":"answerer","user_id":"anon_eba93e5811cc57b1","comment_id":"c08pw51","kind":"comment","text":"The \"... or better\" part is what should determine whether someone else should be the one with my job, not how much anyone loves programming. Anyway, I doubt anyone who really loves programming and is really good at it would want my job. It isn't that much programming, and the pay is mediocre. A degree can only get me so far.","timestamp":"2009-04-07T23:39:02+00:00","score":2}],"n_turns":4,"n_turns_after_thanks":1,"op_metadata":{"user_id":"anon_71ec151aabcd9b22","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_eba93e5811cc57b1","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c08ptv2","thanks_reply_id":"c08pv9g","post_score":0,"answer_score":2,"preferred_answer_is_top_level":false}}
{"user_id":"anon_1c3e2b625ba482c4","answerer_user_id":"anon_d31809b974ecb66a","subreddit":"programming","timestamp":"2009-04-09T17:35:21+00:00","post_id":"8bag7","question":"In The Game of Life, what is the minimum number of logic gates needed to implement a cell?","preferred_answer":"The author has put your solution in the article now, although he spelt the domain name wrong so it goes to a parked page.","full_conversation":[{"role":"OP","user_id":"anon_1c3e2b625ba482c4","comment_id":"8bag7","kind":"post","text":"In The Game of Life, what is the minimum number of logic gates needed to implement a cell?","timestamp":"2009-04-09T17:35:21+00:00","score":113},{"role":"answerer","user_id":"anon_d31809b974ecb66a","comment_id":"c08reca","kind":"comment","text":"The author has put your solution in the article now, although he spelt the domain name wrong so it goes to a parked page.","timestamp":"2009-04-09T21:26:18+00:00","score":15},{"role":"OP","user_id":"anon_1c3e2b625ba482c4","comment_id":"c08rhzx","kind":"comment","text":"thanks for the notice...ill fix it right now. Have some pity on the typography of a 36 hour unrested brain!","timestamp":"2009-04-10T00:05:04+00:00","score":9},{"role":"answerer","user_id":"anon_d31809b974ecb66a","comment_id":"c08rigf","kind":"comment","text":"Never.","timestamp":"2009-04-10T00:29:01+00:00","score":9}],"n_turns":4,"n_turns_after_thanks":1,"op_metadata":{"user_id":"anon_1c3e2b625ba482c4","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_d31809b974ecb66a","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c08reca","thanks_reply_id":"c08rhzx","post_score":113,"answer_score":15,"preferred_answer_is_top_level":false}}
{"user_id":"anon_04ab3e1ecefb19a5","answerer_user_id":"anon_4e4e728826ad7887","subreddit":"programming","timestamp":"2009-04-17T08:10:31+00:00","post_id":"8d6oq","question":"Dear Reddit, I made this site to share our best stories \"anonymously\", What do you think?","preferred_answer":"Priblo title","full_conversation":[{"role":"OP","user_id":"anon_04ab3e1ecefb19a5","comment_id":"8d6oq","kind":"post","text":"Dear Reddit, I made this site to share our best stories \"anonymously\", What do you think?","timestamp":"2009-04-17T08:10:31+00:00","score":5},{"role":"answerer","user_id":"anon_4e4e728826ad7887","comment_id":"c08x1bn","kind":"comment","text":"Priblo title","timestamp":"2009-04-17T12:32:51+00:00","score":1},{"role":"OP","user_id":"anon_04ab3e1ecefb19a5","comment_id":"c08x1fr","kind":"comment","text":"Thank you very much, took me a while to notice the missing 'r'!","timestamp":"2009-04-17T12:39:23+00:00","score":2},{"role":"answerer","user_id":"anon_4e4e728826ad7887","comment_id":"c08x39y","kind":"comment","text":"No worries, good luck with the site.","timestamp":"2009-04-17T14:07:45+00:00","score":1}],"n_turns":4,"n_turns_after_thanks":1,"op_metadata":{"user_id":"anon_04ab3e1ecefb19a5","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_4e4e728826ad7887","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c08x1bn","thanks_reply_id":"c08x1fr","post_score":5,"answer_score":1,"preferred_answer_is_top_level":false}}
{"user_id":"anon_1b11757d33424678","answerer_user_id":"anon_6637ebfe82795078","subreddit":"programming","timestamp":"2009-04-23T05:49:30+00:00","post_id":"8eqon","question":"Q: High-level concepts behind j2ee application scaling?","preferred_answer":"This is not a direct answer to your question. But when you want to understand the JEE basics you need to go beyond the 'product level' (yes, JEE *is a* SUN product) and the product's marketing.\n\n* Entity Beans: Look for the theory of 'distibuted objects' and CORBA. EntityBeans failed for the same reasons as CORBA, just in the JAVA way.\n\n* Session Beans: Get some information about Transaction Monitors (TM). SessionBeans are a SUN's mostly misunderstood (and mis-communicated) way of providing TM functionality in server-side JAVA. SessionBeans are the best part of EJB. \n\n* A Message-Driven Beans: Message-Oriented Middleware (MOM) is the theory behind it. \n\n\nThe remaining pieces, esp. Servlets ('Web-Containers') are more accessible since there are many competitors (ASP, PHP, even RoR). Servlets offer superior enterprise functionality. \n\nP.S.: Don't be fooled by free-riders like 'Spring' which pretend to offer their own enterprise 'full stack' in Java.","full_conversation":[{"role":"OP","user_id":"anon_1b11757d33424678","comment_id":"8eqon","kind":"post","text":"Q: High-level concepts behind j2ee application scaling?","timestamp":"2009-04-23T05:49:30+00:00","score":0},{"role":"answerer","user_id":"anon_6637ebfe82795078","comment_id":"c0929uf","kind":"comment","text":"This is not a direct answer to your question. But when you want to understand the JEE basics you need to go beyond the 'product level' (yes, JEE *is a* SUN product) and the product's marketing.\n\n* Entity Beans: Look for the theory of 'distibuted objects' and CORBA. EntityBeans failed for the same reasons as CORBA, just in the JAVA way.\n\n* Session Beans: Get some information about Transaction Monitors (TM). SessionBeans are a SUN's mostly misunderstood (and mis-communicated) way of providing TM functionality in server-side JAVA. SessionBeans are the best part of EJB. \n\n* A Message-Driven Beans: Message-Oriented Middleware (MOM) is the theory behind it. \n\n\nThe remaining pieces, esp. Servlets ('Web-Containers') are more accessible since there are many competitors (ASP, PHP, even RoR). Servlets offer superior enterprise functionality. \n\nP.S.: Don't be fooled by free-riders like 'Spring' which pretend to offer their own enterprise 'full stack' in Java.","timestamp":"2009-04-23T20:05:40+00:00","score":1},{"role":"OP","user_id":"anon_1b11757d33424678","comment_id":"c092k8m","kind":"comment","text":"Hey thanks, pointer2void! I will (try to) look at what you've suggested above but I'm not sure any theory/text would also include a critique of the subject; usually, they advocate what they, well, advocate. I'll google on my own but would appreciate if you have any ready links (good ones) to share.\n\n> P.S.: Don't be fooled by free-riders like 'Spring' which ...\n\nWhere could I find more info on this... so that I can avoid being fooled?","timestamp":"2009-04-24T02:29:38+00:00","score":1},{"role":"answerer","user_id":"anon_6637ebfe82795078","comment_id":"c09346h","kind":"comment","text":"> Where could I find more info on this...\n\nhttp://www.web4j.com/Criticisms_Drawbacks_Pitfalls_Spring_Rails_PHP.jsp#Spring","timestamp":"2009-04-24T18:50:48+00:00","score":2}],"n_turns":4,"n_turns_after_thanks":1,"op_metadata":{"user_id":"anon_1b11757d33424678","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_6637ebfe82795078","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c0929uf","thanks_reply_id":"c092k8m","post_score":0,"answer_score":1,"preferred_answer_is_top_level":false}}
{"user_id":"anon_d971b2a410d27123","answerer_user_id":"anon_79cdf5f7f8872e63","subreddit":"programming","timestamp":"2009-04-25T20:35:44+00:00","post_id":"8fgb7","question":"help me","preferred_answer":"A couple of points here: What language do you want/need. How much work would you like to see? Is pseudo code ok?","full_conversation":[{"role":"OP","user_id":"anon_d971b2a410d27123","comment_id":"8fgb7","kind":"post","text":"help me","timestamp":"2009-04-25T20:35:44+00:00","score":0},{"role":"answerer","user_id":"anon_79cdf5f7f8872e63","comment_id":"c093yde","kind":"comment","text":"A couple of points here: What language do you want/need. How much work would you like to see? Is pseudo code ok?","timestamp":"2009-04-25T20:44:24+00:00","score":0},{"role":"OP","user_id":"anon_d971b2a410d27123","comment_id":"c093ygx","kind":"comment","text":"first of all thanks for the serious reply, now as i said i have no idea about this stuff. I need whatever code it is maxima runs naturally, i dont know what that is, also i have no idea what pseudo code is, sorry but again thanks","timestamp":"2009-04-25T20:49:06+00:00","score":1},{"role":"answerer","user_id":"anon_79cdf5f7f8872e63","comment_id":"c093yzf","kind":"comment","text":"Hrm...well maybe this will get you started. (Since it seems you don't want it, I won't give you the full answer, but a little description)\n\nWe need to first figure out what a Taylor Expansion is. So we know \n\n1 + x^1 / 1! + x^2 / 2! + x^3 / 3! ...\n\nSo, now we need to look at arctan:\n\narctan(x) = x - x3/3 + x5/5 - x7/7 + .... \n\nRight?\n\nSo that should get you on your way...\n\n* edit why the down mods?","timestamp":"2009-04-25T21:13:31+00:00","score":0}],"n_turns":4,"n_turns_after_thanks":1,"op_metadata":{"user_id":"anon_d971b2a410d27123","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_79cdf5f7f8872e63","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c093yde","thanks_reply_id":"c093ygx","post_score":0,"answer_score":0,"preferred_answer_is_top_level":false}}
{"user_id":"anon_85d28e608c5e3fd8","answerer_user_id":"anon_3592c0e1f116e6a6","subreddit":"programming","timestamp":"2009-05-04T12:54:08+00:00","post_id":"8hot7","question":"We spend 1000s of hours building Mozilla/OpenOffice/Ubuntu because we \"hate\" Microsoft - yet we all pay exorbitant taxes which the Govt squanders on ineffective healthcare systems projects - diverting moneyfrom treatment that we will all need. Where the hell is OpenSourceMedicalDatabase.org?","preferred_answer":"http://thebrainproject.org/2008-11-21.asp","full_conversation":[{"role":"OP","user_id":"anon_85d28e608c5e3fd8","comment_id":"8hot7","kind":"post","text":"We spend 1000s of hours building Mozilla/OpenOffice/Ubuntu because we \"hate\" Microsoft - yet we all pay exorbitant taxes which the Govt squanders on ineffective healthcare systems projects - diverting moneyfrom treatment that we will all need. Where the hell is OpenSourceMedicalDatabase.org?","timestamp":"2009-05-04T12:54:08+00:00","score":0},{"role":"answerer","user_id":"anon_3592c0e1f116e6a6","comment_id":"c09bequ","kind":"comment","text":"http://thebrainproject.org/2008-11-21.asp","timestamp":"2009-05-04T13:20:23+00:00","score":1},{"role":"OP","user_id":"anon_85d28e608c5e3fd8","comment_id":"c09bfbx","kind":"comment","text":"Thanks - that's a very specific project however in terms of scale. I'm thinking of open-source building the infrastructure required for patient records, prescriptions, drug interactions, treatment records, medicare, private insurance etc etc across the whole gamut of health care services - basically replacing \"white elephant\" public sector overspends that are sapping the lifeblood from public budgets with few results.","timestamp":"2009-05-04T13:48:28+00:00","score":1},{"role":"answerer","user_id":"anon_3592c0e1f116e6a6","comment_id":"c09bh3r","kind":"comment","text":"I figured you meant something more general, but I thought I'd point out that anyway. It was the result of \"googling\": OpenSourceMedicalDatabase.org","timestamp":"2009-05-04T15:07:13+00:00","score":1}],"n_turns":4,"n_turns_after_thanks":1,"op_metadata":{"user_id":"anon_85d28e608c5e3fd8","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_3592c0e1f116e6a6","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c09bequ","thanks_reply_id":"c09bfbx","post_score":0,"answer_score":1,"preferred_answer_is_top_level":true}}
{"user_id":"anon_929b893172cbc1a9","answerer_user_id":"anon_0707b2fa944f540a","subreddit":"programming","timestamp":"2009-05-06T16:48:50+00:00","post_id":"8id0y","question":"Hey programming - I want to teach myself enough to create a decent website. Is this the book? Is it even the right language?","preferred_answer":"Java, to create a website?\nNO.. While Java can be used to script a website, its really not the best solution. In-fact very few web host support Java nowadays. Java for web should only be used as a front-end for a much more complex program.\n\nAnyways you want to start out with HTML, once you've got that down, you want to work with a web language. You could go with PHP or Ruby, or Python, or a number of languages. But Java, not unless you already know it..","full_conversation":[{"role":"OP","user_id":"anon_929b893172cbc1a9","comment_id":"8id0y","kind":"post","text":"Hey programming - I want to teach myself enough to create a decent website. Is this the book? Is it even the right language?","timestamp":"2009-05-06T16:48:50+00:00","score":0},{"role":"answerer","user_id":"anon_0707b2fa944f540a","comment_id":"c09djs4","kind":"comment","text":"Java, to create a website?\nNO.. While Java can be used to script a website, its really not the best solution. In-fact very few web host support Java nowadays. Java for web should only be used as a front-end for a much more complex program.\n\nAnyways you want to start out with HTML, once you've got that down, you want to work with a web language. You could go with PHP or Ruby, or Python, or a number of languages. But Java, not unless you already know it..","timestamp":"2009-05-06T16:54:33+00:00","score":5},{"role":"OP","user_id":"anon_929b893172cbc1a9","comment_id":"c09dk2h","kind":"comment","text":"Thanks very much, excuse my ignorance. Can I build a website in HTML alone, or do I need one of those other programs too?\n\nAnd is there a book for starters in HTML you could recommend?","timestamp":"2009-05-06T17:03:36+00:00","score":1},{"role":"answerer","user_id":"anon_0707b2fa944f540a","comment_id":"c09dko7","kind":"comment","text":"Ekk. Yes, start with HTML. No I can't recommend any good books really. One of the quickest ways to learn HTML is to take an existing website that you like the look of. And do a Page Save (in firefox file menu). Or Save As, Webpage Complete in IE.\nThen open the .htm file in a text editor (NOT word, something like notepad or wordpad) and make changes and see how those changes affect the page. Use a basic reference guide like http://www.w3schools.com/tags/default.asp to find out what each tag does.\nThere are plenty of good HTML books out there, though I can't recommend any off hand.","timestamp":"2009-05-06T17:21:29+00:00","score":1}],"n_turns":4,"n_turns_after_thanks":1,"op_metadata":{"user_id":"anon_929b893172cbc1a9","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_0707b2fa944f540a","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c09djs4","thanks_reply_id":"c09dk2h","post_score":0,"answer_score":5,"preferred_answer_is_top_level":true}}
{"user_id":"anon_e20acf412ec5d94f","answerer_user_id":"anon_b7ff7d1b685f56c5","subreddit":"programming","timestamp":"2009-05-09T16:22:35+00:00","post_id":"8j60s","question":"Where to learn computer science - I'm a self taught ASP.NET programmer w/ 7yrs experience","preferred_answer":"Well, I learned it in a classroom, so I'm not sure what's most useful for self-learning. The wikipedia article (http://en.wikipedia.org/wiki/Big_O_notation) is a bit too abstract and formal for a beginner, IMO.\n\nBasically, saying that one function is big-O another function (looks like \"f(n) ∈ O(g(n))\") means that as n gets big, f(n) and g(n) increase similarly, after ignoring all kinds of things that are actually important such as constant multipliers (so f can be 100 times slower than g, but if it goes up in the same way, it's still in the order of g). So if a particular method takes the same amount of time no matter much data you feed it (such as array lookups), one might say that it's O(1). If it takes an amount of time that goes up according to a constant factor of the input size (like putting something at the end of a linked list), then you write that it's O(n). If doubling the input size makes it take 4 times as long, then it's O(n^2).\n\nhttp://mitpress.mit.edu/algorithms/ is a fantastic reference, but I don't think I'd be able to learn directly from it. There's also a lot of algorithm/data structures books written to take advantage of particular programming environments, but googling around doens't turn up any for C# or VB.NET, which is what I assume you're used to if you did ASP.NET. But there are a few for Java, which is almost the same as .NET. Sedgewick's \"Algorithms in Java\" has pretty good explanations of the math, but the code samples are all shite. They make you really aware that he's a C programmer :) But if you can figure them out, it's a decent text.\n\nYou could also try a local college/community college, depending where you are. This kind of stuff is usually covered in a sophomore course at state schools, or really early at fancy places like MIT.\n\nBest of luck! Feel free to msg me with any questions you come across. I've not done much with .NET, but I can do the other stuff :)","full_conversation":[{"role":"OP","user_id":"anon_e20acf412ec5d94f","comment_id":"8j60s","kind":"post","text":"Where to learn computer science - I'm a self taught ASP.NET programmer w/ 7yrs experience","timestamp":"2009-05-09T16:22:35+00:00","score":30},{"role":"answerer","user_id":"anon_b7ff7d1b685f56c5","comment_id":"c09hdhi","kind":"comment","text":"Well, I learned it in a classroom, so I'm not sure what's most useful for self-learning. The wikipedia article (http://en.wikipedia.org/wiki/Big_O_notation) is a bit too abstract and formal for a beginner, IMO.\n\nBasically, saying that one function is big-O another function (looks like \"f(n) ∈ O(g(n))\") means that as n gets big, f(n) and g(n) increase similarly, after ignoring all kinds of things that are actually important such as constant multipliers (so f can be 100 times slower than g, but if it goes up in the same way, it's still in the order of g). So if a particular method takes the same amount of time no matter much data you feed it (such as array lookups), one might say that it's O(1). If it takes an amount of time that goes up according to a constant factor of the input size (like putting something at the end of a linked list), then you write that it's O(n). If doubling the input size makes it take 4 times as long, then it's O(n^2).\n\nhttp://mitpress.mit.edu/algorithms/ is a fantastic reference, but I don't think I'd be able to learn directly from it. There's also a lot of algorithm/data structures books written to take advantage of particular programming environments, but googling around doens't turn up any for C# or VB.NET, which is what I assume you're used to if you did ASP.NET. But there are a few for Java, which is almost the same as .NET. Sedgewick's \"Algorithms in Java\" has pretty good explanations of the math, but the code samples are all shite. They make you really aware that he's a C programmer :) But if you can figure them out, it's a decent text.\n\nYou could also try a local college/community college, depending where you are. This kind of stuff is usually covered in a sophomore course at state schools, or really early at fancy places like MIT.\n\nBest of luck! Feel free to msg me with any questions you come across. I've not done much with .NET, but I can do the other stuff :)","timestamp":"2009-05-11T07:14:03+00:00","score":2},{"role":"OP","user_id":"anon_e20acf412ec5d94f","comment_id":"c09hejs","kind":"comment","text":"Thanks a ton. I might take you up on the msg bit!","timestamp":"2009-05-11T08:41:23+00:00","score":1},{"role":"answerer","user_id":"anon_b7ff7d1b685f56c5","comment_id":"c09hewl","kind":"comment","text":"Do it!","timestamp":"2009-05-11T09:15:41+00:00","score":1}],"n_turns":4,"n_turns_after_thanks":1,"op_metadata":{"user_id":"anon_e20acf412ec5d94f","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_b7ff7d1b685f56c5","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c09hdhi","thanks_reply_id":"c09hejs","post_score":30,"answer_score":2,"preferred_answer_is_top_level":false}}
{"user_id":"anon_a838925267355ffd","answerer_user_id":"anon_7d2df2d31213df13","subreddit":"programming","timestamp":"2009-05-14T07:06:12+00:00","post_id":"8kd0c","question":"Hey Proggit, I have an option of either learning Adobe Flex or Qt. Which would you suggest and Why?","preferred_answer":"While I prefer Air/Flex to my other options for GUI development these days, it's for rapid-application development reasons and not for the quality of the code the framework encouarges. Qt is the singular nicest to use and best designed desktop GUI framework I've used. And I've used a lot.\n\nSo if you want to:\n - get a job as a 'web dude' just learn Flex/Air\n\n - get a job in visual effects or doing heavy 3D modeling like solidworks, learn PyQt\n\n - observe and use good programming techniques of the framework to improve your own coding skills and to better understand how a proper MVC framework should work use Qt/C++\n\n - rapidly develop an internet-services-centric, glitzy GUI use Air/Flex\n\n - observe and use good programming techniques of the framework to improve your own coding skills and to better understand how a proper aysnchronous/event-based GUI coding works, use PyQt\n\n - if you answered \"Yes\" to all of the above, pick a target problem - say 'yet another twitter client' and implement it first in PyQt. Then re-implement that same application in Flex/Air plus a good MVC framework like PureMVC and/or Cairngorn. \n\nI'd suggest the last option frankly. Flex is BRILLIANT but out of the box it encourages very messy, very tightly-coupled code that will quickly grow unmanageable in a junior coder's hands (much like PHP). Learning Qt using PyQt will get you accustomed to both the rapid development you should be seeing for GUI development as well as good programming techniques you'd be advised to carry over into the Air/Flex environment.","full_conversation":[{"role":"OP","user_id":"anon_a838925267355ffd","comment_id":"8kd0c","kind":"post","text":"Hey Proggit, I have an option of either learning Adobe Flex or Qt. Which would you suggest and Why?","timestamp":"2009-05-14T07:06:12+00:00","score":0},{"role":"answerer","user_id":"anon_7d2df2d31213df13","comment_id":"c09kb06","kind":"comment","text":"While I prefer Air/Flex to my other options for GUI development these days, it's for rapid-application development reasons and not for the quality of the code the framework encouarges. Qt is the singular nicest to use and best designed desktop GUI framework I've used. And I've used a lot.\n\nSo if you want to:\n - get a job as a 'web dude' just learn Flex/Air\n\n - get a job in visual effects or doing heavy 3D modeling like solidworks, learn PyQt\n\n - observe and use good programming techniques of the framework to improve your own coding skills and to better understand how a proper MVC framework should work use Qt/C++\n\n - rapidly develop an internet-services-centric, glitzy GUI use Air/Flex\n\n - observe and use good programming techniques of the framework to improve your own coding skills and to better understand how a proper aysnchronous/event-based GUI coding works, use PyQt\n\n - if you answered \"Yes\" to all of the above, pick a target problem - say 'yet another twitter client' and implement it first in PyQt. Then re-implement that same application in Flex/Air plus a good MVC framework like PureMVC and/or Cairngorn. \n\nI'd suggest the last option frankly. Flex is BRILLIANT but out of the box it encourages very messy, very tightly-coupled code that will quickly grow unmanageable in a junior coder's hands (much like PHP). Learning Qt using PyQt will get you accustomed to both the rapid development you should be seeing for GUI development as well as good programming techniques you'd be advised to carry over into the Air/Flex environment.","timestamp":"2009-05-14T09:57:18+00:00","score":1},{"role":"OP","user_id":"anon_a838925267355ffd","comment_id":"c09kbnk","kind":"comment","text":"Hi, Thanks for your wonderful answer. I really like the example target problem you gave. Do you by any chance have a link or so, where I can find, say, a list of all the \"real-time\" applications built using Qt or Flex? It would definitely make it easy to evaluate.","timestamp":"2009-05-14T10:51:01+00:00","score":1},{"role":"answerer","user_id":"anon_7d2df2d31213df13","comment_id":"c09kdjt","kind":"comment","text":"I've got heaps of personal experience with what I would call high-performance GUI's with both of these tools but I'm careful to not presume what you mean by \"real-time\". If you mean \"real-time\" like a stock trader means real-time then you'll struggle finding examples from either platform. I know of some 'very powerful' apps however:\n\n- PyQT: I know of aerodynamics engineering and 3D modelling applications built at Airbus that use PyQT with Enthought's \"Traits\" and other frameworks (http://code.enthought.com/). This is a very compelling and powerful stack. It's every bit as powerful as stuff I've seen built, with more effort, using Qt and C++.\n\n- C++ and Qt: The Foundry's Nuke is THE choice for hardcore 2D work in visual effects. It's built using C++ and Qt and has a bloody marvellous UI and is very high-performance. Mere mortals would be shocked by its power - it's so cool.\n\n- Flex/Air: I've personally built market-data visualisation applications using this stack that I can't share. Perhaps you can just download Tweetdeck to get a feel for Flex/Air's real-time capabilities.\n\nFlex/Air *really* is the way forward, it's just such a delight to use. BUT you MUST first understand:\n - the MVC ethos and separation of concerns\n - true event-based programming as Air is single-threaded. Conveniently, Qt has a GREAT event model called \"signals and slots\".\n\nFlex/Air will burn you badly if you don't understand this beforehand. And the Flex/Air gurus and the web tutorials/examples generally don't make nearly a big enough effort to address this.\n\nFinal note on this single-thread issue: C++ snobs are going to use this tidbit to dismiss the platform wholesale. Ignore them. They're just jealous it's still such a pain in the arse to use C++. And their beards itch.\n\nWhat you do need to realise though is that anything that requires loads of processing power should NOT be done in Air. Instead do that work in something like Python and communicate between the Python and Flex application using PyAMF. It's dead-easy to do this in a web-centric model. I've just finished a very satisfying prototype for a project management tool using:\n - Flex/Air user-interface, fronting a\n - Web2Py backend, running on\n - Google App Engine \n(see http://www.web2py.com/AlterEgo/default/show/22 for a starter)\n\nThis could be made to be quite fast, if not real-time with the right infrastructure. \"Real-Time\" applications are usually down to doing good, concurrent programming. Things like Python (using twisted, eventlets, or just generators), Erlang, Scala and others really have their heads screwed on right when it comes to concurrent programming. So my advice is pick a tool that:\n\n1) makes it easy and FAST to make a UI\n2) doesn't box you into design decisions that sacrifice performance arbitrarily\n3) easy and convenient concurrency capabilities\n\nFor me that tends to be Python for the 'hard stuff' and either PyQt for single-user UIs or Flex/Air for UIs that would be better distributed using the web model.","timestamp":"2009-05-14T12:54:19+00:00","score":2},{"role":"OP","user_id":"anon_a838925267355ffd","comment_id":"c09kdqg","kind":"comment","text":"Thank you so much! Can't upvote you enough. I think I've made my decision :) Thanks again!","timestamp":"2009-05-14T13:05:01+00:00","score":1},{"role":"answerer","user_id":"anon_7d2df2d31213df13","comment_id":"c09kdzz","kind":"comment","text":"Out of curiosity - which did you choose?\n\nAlso - try them all eventually. There's no \"one way\" to do things and you learn heaps by experimenting with each.\n\nHappy hacking!","timestamp":"2009-05-14T13:17:10+00:00","score":2},{"role":"OP","user_id":"anon_a838925267355ffd","comment_id":"c09ke9m","kind":"comment","text":"Me and my project partner chose Flex for this project, but are planning to use Qt for the next one. We were so impressed by both of 'em that we thought, 'What the heck, lets just learn both'. Decided to take it, step by step though. And since, we are focused on our current project and it has a 'deadline', we thought Flex is gonna be a lot more smoother. Thanks again for all your help. C ya :)","timestamp":"2009-05-14T13:30:07+00:00","score":1},{"role":"answerer","user_id":"anon_7d2df2d31213df13","comment_id":"c09keeu","kind":"comment","text":"Good choice and good luck - and remember: don't load too much logic into the blocks of your mxml sources -- use modules! :D\n\nhttp://livedocs.adobe.com/flex/3/html/help.html?content=usingas_6.html","timestamp":"2009-05-14T13:36:18+00:00","score":2},{"role":"OP","user_id":"anon_a838925267355ffd","comment_id":"c09keg7","kind":"comment","text":"Will definitely keep that in mind. Thanks!","timestamp":"2009-05-14T13:37:56+00:00","score":1}],"n_turns":9,"n_turns_after_thanks":6,"op_metadata":{"user_id":"anon_a838925267355ffd","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_7d2df2d31213df13","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c09kb06","thanks_reply_id":"c09kbnk","post_score":0,"answer_score":1,"preferred_answer_is_top_level":true}}
{"user_id":"anon_31cca738d8b6269c","answerer_user_id":"anon_146a04a13db2b7c3","subreddit":"programming","timestamp":"2009-05-15T14:52:06+00:00","post_id":"8kqr8","question":"What should a modern macro system look like?","preferred_answer":"Awesome!\r\n\r\nIn fact, I've been toying with ideas for an ideal language, and what you're describing fits it almost perfectly. A really powerful idea is that of combining dynamicity and staticness into one language, so you can use whichever fits best. Your approach of having two kinds of object seems good, and perfectly feasible.","full_conversation":[{"role":"OP","user_id":"anon_31cca738d8b6269c","comment_id":"8kqr8","kind":"post","text":"What should a modern macro system look like?","timestamp":"2009-05-15T14:52:06+00:00","score":24},{"role":"answerer","user_id":"anon_146a04a13db2b7c3","comment_id":"c09m7ue","kind":"comment","text":"Awesome!\r\n\r\nIn fact, I've been toying with ideas for an ideal language, and what you're describing fits it almost perfectly. A really powerful idea is that of combining dynamicity and staticness into one language, so you can use whichever fits best. Your approach of having two kinds of object seems good, and perfectly feasible.","timestamp":"2009-05-16T18:54:28+00:00","score":1},{"role":"OP","user_id":"anon_31cca738d8b6269c","comment_id":"c09m9p9","kind":"comment","text":"Thanks. To be clear, its two kinds of method, not object. It's perfectly fine for an object to have both multi- and single-dispatch methods.\n\nNow, I just need to decide on a basic macro/metaprogramming system, implement multi-method dispatch, fill in a bunch of operators, and announce it. :)\n\nIt's called Mother, after the computer in the original Alien movie.","timestamp":"2009-05-16T20:26:09+00:00","score":2},{"role":"answerer","user_id":"anon_146a04a13db2b7c3","comment_id":"c09maqr","kind":"comment","text":"Of course. For some reason I read \"multiple dispatch\" and thought of what I guess is called dynamic dispatch, as in the difference between ruby and java, not as in common lisp and java. But I'm with you now.\r\n\r\nYou got me wondering how multiple dispatch is implemented in common lisp, and google came up with [this](http://compilers.iecc.com/comparch/article/08-09-100). Maybe that's interesting to you too.","timestamp":"2009-05-16T21:17:15+00:00","score":1}],"n_turns":4,"n_turns_after_thanks":1,"op_metadata":{"user_id":"anon_31cca738d8b6269c","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_146a04a13db2b7c3","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c09m7ue","thanks_reply_id":"c09m9p9","post_score":24,"answer_score":1,"preferred_answer_is_top_level":false}}
{"user_id":"anon_679f69ae04c58629","answerer_user_id":"anon_f06bfef2b329f25a","subreddit":"programming","timestamp":"2009-05-21T09:20:48+00:00","post_id":"8m48q","question":"We (a small group of 6 students) are about to develop a Java EE website. It's a pretty standard C.R.U.D deal. Framework recommendations?","preferred_answer":"JBoss's Seam Framework and ICEFaces tie pretty well together, although ICEFaces documentation is a little lacking, and sometimes can be painful to tweak it \"just right\". \n\nDefinitely use Hibernate for persistence Layer... \n\n(Actually, I think there's a generator with Seam to build a simple CRUD website for a defined schema - never tried it myself, but might be reasonable starting point)","full_conversation":[{"role":"OP","user_id":"anon_679f69ae04c58629","comment_id":"8m48q","kind":"post","text":"We (a small group of 6 students) are about to develop a Java EE website. It's a pretty standard C.R.U.D deal. Framework recommendations?","timestamp":"2009-05-21T09:20:48+00:00","score":0},{"role":"answerer","user_id":"anon_f06bfef2b329f25a","comment_id":"c09pzj9","kind":"comment","text":"JBoss's Seam Framework and ICEFaces tie pretty well together, although ICEFaces documentation is a little lacking, and sometimes can be painful to tweak it \"just right\". \n\nDefinitely use Hibernate for persistence Layer... \n\n(Actually, I think there's a generator with Seam to build a simple CRUD website for a defined schema - never tried it myself, but might be reasonable starting point)","timestamp":"2009-05-21T09:29:49+00:00","score":0},{"role":"OP","user_id":"anon_679f69ae04c58629","comment_id":"c09pzro","kind":"comment","text":"Thanks I'm reading over the Seam tutorial now.\n\nCan anyone comment on the Tapestry framework?","timestamp":"2009-05-21T09:53:03+00:00","score":1},{"role":"answerer","user_id":"anon_f06bfef2b329f25a","comment_id":"c09q2jb","kind":"comment","text":"I should have added - if its to get a simple CRUD website up and running then don't look to Java - unless you are, as I suspect, looking at getting the experience...\n\nFor a quick way of building very functional CRUD website check out Python's Django project - a few simple python classes to represent a data model is all you need for full blown CRUD site (Django automatically generates an \"admin\" site if desired...)","timestamp":"2009-05-21T13:24:57+00:00","score":1}],"n_turns":4,"n_turns_after_thanks":1,"op_metadata":{"user_id":"anon_679f69ae04c58629","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_f06bfef2b329f25a","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c09pzj9","thanks_reply_id":"c09pzro","post_score":0,"answer_score":0,"preferred_answer_is_top_level":true}}
{"user_id":"anon_55c03d04a702239c","answerer_user_id":"anon_4703c4e627fb0dea","subreddit":"programming","timestamp":"2009-05-25T17:34:16+00:00","post_id":"8n450","question":"Dear Reddit, could you please help me with choosing a Computer Science BSC graduation paper subject?","preferred_answer":"Lurk on LKML for a while. Find some nasty thing that is obviously broken but that no one wants to spend the time to fix or has gotten around to fixing yet. (Last time I looked, there were a lot of things like this.) Fix it. The more code you have to gut and replace with totally different algorithms, the better.","full_conversation":[{"role":"OP","user_id":"anon_55c03d04a702239c","comment_id":"8n450","kind":"post","text":"Dear Reddit, could you please help me with choosing a Computer Science BSC graduation paper subject?","timestamp":"2009-05-25T17:34:16+00:00","score":1},{"role":"answerer","user_id":"anon_4703c4e627fb0dea","comment_id":"c09t7qx","kind":"comment","text":"Lurk on LKML for a while. Find some nasty thing that is obviously broken but that no one wants to spend the time to fix or has gotten around to fixing yet. (Last time I looked, there were a lot of things like this.) Fix it. The more code you have to gut and replace with totally different algorithms, the better.","timestamp":"2009-05-25T20:29:53+00:00","score":0},{"role":"OP","user_id":"anon_55c03d04a702239c","comment_id":"c09t86r","kind":"comment","text":"Thank you. That's a very interesting idea. Do you have any tips on how I could browse more efficiently through all that information? I am kind of short on time. I have to provide a name for my thesis preferably this week.","timestamp":"2009-05-25T20:49:09+00:00","score":1},{"role":"answerer","user_id":"anon_4703c4e627fb0dea","comment_id":"c09t8kk","kind":"comment","text":"Read LWN. Love LWN. LWN is good.\r\n\r\nhttp://www.lwn.net/","timestamp":"2009-05-25T21:04:10+00:00","score":0}],"n_turns":4,"n_turns_after_thanks":1,"op_metadata":{"user_id":"anon_55c03d04a702239c","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_4703c4e627fb0dea","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c09t7qx","thanks_reply_id":"c09t86r","post_score":1,"answer_score":0,"preferred_answer_is_top_level":false}}
{"user_id":"anon_8f0b713f36f9857d","answerer_user_id":"anon_013baa47c11529c3","subreddit":"programming","timestamp":"2009-05-27T05:18:00+00:00","post_id":"8nium","question":"Hey Reddit, Whats The Best Free Web Host?","preferred_answer":"http://www.free-webhosts.com/user_reviews.php\n\nDon't thank me, thank google. Input best free web hosting ratings...\n\nGood luck\n\nregards...jack","full_conversation":[{"role":"OP","user_id":"anon_8f0b713f36f9857d","comment_id":"8nium","kind":"post","text":"Hey Reddit, Whats The Best Free Web Host?","timestamp":"2009-05-27T05:18:00+00:00","score":0},{"role":"answerer","user_id":"anon_013baa47c11529c3","comment_id":"c09uhkr","kind":"comment","text":"http://www.free-webhosts.com/user_reviews.php\n\nDon't thank me, thank google. Input best free web hosting ratings...\n\nGood luck\n\nregards...jack","timestamp":"2009-05-27T05:23:25+00:00","score":1},{"role":"OP","user_id":"anon_8f0b713f36f9857d","comment_id":"c09uhvf","kind":"comment","text":"ok, i wont thank you \nthank you!","timestamp":"2009-05-27T05:40:08+00:00","score":2},{"role":"answerer","user_id":"anon_013baa47c11529c3","comment_id":"c09uic9","kind":"comment","text":"Cool.\n\nregards...jack","timestamp":"2009-05-27T06:02:29+00:00","score":0}],"n_turns":4,"n_turns_after_thanks":1,"op_metadata":{"user_id":"anon_8f0b713f36f9857d","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_013baa47c11529c3","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c09uhkr","thanks_reply_id":"c09uhvf","post_score":0,"answer_score":1,"preferred_answer_is_top_level":false}}
{"user_id":"anon_8055b23cb9a31bf1","answerer_user_id":"anon_249451e2b0932936","subreddit":"programming","timestamp":"2009-05-29T12:35:04+00:00","post_id":"8o792","question":"Does anyone have an opinion on developing a site with Google Web Toolkit? I cannot find any negatives online so any personal experience would be great to hear.","preferred_answer":"[Edited: please excuse my formatting skill]\n\nI've been using GWT (and Ext-GWT) for almost 1.5 years. So please take my opinion with a grain of salt. \n\nFirst of all, GWT is more suitable for a single page app with lots of UI interactivity and flashes. So you probably don't want to use it to build sites like Stackoverflow.com.\n\nSecond, if you need your site to be searchable by search engine, you should limit the use of GWT to small widgets whereas your pages should come from \"View/Template\" (Erb, JSP, PHP whatever). \n\nThird, anything you can do with JS, GWT should be able to do it. \n\nNow once we pass the high-level usage. Let's go deeper a little bit to GWT features/issues that I know in no particular order (you should check + use GWT yourself for the full features). \n\n* Internationalization. \nIt's easier to do i18n with GWT: create a property file for a target language and let GWT 1l8n tool handle the rest. GWT will load the right language properly for you. No extra logic. GWT i18n also help pluralization to some extend and the \"left to right\" plus \"right to left\" language format.\n\n* Abstracting Browsers. \nIt's true, it's write once run any browser... 99% of the time. There's this 1% case where certain browser just gave up, blew up or whatnot. The good news is that all these 1% cases have already been reported to GWT and they're there on their bug tracking list along with the discussion (open for public), workaround and future fixes. \n\n* Specific JS for specific Browser \nGWT compiles JS to various permutation output of popular browsers. If your client is IE, GWT will send IE JS code. So the code is guaranteed to be smaller than hand-written JS code that probably did something like \"if IE do the following\".\n\nNow: what would happen if HTML5 is out and you wrote your app in GWT? Nothing. GWT abstracts HTML/CSS/JS away from the developer.\n\nIn my experience using GWT, I've never have to care of the 1% until it hit me. Once it happened, Google for the bug and most likely you'll end up in GWT's bug tracking list. I still don't need to have extensive JS knowledge. It's like if you write a desktop app for Windows or Linux and there was a bug in the Windows/Linux kernel, do you have to know the kernel extensively? Most people don't need to know. \n\n* Debugging. \nDebugging GWT using Eclipse/Netbeans/Jetbrains feels like debugging a regular Java code. Again, debugging will cover 99% of the use-case. There is this 1% that the debugger can't cover: say in FF3 there is this bug where if you do setSelectionRange on a TextField (or... Firefox. Windows => IE. \n\nNow, the good news is that the GWT team is working hard to release Out-of-Process Hosted Mode so you can pick the browser to run your Hosted Mode on. It should be out soon. \n\n* Compilation, Obfuscation, Speed. \nGWT claims that it produces the faster JS code if compared with hand-written one. I don't know if it's true, but feel free to try it yourself. The code can be obfuscated as well so that's good if your JS or your UI code contains your secret sauce. \n\nOn the down-side, compilation process isn't the same with hitting refresh and GWT compiler is a bit slow. A medium-size project could take 2-4 minutes to compile. My development platform is OSX and it's a bit painful when I have to test on Firefox. Since Hosted-Mode is Safari only, I have to compile every time I want to test on other browser. Compilation issues will go away because GWT team is working on OOPHM (out of process) and compiler improvements. \n\n* Image Bundle. \nOne of the most well-known tricks to improve the responsiveness of the whole web-app is to bundle images and send them as one unified image file. But you'd have to do various tricks via CSS + background images + some (x,y) coordinates to access the images within the \"big image chunk\". First of all, I don't know any tools out there that can take a bunch of images, stitch them together, and generate CSS to map those images. Again, I'm a newbie in this area so there might be such tool already. GWT handles all of these for you via their ImageBundle sub-system. You create an interface + use Java annotation to point to an image file:\n\n@Resource(\"btn-submit-icon.gif\")\npublic AbstractImagePrototype submitButtonIcon();\n\nGWT compiler will collect all images pointed by @Resource and stitch them all for you. And you don't have to come up with your own CSS; GWT abstracts you from all of the tedious process.\n\n* Software Engineering/Agile goodies. \nI'm not a huge follower of Agile, XP, Scrum and all those things. But developing GWT app is almost as similar as developing a Java app. Which means you can do the following actions properly(?): Refactoring, Continuus Integration (Maven, Hudson), Unit Test, Mocking, etc.\n\nI haven't done them all but I suppose it is more easier to do them in GWT/Java environment compare to native JS?\n\nAs a side note: Google Gears (or HTML5 local database feature) brings powerful feature with added complexity. Now suddenly your front-end web-app can have features similar to a desktop-app. But you need to design your front-end code to support this \"Data Store\" layer properly (that either can ask data from Google Gears _or_ XMLHttpRequest Async callback) otherwise the JS code will be a huge messy jungle. \n\nPeople are quite familiar to design a complex desktop-app. I don't think people are comfortable to design front-end code using JS to adapt to a more desktop-app-like architecture.\n\n* Progressive JS Loading. \nThis is a new feature that I don't know when it's going to be included. The premise is that you don't have to send one big JS chunk to the client (JS = GWT compiled obfuscated JS output). The idea is that GWT will load pieces of the obfuscated code on-demand. \n\n* JSNI (JavaScript Native Interface). \nThe idea here is to write bits and pieces of pure native JS code and call that code from within GWT code. What's nice about this is that now you can wrap your favorite JS library (jQuery => GQuery) and use it within GWT. This means you can resort to JavaScript if you have to (for whatever reason). It's like writing ASM code within your C code (which is quite common in OS low-level code).\n\n* JS Overlay (JSON object => Java object). \nThis feature works similar to C union (or a wrapper). You define a Java object that extends JavaScriptObject. You provide getter/setter that calls JSNI code. You pass a JSON object to your Java object and voila, you can access all JSON properties with no parsing needed. \n\n* Weaknesses. \nIf you're using Java for server-side, there will be a case to have client side domain models: a simplify server side domain models. This introduce duplicates and grunt works to maintain. The way to avoid this is to make sure your domain-models are pure POJOs (I hate Java terminology). The general rule is that GWT should be able to compile your code. So if your domain-models contain annotations, those annotations must be available for GWT to compile (or even an interface marker like Serializable). GWT uses Java for its implementation language. Unfortunately, Java is too verbose for application development. You can make a strong case for server-side/system-level programming.","full_conversation":[{"role":"OP","user_id":"anon_8055b23cb9a31bf1","comment_id":"8o792","kind":"post","text":"Does anyone have an opinion on developing a site with Google Web Toolkit? I cannot find any negatives online so any personal experience would be great to hear.","timestamp":"2009-05-29T12:35:04+00:00","score":21},{"role":"answerer","user_id":"anon_249451e2b0932936","comment_id":"c09wu26","kind":"comment","text":"[Edited: please excuse my formatting skill]\n\nI've been using GWT (and Ext-GWT) for almost 1.5 years. So please take my opinion with a grain of salt. \n\nFirst of all, GWT is more suitable for a single page app with lots of UI interactivity and flashes. So you probably don't want to use it to build sites like Stackoverflow.com.\n\nSecond, if you need your site to be searchable by search engine, you should limit the use of GWT to small widgets whereas your pages should come from \"View/Template\" (Erb, JSP, PHP whatever). \n\nThird, anything you can do with JS, GWT should be able to do it. \n\nNow once we pass the high-level usage. Let's go deeper a little bit to GWT features/issues that I know in no particular order (you should check + use GWT yourself for the full features). \n\n* Internationalization. \nIt's easier to do i18n with GWT: create a property file for a target language and let GWT 1l8n tool handle the rest. GWT will load the right language properly for you. No extra logic. GWT i18n also help pluralization to some extend and the \"left to right\" plus \"right to left\" language format.\n\n* Abstracting Browsers. \nIt's true, it's write once run any browser... 99% of the time. There's this 1% case where certain browser just gave up, blew up or whatnot. The good news is that all these 1% cases have already been reported to GWT and they're there on their bug tracking list along with the discussion (open for public), workaround and future fixes. \n\n* Specific JS for specific Browser \nGWT compiles JS to various permutation output of popular browsers. If your client is IE, GWT will send IE JS code. So the code is guaranteed to be smaller than hand-written JS code that probably did something like \"if IE do the following\".\n\nNow: what would happen if HTML5 is out and you wrote your app in GWT? Nothing. GWT abstracts HTML/CSS/JS away from the developer.\n\nIn my experience using GWT, I've never have to care of the 1% until it hit me. Once it happened, Google for the bug and most likely you'll end up in GWT's bug tracking list. I still don't need to have extensive JS knowledge. It's like if you write a desktop app for Windows or Linux and there was a bug in the Windows/Linux kernel, do you have to know the kernel extensively? Most people don't need to know. \n\n* Debugging. \nDebugging GWT using Eclipse/Netbeans/Jetbrains feels like debugging a regular Java code. Again, debugging will cover 99% of the use-case. There is this 1% that the debugger can't cover: say in FF3 there is this bug where if you do setSelectionRange on a TextField (or... Firefox. Windows => IE. \n\nNow, the good news is that the GWT team is working hard to release Out-of-Process Hosted Mode so you can pick the browser to run your Hosted Mode on. It should be out soon. \n\n* Compilation, Obfuscation, Speed. \nGWT claims that it produces the faster JS code if compared with hand-written one. I don't know if it's true, but feel free to try it yourself. The code can be obfuscated as well so that's good if your JS or your UI code contains your secret sauce. \n\nOn the down-side, compilation process isn't the same with hitting refresh and GWT compiler is a bit slow. A medium-size project could take 2-4 minutes to compile. My development platform is OSX and it's a bit painful when I have to test on Firefox. Since Hosted-Mode is Safari only, I have to compile every time I want to test on other browser. Compilation issues will go away because GWT team is working on OOPHM (out of process) and compiler improvements. \n\n* Image Bundle. \nOne of the most well-known tricks to improve the responsiveness of the whole web-app is to bundle images and send them as one unified image file. But you'd have to do various tricks via CSS + background images + some (x,y) coordinates to access the images within the \"big image chunk\". First of all, I don't know any tools out there that can take a bunch of images, stitch them together, and generate CSS to map those images. Again, I'm a newbie in this area so there might be such tool already. GWT handles all of these for you via their ImageBundle sub-system. You create an interface + use Java annotation to point to an image file:\n\n@Resource(\"btn-submit-icon.gif\")\npublic AbstractImagePrototype submitButtonIcon();\n\nGWT compiler will collect all images pointed by @Resource and stitch them all for you. And you don't have to come up with your own CSS; GWT abstracts you from all of the tedious process.\n\n* Software Engineering/Agile goodies. \nI'm not a huge follower of Agile, XP, Scrum and all those things. But developing GWT app is almost as similar as developing a Java app. Which means you can do the following actions properly(?): Refactoring, Continuus Integration (Maven, Hudson), Unit Test, Mocking, etc.\n\nI haven't done them all but I suppose it is more easier to do them in GWT/Java environment compare to native JS?\n\nAs a side note: Google Gears (or HTML5 local database feature) brings powerful feature with added complexity. Now suddenly your front-end web-app can have features similar to a desktop-app. But you need to design your front-end code to support this \"Data Store\" layer properly (that either can ask data from Google Gears _or_ XMLHttpRequest Async callback) otherwise the JS code will be a huge messy jungle. \n\nPeople are quite familiar to design a complex desktop-app. I don't think people are comfortable to design front-end code using JS to adapt to a more desktop-app-like architecture.\n\n* Progressive JS Loading. \nThis is a new feature that I don't know when it's going to be included. The premise is that you don't have to send one big JS chunk to the client (JS = GWT compiled obfuscated JS output). The idea is that GWT will load pieces of the obfuscated code on-demand. \n\n* JSNI (JavaScript Native Interface). \nThe idea here is to write bits and pieces of pure native JS code and call that code from within GWT code. What's nice about this is that now you can wrap your favorite JS library (jQuery => GQuery) and use it within GWT. This means you can resort to JavaScript if you have to (for whatever reason). It's like writing ASM code within your C code (which is quite common in OS low-level code).\n\n* JS Overlay (JSON object => Java object). \nThis feature works similar to C union (or a wrapper). You define a Java object that extends JavaScriptObject. You provide getter/setter that calls JSNI code. You pass a JSON object to your Java object and voila, you can access all JSON properties with no parsing needed. \n\n* Weaknesses. \nIf you're using Java for server-side, there will be a case to have client side domain models: a simplify server side domain models. This introduce duplicates and grunt works to maintain. The way to avoid this is to make sure your domain-models are pure POJOs (I hate Java terminology). The general rule is that GWT should be able to compile your code. So if your domain-models contain annotations, those annotations must be available for GWT to compile (or even an interface marker like Serializable). GWT uses Java for its implementation language. Unfortunately, Java is too verbose for application development. You can make a strong case for server-side/system-level programming.","timestamp":"2009-05-29T17:10:04+00:00","score":28},{"role":"OP","user_id":"anon_8055b23cb9a31bf1","comment_id":"c09x2ui","kind":"comment","text":"Really appreciate the time and effort you have taken to respond to may fairly open ended question. Very helpful.","timestamp":"2009-05-29T22:05:05+00:00","score":6},{"role":"answerer","user_id":"anon_249451e2b0932936","comment_id":"c09y0rg","kind":"comment","text":"Oh and there are more\n\n* History \nMost AJAX web-apps have either no history, broken history, half-working history, or to use IFrame History workaround. GWT abstracts all of these from you. All you need to do is to register a history handle to your front-end code.\n\n* Optimized JS output \nThe JS output will not contain \"IF IE DO THIS\" kind of code. GWT generates output for different browsers and serves them depending on the browser type.","timestamp":"2009-05-31T07:04:46+00:00","score":1}],"n_turns":4,"n_turns_after_thanks":1,"op_metadata":{"user_id":"anon_8055b23cb9a31bf1","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_249451e2b0932936","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c09wu26","thanks_reply_id":"c09x2ui","post_score":21,"answer_score":28,"preferred_answer_is_top_level":true}}
{"user_id":"anon_dc14b6e2e53eedb1","answerer_user_id":"anon_cc319b2b11ee6453","subreddit":"programming","timestamp":"2009-05-30T11:58:51+00:00","post_id":"8ogb9","question":"Wanna learn something different: Haskell or PLT Scheme (comment inside)?","preferred_answer":"I do not know Haskell but heres why I think PLT Scheme is a good choice:\r\n\r\n 1. Really Good Documentations \r\nhttp://download.plt-scheme.org/doc/html/\r\n\r\n 2. DrScheme \r\n DrScheme is an amazing programming environment that comes with a compiler, stepper, syntax checkers, REPL, myriad of languages support and is extensible. This makes the entire experience fun. See some [screenshots](http://plt-scheme.org/screenshots/)\r\n\r\n 3. Good Support from the community. \r\nThe community is very enthusiastic about their language and very supportive too. If you have any questions, mailing lists, groups and forums are available. Even the authors are very very accessible.\r\n\r\n 4. Continuing Research \r\nPLT is very active and continue to make their tool better and better. You can expect a lot of innovations from the labs. eg. Im pretty excited about using this: http://blog.plt-scheme.org/2009/05/typed-scheme-20.html\r\n\r\n 5. Free Books and interesting tutorials to get you started. \r\nhttp://www.htdp.org/ \r\nhttp://world.cs.brown.edu/\r\n\r\n 6. Good modules and extensive libraries. \r\nhttp://www.cs.utah.edu/plt/develop/ \r\nhttp://planet.plt-scheme.org/ \r\nalso see [docs](http://docs.plt-scheme.org/)\r\n\r\nGive [PLT Scheme](http://download.plt-scheme.org/) a try. \r\n\r\nEdit: Btw have you seen [this article](http://scienceblogs.com/goodmath/2006/10/haskell_and_scheme_which_one_a.php)","full_conversation":[{"role":"OP","user_id":"anon_dc14b6e2e53eedb1","comment_id":"8ogb9","kind":"post","text":"Wanna learn something different: Haskell or PLT Scheme (comment inside)?","timestamp":"2009-05-30T11:58:51+00:00","score":11},{"role":"answerer","user_id":"anon_cc319b2b11ee6453","comment_id":"c09yasz","kind":"comment","text":"I do not know Haskell but heres why I think PLT Scheme is a good choice:\r\n\r\n 1. Really Good Documentations \r\nhttp://download.plt-scheme.org/doc/html/\r\n\r\n 2. DrScheme \r\n DrScheme is an amazing programming environment that comes with a compiler, stepper, syntax checkers, REPL, myriad of languages support and is extensible. This makes the entire experience fun. See some [screenshots](http://plt-scheme.org/screenshots/)\r\n\r\n 3. Good Support from the community. \r\nThe community is very enthusiastic about their language and very supportive too. If you have any questions, mailing lists, groups and forums are available. Even the authors are very very accessible.\r\n\r\n 4. Continuing Research \r\nPLT is very active and continue to make their tool better and better. You can expect a lot of innovations from the labs. eg. Im pretty excited about using this: http://blog.plt-scheme.org/2009/05/typed-scheme-20.html\r\n\r\n 5. Free Books and interesting tutorials to get you started. \r\nhttp://www.htdp.org/ \r\nhttp://world.cs.brown.edu/\r\n\r\n 6. Good modules and extensive libraries. \r\nhttp://www.cs.utah.edu/plt/develop/ \r\nhttp://planet.plt-scheme.org/ \r\nalso see [docs](http://docs.plt-scheme.org/)\r\n\r\nGive [PLT Scheme](http://download.plt-scheme.org/) a try. \r\n\r\nEdit: Btw have you seen [this article](http://scienceblogs.com/goodmath/2006/10/haskell_and_scheme_which_one_a.php)","timestamp":"2009-05-31T18:43:34+00:00","score":5},{"role":"OP","user_id":"anon_dc14b6e2e53eedb1","comment_id":"c09ztpf","kind":"comment","text":"Thanks kunjaan. Which language pack do you suggest? Should I use the *advanced student* from *How To Design Programs*? I'd like to have a \"complete\" environment since the beginning.\nOh, the article from scienceblogs.com looks interesting, I'm gonna read it right now!","timestamp":"2009-06-02T15:15:29+00:00","score":1},{"role":"answerer","user_id":"anon_cc319b2b11ee6453","comment_id":"c09zuhy","kind":"comment","text":"Since I started with HtDP, I used BSL and went to ASL. If you want the standard implementation then R5RS is good, but it doesnt have PLT's extensions to the language. Right now I just use the Module (#lang scheme).\r\n\r\nThere was an interesting discussion regarding various languages somewhere in comp.lang.scheme. I strongly urge you to join this group. Lot of PLT's researchers and the standard commitee's members are very active there.They will definitely welcome your questions and give you a better response .","timestamp":"2009-06-02T15:38:26+00:00","score":1}],"n_turns":4,"n_turns_after_thanks":1,"op_metadata":{"user_id":"anon_dc14b6e2e53eedb1","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_cc319b2b11ee6453","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c09yasz","thanks_reply_id":"c09ztpf","post_score":11,"answer_score":5,"preferred_answer_is_top_level":true}}
{"user_id":"anon_f37c7573a2ac32e5","answerer_user_id":"anon_6118959b6dfc70e4","subreddit":"programming","timestamp":"2009-06-08T05:10:44+00:00","post_id":"8qm86","question":"Is it possible to use same domain name for two servers with some setup? I will explain the question in the detail in comment due to space constraint.","preferred_answer":"As I understand it, your main domain is on a server where you have no PHP, and you need to show something done in PHP. Two quick and nasty solutions come to mind.\n\n1. An iframe, cheap and easy, but frowned upon. This is one of those few cases where I'd actually consider it... but I don't know the security implications for what you are trying to do. (Sessions, direct access, etc.). Some .htaccess magic could make sure that the page is only opened when linked to from the main domain.\n\n2. A subdomain that points to the PHP-enabled server. Probably more elegant but a little more work, and I don't know if you actually have DNS control of the main domain.\n\nWhat I would actually do:\n\n3. Just install php on the main server, it's not that hard. Or move the whole thing to a server with PHP.\n\nEdit: p.s. You know that a form action does not necessarily have to be hosted on the server that has the form, right? You can point the form to be processed elsewhere. If I had more specific information, I might be able to help out.","full_conversation":[{"role":"OP","user_id":"anon_f37c7573a2ac32e5","comment_id":"8qm86","kind":"post","text":"Is it possible to use same domain name for two servers with some setup? I will explain the question in the detail in comment due to space constraint.","timestamp":"2009-06-08T05:10:44+00:00","score":0},{"role":"answerer","user_id":"anon_6118959b6dfc70e4","comment_id":"c0a4o42","kind":"comment","text":"As I understand it, your main domain is on a server where you have no PHP, and you need to show something done in PHP. Two quick and nasty solutions come to mind.\n\n1. An iframe, cheap and easy, but frowned upon. This is one of those few cases where I'd actually consider it... but I don't know the security implications for what you are trying to do. (Sessions, direct access, etc.). Some .htaccess magic could make sure that the page is only opened when linked to from the main domain.\n\n2. A subdomain that points to the PHP-enabled server. Probably more elegant but a little more work, and I don't know if you actually have DNS control of the main domain.\n\nWhat I would actually do:\n\n3. Just install php on the main server, it's not that hard. Or move the whole thing to a server with PHP.\n\nEdit: p.s. You know that a form action does not necessarily have to be hosted on the server that has the form, right? You can point the form to be processed elsewhere. If I had more specific information, I might be able to help out.","timestamp":"2009-06-08T06:10:08+00:00","score":2},{"role":"OP","user_id":"anon_f37c7573a2ac32e5","comment_id":"c0a4o88","kind":"comment","text":"Thanks for the reply. It is not possible to install php on main server as the hosting company is not having that option.\n\nI will think about implementing your other suggestion. i-e moving while thing to a server with php. But the thing is domain name of non-php server will look good that the other.\n\nI hope there will be some way to change the domain name also. But I am not sure whether it will affect any search engine ranking.","timestamp":"2009-06-08T06:16:17+00:00","score":1},{"role":"answerer","user_id":"anon_6118959b6dfc70e4","comment_id":"c0a4oa3","kind":"comment","text":"A hosting company with no php these days? ... Move the whole thing.\n\nAs long as you have DNS control (i.e., you OWN the domain), moving it to a new server is trivial, as is creating subdomains that point elsewhere.\n\nOh, and as long as you move the whole thing and keep the same URIs, you should not lose any page ranking at all.","timestamp":"2009-06-08T06:19:53+00:00","score":2}],"n_turns":4,"n_turns_after_thanks":1,"op_metadata":{"user_id":"anon_f37c7573a2ac32e5","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_6118959b6dfc70e4","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c0a4o42","thanks_reply_id":"c0a4o88","post_score":0,"answer_score":2,"preferred_answer_is_top_level":true}}
{"user_id":"anon_99b9b678e5fdd4b7","answerer_user_id":"anon_be12453c8b82aca3","subreddit":"programming","timestamp":"2009-06-10T01:58:47+00:00","post_id":"8r7m9","question":"Anyone mind commenting on my large table visualization plugin for jQuery?","preferred_answer":"Yeah, my only quip with it is the hover delay as well.\n\nIt would be nice if you can set the hover_delay of your bullseye/table when you're setting it up, something like:\n\n $('div#bullseye').bullseye({\n 'use_rows': 3,\n 'use_cols': 3,\n 'hover_delay': 2,\n });\n\nMaybe?","full_conversation":[{"role":"OP","user_id":"anon_99b9b678e5fdd4b7","comment_id":"8r7m9","kind":"post","text":"Anyone mind commenting on my large table visualization plugin for jQuery?","timestamp":"2009-06-10T01:58:47+00:00","score":4},{"role":"answerer","user_id":"anon_be12453c8b82aca3","comment_id":"c0a6r14","kind":"comment","text":"Yeah, my only quip with it is the hover delay as well.\n\nIt would be nice if you can set the hover_delay of your bullseye/table when you're setting it up, something like:\n\n $('div#bullseye').bullseye({\n 'use_rows': 3,\n 'use_cols': 3,\n 'hover_delay': 2,\n });\n\nMaybe?","timestamp":"2009-06-10T13:55:43+00:00","score":1},{"role":"OP","user_id":"anon_99b9b678e5fdd4b7","comment_id":"c0a6x6c","kind":"comment","text":"Thanks, [see this](http://www.reddit.com/r/programming/comments/8r7m9/anyone_mind_commenting_on_my_large_table/c0a6x46)","timestamp":"2009-06-10T17:13:58+00:00","score":1},{"role":"answerer","user_id":"anon_be12453c8b82aca3","comment_id":"c0a6ybj","kind":"comment","text":"Well done","timestamp":"2009-06-10T17:48:02+00:00","score":1}],"n_turns":4,"n_turns_after_thanks":1,"op_metadata":{"user_id":"anon_99b9b678e5fdd4b7","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_be12453c8b82aca3","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c0a6r14","thanks_reply_id":"c0a6x6c","post_score":4,"answer_score":1,"preferred_answer_is_top_level":false}}
{"user_id":"anon_22c51c87ca038dcc","answerer_user_id":"anon_809e09cbace654d6","subreddit":"programming","timestamp":"2009-06-12T18:31:58+00:00","post_id":"8s1yj","question":"Ask reddit: Is it bad to tell a recruiter about others you are working with?","preferred_answer":"I have worked in Recruitment for almost 5 years and can tell you that you need to remember only 2 things when dealing with a Recruiter:\n\n* They are not there to find a job for you - They are there to find *you* for the job.\n* Never, ever, ever tell them about any other potential jobs you have lined up. \n\nThe reason for the second point is a practice known as 'lead farming'. They basically ask you which companies you are applying to or working with, so they can call that company 10 minutes later and submit several CVs / Résumés to that role. A large percentage of them will in-fact mention your name and voice their concerns about your reliability - to increase the chances of their candidates getting the job.\n\nTo give you an idea of their incentives for such behaviour: Successfully placing you in a £30k / $50k job would yield anywhere up to £2250 / $3750 in commission. Often the promise of great riches leads to morals being left at the door.\n\nThere are a reasonable amount of decent Recruitment agents out there but the underbelly is both seedy and considerable in size.\n\nHope this helps and doesn't put the frighteners on too much!\n\nFeel free to PM me if you are having any trouble with your applications / résumé or dealing with Recruiters. I recently left the industry to pursue a dream but would be more than happy to help :-)","full_conversation":[{"role":"OP","user_id":"anon_22c51c87ca038dcc","comment_id":"8s1yj","kind":"post","text":"Ask reddit: Is it bad to tell a recruiter about others you are working with?","timestamp":"2009-06-12T18:31:58+00:00","score":16},{"role":"answerer","user_id":"anon_809e09cbace654d6","comment_id":"c0a8xl0","kind":"comment","text":"I have worked in Recruitment for almost 5 years and can tell you that you need to remember only 2 things when dealing with a Recruiter:\n\n* They are not there to find a job for you - They are there to find *you* for the job.\n* Never, ever, ever tell them about any other potential jobs you have lined up. \n\nThe reason for the second point is a practice known as 'lead farming'. They basically ask you which companies you are applying to or working with, so they can call that company 10 minutes later and submit several CVs / Résumés to that role. A large percentage of them will in-fact mention your name and voice their concerns about your reliability - to increase the chances of their candidates getting the job.\n\nTo give you an idea of their incentives for such behaviour: Successfully placing you in a £30k / $50k job would yield anywhere up to £2250 / $3750 in commission. Often the promise of great riches leads to morals being left at the door.\n\nThere are a reasonable amount of decent Recruitment agents out there but the underbelly is both seedy and considerable in size.\n\nHope this helps and doesn't put the frighteners on too much!\n\nFeel free to PM me if you are having any trouble with your applications / résumé or dealing with Recruiters. I recently left the industry to pursue a dream but would be more than happy to help :-)","timestamp":"2009-06-12T18:55:57+00:00","score":32},{"role":"OP","user_id":"anon_22c51c87ca038dcc","comment_id":"c0a8yhb","kind":"comment","text":"Thanks for the info. Here's a follow-up: how to gracefully handle the questions then? I still want to appear favorable to these people, but when they ask what should I say? Just tell them I have no other leads? Or say \"I'd rather not say?\" What other tips do you have as a job seeker trying to manage being contacted by all these recruiters?","timestamp":"2009-06-12T19:21:52+00:00","score":6},{"role":"answerer","user_id":"anon_809e09cbace654d6","comment_id":"c0a8zsw","kind":"comment","text":"Recruiters are trained to push you on this. Regardless of your answer (short of telling them to mind their own business) they will, more than likely, push you on the matter several times. I'll offer some tips below to make your job search a more pleasant one.\n\n-----\n\nCall Recruiters by name whenever you speak to them (this generates consequence and takes them out of their comfort zone - you will notice a much greater level of attention being paid)\n\n-----\n\nIf you are faced with your original question, try something along the lines of \"I like to keep my cards close to my chest until I've found the right job\". As I say, they **will** push you on this. Just repeat variations of your initial statement and they will drop the subject with little or no consequence to you.\n\n-----\n\nIf you see a job you like, don't be lazy. Your CV / Résumé should look different for **every single** application you make. The reason for this is because you should be getting the job spec before you apply, or asking for the spec from the Recruiter before you permit them to send your CV / Résumé. Then, sit down and answer each individual requirement on the spec (do you have this skill / attribute? If so what is your proficiency and where did you acquire this skill?) and turn it into either a well written summary or bullet point set of personal skills / attributes. This should be at the top of your CV / Résumé. If you can't comfortably answer at least 60% of the main requirements, you should question your reasons for applying in the first place. If you do have 60%+ of the skills required and skilfully indicate this in a summary on the first page of your résumé, you are very likely to secure an interview.\n\n-----\n\nHiring Managers have neither the time nor the inclination to read your full job history, so make it easy for them in this format for every single job you’ve had: \n\n* Clear ‘from’ and ‘to’ dates and job title\n* Job description (“I was responsible for” It’s important to show that you have confidence in your yourself and can be clear about your actual responsibilities)\n* Achievements (anything from good client feedback to internal awards / meeting deadlines etc)\n* Reasons for leaving (Never be negative. Ever. Put a positive spin on as much as you can).\n* List of Skills / systems used (and proficiency). This creates a nice shit sandwich for every role. Starting with a description and your achievements, then the often shitty reason for leaving and cleaning up the taste with a nice set of appropriate skills along with your level of proficiency.\n\n-----\n\nThis is really just a sample. You’ll learn a lot by trial and error. Job seeking is often a draining and tiresome endeavour – Recruiters should be there to make it easier, but they’re not.\n\nAlso, if you haven’t already, sign up to a job search engine. Which country are you searching in? – I can give you links to a few regional search engines and tools that will help you.","timestamp":"2009-06-12T20:04:00+00:00","score":25}],"n_turns":4,"n_turns_after_thanks":1,"op_metadata":{"user_id":"anon_22c51c87ca038dcc","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_809e09cbace654d6","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c0a8xl0","thanks_reply_id":"c0a8yhb","post_score":16,"answer_score":32,"preferred_answer_is_top_level":true}}
{"user_id":"anon_b01da386a69d4023","answerer_user_id":"anon_5b11c5de8e629aa0","subreddit":"programming","timestamp":"2009-06-19T10:42:14+00:00","post_id":"8tv1o","question":"How to start using Git?\n\nSo, we are a team of 4 people, and we began a new project. We need some sort of version controle and we went with git. The problem is that we dont know much about version control and nothing about how git functions. I know that git is a distributed version control system, but how can we configure git so that we can come together and share our code? I don't know if anything what I said makes sence, but I hope you understand.","preferred_answer":"Read a tutorial ([this](http://www.kernel.org/pub/software/scm/git/docs/gittutorial.html), for example), then look for [tips and hints](http://gitready.com/). There is also the [Git Community Book](http://book.git-scm.com/).\n\nAs for sharing you either want [GitHub](http://github.com/) or a local TCP (git-daemon), SSH or HTTP server.","full_conversation":[{"role":"OP","user_id":"anon_b01da386a69d4023","comment_id":"8tv1o","kind":"post","text":"How to start using Git?\n\nSo, we are a team of 4 people, and we began a new project. We need some sort of version controle and we went with git. The problem is that we dont know much about version control and nothing about how git functions. I know that git is a distributed version control system, but how can we configure git so that we can come together and share our code? I don't know if anything what I said makes sence, but I hope you understand.","timestamp":"2009-06-19T10:42:14+00:00","score":0},{"role":"answerer","user_id":"anon_5b11c5de8e629aa0","comment_id":"c0aes7l","kind":"comment","text":"Read a tutorial ([this](http://www.kernel.org/pub/software/scm/git/docs/gittutorial.html), for example), then look for [tips and hints](http://gitready.com/). There is also the [Git Community Book](http://book.git-scm.com/).\n\nAs for sharing you either want [GitHub](http://github.com/) or a local TCP (git-daemon), SSH or HTTP server.","timestamp":"2009-06-19T11:56:59+00:00","score":1},{"role":"OP","user_id":"anon_b01da386a69d4023","comment_id":"c0aetdy","kind":"comment","text":"thanks for the tips...i'll try those out. If we want to share code over the internet, do we need a server?","timestamp":"2009-06-19T13:06:00+00:00","score":0},{"role":"answerer","user_id":"anon_5b11c5de8e629aa0","comment_id":"c0aeyyl","kind":"comment","text":"Yes, though you can always resort to sending and recieving patches through email. Here is an [instruction](http://gitready.com/intermediate/2009/01/24/sharing-your-changes.html) how to set up a server.","timestamp":"2009-06-19T16:20:02+00:00","score":1},{"role":"OP","user_id":"anon_b01da386a69d4023","comment_id":"c0af0q8","kind":"comment","text":"ok..I'll try it...Thanks","timestamp":"2009-06-19T17:09:27+00:00","score":1}],"n_turns":5,"n_turns_after_thanks":2,"op_metadata":{"user_id":"anon_b01da386a69d4023","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_5b11c5de8e629aa0","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c0aes7l","thanks_reply_id":"c0aetdy","post_score":0,"answer_score":1,"preferred_answer_is_top_level":true}}
{"user_id":"anon_17d93b3e93059e01","answerer_user_id":"anon_86ea27774b02896d","subreddit":"programming","timestamp":"2009-06-22T05:46:36+00:00","post_id":"8uhat","question":"can someone w/ Vista 64bit help me out? Need wow64cpu.dll\n\nMy laptop keeps crashing because of a corrupted dll file (C:\\windows\\system32\\wow64cpu.dll). Can someone with a Vista 64 bit edition please help me out? My \"temp\" e-mail is temp@apoetry.com. \n\nThanks a lot!","preferred_answer":"See\n\nhttp://neosmart.net/blog/2008/windows-vista-recovery-disc-download/\n\nThese are also available direct from Microsoft, although I have misplaced that specific link.\n\nThis will allow you to do certain repair actions","full_conversation":[{"role":"OP","user_id":"anon_17d93b3e93059e01","comment_id":"8uhat","kind":"post","text":"can someone w/ Vista 64bit help me out? Need wow64cpu.dll\n\nMy laptop keeps crashing because of a corrupted dll file (C:\\windows\\system32\\wow64cpu.dll). Can someone with a Vista 64 bit edition please help me out? My \"temp\" e-mail is temp@apoetry.com. \n\nThanks a lot!","timestamp":"2009-06-22T05:46:36+00:00","score":0},{"role":"answerer","user_id":"anon_86ea27774b02896d","comment_id":"c0agzom","kind":"comment","text":"See\n\nhttp://neosmart.net/blog/2008/windows-vista-recovery-disc-download/\n\nThese are also available direct from Microsoft, although I have misplaced that specific link.\n\nThis will allow you to do certain repair actions","timestamp":"2009-06-22T06:01:33+00:00","score":1},{"role":"OP","user_id":"anon_17d93b3e93059e01","comment_id":"c0ah98n","kind":"comment","text":"Thank you. I'll try it out tonight, and will let you know how it goes.","timestamp":"2009-06-22T15:16:32+00:00","score":1},{"role":"answerer","user_id":"anon_86ea27774b02896d","comment_id":"c0ahej0","kind":"comment","text":"You are welcome\n\nlet's you do a system restore among other things.","timestamp":"2009-06-22T17:49:26+00:00","score":1},{"role":"OP","user_id":"anon_17d93b3e93059e01","comment_id":"c0ahwod","kind":"comment","text":"Thanks anyway Scientologist2, but I tried it out, didn't help. The auto-recover tool fails, and the manual option just gets me to the command prompt. Can't do a system restore, as I don't have the original disk, nor do I have a backup of the files. It does mount the file system correctly and I can access it via command prompt. I technically had access to the file system by mounting this drive onto an XP installation. \nI'm a fairly experienced technician. \n\nAnyway I think I still need the wow64cpu.dll sigh.","timestamp":"2009-06-23T03:37:53+00:00","score":1},{"role":"answerer","user_id":"anon_86ea27774b02896d","comment_id":"c0ahxcs","kind":"comment","text":"then you might be able to find it in one of the system recover folders.\n\nI believe the recover disk does give you the option to run system restor IF you had it enabled in the first place.\n\nAlso, another place to look may be in the dll cache, or in the service pack install file folder.\n\nIf you have a windows live cd, then you may be able to do a search and find it in an obscure folder.\n\nI also note that these seem to have some system variations based on hardware optimization. (AMD64 vs Intel, etc)\n\nI also wonder if the file is on the recovery CD itself. \n\nNote: 7zip can also extract the contents of a wim file, and the data is compressed in a boot.wim on the recovery CD\n\nEdit: just did a quick check, no such luck.\n\nanother option is to run it as a slave from your xp system, and see if you can do an undelete using one of the common undelete tools out there. You could get lucky.","timestamp":"2009-06-23T04:04:25+00:00","score":1},{"role":"OP","user_id":"anon_17d93b3e93059e01","comment_id":"c0akpkx","kind":"comment","text":"Solved - Ok, I was able to get the file from a computer at work. In the future, if someone runs across the same problem as me, you can find the file, that I posted here: http://www.apoetry.com/random_files/wow64cpu.dll keywords: bad image, 00007, corrupted file, windows won't boot. \n\nTo repair the system, which wouldn't boot into safe mode, I had to use the boot-disk from the top (although mounting the disk should work also) and replaced the wow64cpu.dll . Please note that you may have to take ownership of the file, in order to replace it, in the mounted-disk solution. (Look up permissions and ownership for XP). \n\nCheers.","timestamp":"2009-06-25T20:31:33+00:00","score":1},{"role":"answerer","user_id":"anon_86ea27774b02896d","comment_id":"c0akvmi","kind":"comment","text":"excellent news!\n\nGood work!","timestamp":"2009-06-25T23:27:33+00:00","score":1}],"n_turns":8,"n_turns_after_thanks":5,"op_metadata":{"user_id":"anon_17d93b3e93059e01","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_86ea27774b02896d","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c0agzom","thanks_reply_id":"c0ah98n","post_score":0,"answer_score":1,"preferred_answer_is_top_level":true}}
{"user_id":"anon_1d34495558fc4cb3","answerer_user_id":"anon_95a5db54e130031f","subreddit":"programming","timestamp":"2009-06-27T07:30:00+00:00","post_id":"8w4t6","question":"looking for a specific financial crisis story\n\nA few months ago there was a link posted to proggit, to a story about a guy who wrote some software to faciliate packaging mortgages and loans up (CMO, CMD, whatever you want to call them). I feel like it was a wired article, but I cannot find it. Also numerous google searches have turned up nothing for me. Can anyone help me?","preferred_answer":"Michael Osinski is the name.\n\n[article:](http://nymag.com/news/business/55687/)\n\n[posted in various reddits](http://www.reddit.com/submit?url=http%3A%2F%2Fnymag.com%2Fnews%2Fbusiness%2F55687%2F)","full_conversation":[{"role":"OP","user_id":"anon_1d34495558fc4cb3","comment_id":"8w4t6","kind":"post","text":"looking for a specific financial crisis story\n\nA few months ago there was a link posted to proggit, to a story about a guy who wrote some software to faciliate packaging mortgages and loans up (CMO, CMD, whatever you want to call them). I feel like it was a wired article, but I cannot find it. Also numerous google searches have turned up nothing for me. Can anyone help me?","timestamp":"2009-06-27T07:30:00+00:00","score":0},{"role":"answerer","user_id":"anon_95a5db54e130031f","comment_id":"c0am4xz","kind":"comment","text":"Michael Osinski is the name.\n\n[article:](http://nymag.com/news/business/55687/)\n\n[posted in various reddits](http://www.reddit.com/submit?url=http%3A%2F%2Fnymag.com%2Fnews%2Fbusiness%2F55687%2F)","timestamp":"2009-06-27T07:44:30+00:00","score":2},{"role":"OP","user_id":"anon_1d34495558fc4cb3","comment_id":"c0am58g","kind":"comment","text":"Thank you very much!","timestamp":"2009-06-27T08:05:28+00:00","score":1},{"role":"answerer","user_id":"anon_95a5db54e130031f","comment_id":"c0am5a4","kind":"comment","text":"you're welcome! glad I could help.","timestamp":"2009-06-27T08:08:37+00:00","score":1}],"n_turns":4,"n_turns_after_thanks":1,"op_metadata":{"user_id":"anon_1d34495558fc4cb3","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_95a5db54e130031f","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c0am4xz","thanks_reply_id":"c0am58g","post_score":0,"answer_score":2,"preferred_answer_is_top_level":true}}
{"user_id":"anon_a96233ebb24a8d1f","answerer_user_id":"anon_dba60ecadd4985b5","subreddit":"programming","timestamp":"2009-06-28T16:17:41+00:00","post_id":"8werd","question":"Ubuntu \"Gutsy Gibbon apt-get has many 404s - is it \r\nbroken?\n\nI'm getting messages like:\r\n\r\nFailed to fetch http://us.archive.ubuntu.com/ubuntu/dists/gutsy/main/binary-i386/Packages.gz 404 Not Found [IP: 91.189.88.40 80]\r\n\r\nThis started about a week ago.\r\n\r\nSo I wonder:\r\n\r\nIs G.G. still being supported?\r\n\r\nIs my configuration hosed?\r\n\r\nAre there server problems for Ubuntu?","preferred_answer":"http://www.ubuntu.com/news/ubuntu-7.10-eol","full_conversation":[{"role":"OP","user_id":"anon_a96233ebb24a8d1f","comment_id":"8werd","kind":"post","text":"Ubuntu \"Gutsy Gibbon apt-get has many 404s - is it \r\nbroken?\n\nI'm getting messages like:\r\n\r\nFailed to fetch http://us.archive.ubuntu.com/ubuntu/dists/gutsy/main/binary-i386/Packages.gz 404 Not Found [IP: 91.189.88.40 80]\r\n\r\nThis started about a week ago.\r\n\r\nSo I wonder:\r\n\r\nIs G.G. still being supported?\r\n\r\nIs my configuration hosed?\r\n\r\nAre there server problems for Ubuntu?","timestamp":"2009-06-28T16:17:41+00:00","score":0},{"role":"answerer","user_id":"anon_dba60ecadd4985b5","comment_id":"c0an6nu","kind":"comment","text":"http://www.ubuntu.com/news/ubuntu-7.10-eol","timestamp":"2009-06-28T18:56:25+00:00","score":1},{"role":"OP","user_id":"anon_a96233ebb24a8d1f","comment_id":"c0an6um","kind":"comment","text":"Thank you!\r\n\r\nOkay, joke's on me, so it's time to upgrade.\r\n\r\nJust to add to the LULZ, I go the page you suggested, click the link for upgrade instructions and caveats, and the page doesn't exist.\r\n\r\nHowever, this page does exist:\r\n\r\nhttps://help.ubuntu.com/community/HardyUpgrades","timestamp":"2009-06-28T19:04:35+00:00","score":1},{"role":"answerer","user_id":"anon_dba60ecadd4985b5","comment_id":"c0an7hx","kind":"comment","text":"Yeah, I thought the non-existent upgrade HOWTO was the best.","timestamp":"2009-06-28T19:31:35+00:00","score":1}],"n_turns":4,"n_turns_after_thanks":1,"op_metadata":{"user_id":"anon_a96233ebb24a8d1f","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_dba60ecadd4985b5","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c0an6nu","thanks_reply_id":"c0an6um","post_score":0,"answer_score":1,"preferred_answer_is_top_level":true}}
{"user_id":"anon_6ac92c0a4cbc9223","answerer_user_id":"anon_1347bb14f0310728","subreddit":"programming","timestamp":"2009-06-30T11:53:25+00:00","post_id":"8wxw0","question":"reddit help me choose a new public torrent tracker to replace pirate bay\n\nI LOOOVE pirate bay but looks like we need new options. (At least as a back up). Come on reddit, help me by voting up or posting the best alternatives. \n\nNote that (apparently) http://isohunt.com, http://btjunkie.org, http://torrentz.com are 'public search engines'. What I need is a 'public tracker' not somewhere that links out to somewhere else but a community of good trackers without ads.. ie... pirate bay, but not... \n\nGo to it! And Thanks.\n\nCan anyone help me?","preferred_answer":"wow....touche! I have no response! (except maybe an upvote is deserved for making you laugh/think/annoyed?)\n\nI think that both you and OP now deserve an invite code (if you want)","full_conversation":[{"role":"OP","user_id":"anon_6ac92c0a4cbc9223","comment_id":"8wxw0","kind":"post","text":"reddit help me choose a new public torrent tracker to replace pirate bay\n\nI LOOOVE pirate bay but looks like we need new options. (At least as a back up). Come on reddit, help me by voting up or posting the best alternatives. \n\nNote that (apparently) http://isohunt.com, http://btjunkie.org, http://torrentz.com are 'public search engines'. What I need is a 'public tracker' not somewhere that links out to somewhere else but a community of good trackers without ads.. ie... pirate bay, but not... \n\nGo to it! And Thanks.\n\nCan anyone help me?","timestamp":"2009-06-30T11:53:25+00:00","score":0},{"role":"answerer","user_id":"anon_1347bb14f0310728","comment_id":"c0aoxcj","kind":"comment","text":"wow....touche! I have no response! (except maybe an upvote is deserved for making you laugh/think/annoyed?)\n\nI think that both you and OP now deserve an invite code (if you want)","timestamp":"2009-06-30T12:25:13+00:00","score":1},{"role":"OP","user_id":"anon_6ac92c0a4cbc9223","comment_id":"c0apecc","kind":"comment","text":"yes please.. apologies btw for messing up the OP .. and incidentally thanks to all who bothered to comment even mr 6 reasons i suck","timestamp":"2009-06-30T20:29:18+00:00","score":3},{"role":"answerer","user_id":"anon_1347bb14f0310728","comment_id":"c0apkkj","kind":"comment","text":"well, in the end, you ended up with a 0 karma, so no harm done in the long run :D","timestamp":"2009-06-30T23:45:39+00:00","score":1}],"n_turns":4,"n_turns_after_thanks":1,"op_metadata":{"user_id":"anon_6ac92c0a4cbc9223","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_1347bb14f0310728","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c0aoxcj","thanks_reply_id":"c0apecc","post_score":0,"answer_score":1,"preferred_answer_is_top_level":false}}
{"user_id":"anon_4e736ef703db231e","answerer_user_id":"anon_f7fd5c09bcaa3166","subreddit":"programming","timestamp":"2009-07-01T21:11:28+00:00","post_id":"8xf23","question":"my hosting for 4 sites expires in 1 week - what cheap webhost would you suggest reddit?\n\nlooking for a dependable webhost for shared hosting for 4 domains. the only criteria is the site has to be fast (low latency for MySQL queries) for a fast wordpress site.","preferred_answer":"I've had really good experience with http://hosting.mymarkdown.com. Their cheapest server is $2/month.","full_conversation":[{"role":"OP","user_id":"anon_4e736ef703db231e","comment_id":"8xf23","kind":"post","text":"my hosting for 4 sites expires in 1 week - what cheap webhost would you suggest reddit?\n\nlooking for a dependable webhost for shared hosting for 4 domains. the only criteria is the site has to be fast (low latency for MySQL queries) for a fast wordpress site.","timestamp":"2009-07-01T21:11:28+00:00","score":0},{"role":"answerer","user_id":"anon_f7fd5c09bcaa3166","comment_id":"c0aqpnv","kind":"comment","text":"I've had really good experience with http://hosting.mymarkdown.com. Their cheapest server is $2/month.","timestamp":"2009-07-02T03:15:04+00:00","score":1},{"role":"OP","user_id":"anon_4e736ef703db231e","comment_id":"c0ar5es","kind":"comment","text":"that seems scary cheap - i am looking in to them now. thanks","timestamp":"2009-07-02T15:31:03+00:00","score":1},{"role":"answerer","user_id":"anon_f7fd5c09bcaa3166","comment_id":"c0arv9u","kind":"comment","text":"I've been using them for a few years now. I use one of their [hosting specials](http://hosting.mymarkdown.com/specials/discount-web-hosting.html). Cost me a little over $25/year per domain. I'm happy with them.\n\nI'm not affiliated with this company, just a happy customer.","timestamp":"2009-07-03T05:47:04+00:00","score":1}],"n_turns":4,"n_turns_after_thanks":1,"op_metadata":{"user_id":"anon_4e736ef703db231e","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_f7fd5c09bcaa3166","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c0aqpnv","thanks_reply_id":"c0ar5es","post_score":0,"answer_score":1,"preferred_answer_is_top_level":false}}
{"user_id":"anon_656e0e080cc0b8ae","answerer_user_id":"anon_cead994f4e452ad8","subreddit":"programming","timestamp":"2009-07-05T00:44:28+00:00","post_id":"8y9u3","question":"Ask Proggit: Do you find yourself processing daily logic and choice with cognitive models similar to code?\n\nI recently started progr-- typing formulas into excel (just discovered arrays, i'm elated) and liked the concrete nature of the operations. I have a psychology degree so I'm generally interested as to how my mind is making choices or producing behavior. After a few days of constant work I found myself processing certain choices as if they were written code. I don't think my model itself changed, it was just another way to look at it. \n\nI don't know anyone who does a fair amount of programming so I thought I would ask you all how you felt about it. If you change languages for long enough does your cognitive model change? Do you combine or making use of certain 'commands' for certain situations? Do you ever think about any of this stuff?","preferred_answer":"I dream about Monads and Functors and related things now, instead of pointers and memory.\n\nI usually see a transitions between things like this in my dreams, and how I think about solving programming problems, but not in real life problems. I usually convert all problems into a visualization of something almost mechanical.\n\nI have been programming since I was extremely young, but I don't think I've ever related any sort of real-life algorithm such as a food recipe, or how to build a real life object into any sort of programming language.\n\nIn fact, I think most problems in can solve or think of in my head, real life or programming are always converted to a visualization in my mind of something nearly mechanical in nature. Being able to see a programming problem as moving pieces in my mind and this is what I think makes me good at programming and logic in general.\n\nThis kind of visualization is the same as what is in my dreams. Learning a different programming language or paradigm only changes what mechanical pieces I have to work with.","full_conversation":[{"role":"OP","user_id":"anon_656e0e080cc0b8ae","comment_id":"8y9u3","kind":"post","text":"Ask Proggit: Do you find yourself processing daily logic and choice with cognitive models similar to code?\n\nI recently started progr-- typing formulas into excel (just discovered arrays, i'm elated) and liked the concrete nature of the operations. I have a psychology degree so I'm generally interested as to how my mind is making choices or producing behavior. After a few days of constant work I found myself processing certain choices as if they were written code. I don't think my model itself changed, it was just another way to look at it. \n\nI don't know anyone who does a fair amount of programming so I thought I would ask you all how you felt about it. If you change languages for long enough does your cognitive model change? Do you combine or making use of certain 'commands' for certain situations? Do you ever think about any of this stuff?","timestamp":"2009-07-05T00:44:28+00:00","score":11},{"role":"answerer","user_id":"anon_cead994f4e452ad8","comment_id":"c0atab8","kind":"comment","text":"I dream about Monads and Functors and related things now, instead of pointers and memory.\n\nI usually see a transitions between things like this in my dreams, and how I think about solving programming problems, but not in real life problems. I usually convert all problems into a visualization of something almost mechanical.\n\nI have been programming since I was extremely young, but I don't think I've ever related any sort of real-life algorithm such as a food recipe, or how to build a real life object into any sort of programming language.\n\nIn fact, I think most problems in can solve or think of in my head, real life or programming are always converted to a visualization in my mind of something nearly mechanical in nature. Being able to see a programming problem as moving pieces in my mind and this is what I think makes me good at programming and logic in general.\n\nThis kind of visualization is the same as what is in my dreams. Learning a different programming language or paradigm only changes what mechanical pieces I have to work with.","timestamp":"2009-07-05T01:00:14+00:00","score":5},{"role":"OP","user_id":"anon_656e0e080cc0b8ae","comment_id":"c0atadi","kind":"comment","text":"Have you solved a real life programming problem through a dream? Are you working on current programs in the dreams or are they more abstract? Or do you solve meaningless problems, random numbers and concepts piled into the dream?","timestamp":"2009-07-05T01:02:52+00:00","score":3},{"role":"answerer","user_id":"anon_cead994f4e452ad8","comment_id":"c0av07x","kind":"comment","text":"There are a few times I can remember solving something in a dream that I was going to have to figure out the next morning at work. \n\nI can remember the last time, when I got to work it actually felt very much like I was being made to do the work twice, and I did use the same approach as in my dream.\n\nMost of the time any dreams about programming are pretty abstract and just visualizations about how data structures fit together, or like you said, random meaningless problems, queues, linked lists, trees, loops or flattened out recursion, stuff that is hard to describe.","timestamp":"2009-07-07T00:43:14+00:00","score":1}],"n_turns":4,"n_turns_after_thanks":1,"op_metadata":{"user_id":"anon_656e0e080cc0b8ae","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_cead994f4e452ad8","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c0atab8","thanks_reply_id":"c0atadi","post_score":11,"answer_score":5,"preferred_answer_is_top_level":true}}
{"user_id":"anon_6570896f6a804f78","answerer_user_id":"anon_5c4b9e601ba994b3","subreddit":"programming","timestamp":"2009-07-14T05:01:36+00:00","post_id":"90yd2","question":"How do I prepare for an interview for a QA position\n\nI've scheduled an interview for a QA position, when I was told I had all the skills necessary even though I have next to no QA experience (I have a CS degree and a few short jobs working in the .NET framework), how do I prepare for the interview?","preferred_answer":"* Just off the top of my head: understand the difference between the various types of testings: sanity, regression, black box, unit testing, etc.\n\n\n* More nomenclature to be familiar with (If the person interviewing you is a stickler, he may be dickish about properly \"defining\" the terms): Test plan, test case, test specification, test documentation, bug report.\n\n\n* Look at the login screen of your yahoomail/gmail account, and write some test cases in a formal manner i.e you should be able to succinctly but sufficiently describe the tests and the expected outcomes, and the potential bug you uncovered too if submitted a bug report.\n\n\n* Familiarize yourself superficially with some of the automated testing programs/scripting languages out there.\n\n\nIf this is your first job, or you really need a job right now, then good luck to you! Otherwise, keep in mind that QA is essentially a thankless job, literally speaking. When you find a bug, developers will be annoyed. If you miss a bug, and product is released, developers will be annoyed. A large portion of your time may be involved in just writing test documentation in MS Word, and performing the same tests manually with mouse clicks over and over and over and over and over and over again....","full_conversation":[{"role":"OP","user_id":"anon_6570896f6a804f78","comment_id":"90yd2","kind":"post","text":"How do I prepare for an interview for a QA position\n\nI've scheduled an interview for a QA position, when I was told I had all the skills necessary even though I have next to no QA experience (I have a CS degree and a few short jobs working in the .NET framework), how do I prepare for the interview?","timestamp":"2009-07-14T05:01:36+00:00","score":0},{"role":"answerer","user_id":"anon_5c4b9e601ba994b3","comment_id":"c0b2avf","kind":"comment","text":"* Just off the top of my head: understand the difference between the various types of testings: sanity, regression, black box, unit testing, etc.\n\n\n* More nomenclature to be familiar with (If the person interviewing you is a stickler, he may be dickish about properly \"defining\" the terms): Test plan, test case, test specification, test documentation, bug report.\n\n\n* Look at the login screen of your yahoomail/gmail account, and write some test cases in a formal manner i.e you should be able to succinctly but sufficiently describe the tests and the expected outcomes, and the potential bug you uncovered too if submitted a bug report.\n\n\n* Familiarize yourself superficially with some of the automated testing programs/scripting languages out there.\n\n\nIf this is your first job, or you really need a job right now, then good luck to you! Otherwise, keep in mind that QA is essentially a thankless job, literally speaking. When you find a bug, developers will be annoyed. If you miss a bug, and product is released, developers will be annoyed. A large portion of your time may be involved in just writing test documentation in MS Word, and performing the same tests manually with mouse clicks over and over and over and over and over and over again....","timestamp":"2009-07-14T05:24:15+00:00","score":7},{"role":"OP","user_id":"anon_6570896f6a804f78","comment_id":"c0b2b1j","kind":"comment","text":"Thanks, can you give me more info on how to write test cases for my gmail account (or some other tests), I don't even know what program I'd use.","timestamp":"2009-07-14T05:31:03+00:00","score":1},{"role":"answerer","user_id":"anon_5c4b9e601ba994b3","comment_id":"c0b2bcz","kind":"comment","text":"It's really not that hard, mostly just common sense, sometimes to the point of being so obtusely obvious that it seems asinine. You can automate the tests, but more than likely it will be manual and documented in MS Word, at least for the first testing iterations. For your email login:\n\n* Testcase 1: provide valid login ID and valid password\n\nExpected result: logged in successfully\n\n* Testcase 2: provide valid login ID and invalid password\n\nExpected result: login rejected \n\n* Testcase 3: provide invalid login ID and some valid password\n\nExpected result: login rejected\n\n* Testcase 4: provide no login ID and some valid password\n\nExpected result: login rejected\n\netc, etc.","timestamp":"2009-07-14T05:45:25+00:00","score":2}],"n_turns":4,"n_turns_after_thanks":1,"op_metadata":{"user_id":"anon_6570896f6a804f78","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_5c4b9e601ba994b3","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c0b2avf","thanks_reply_id":"c0b2b1j","post_score":0,"answer_score":7,"preferred_answer_is_top_level":true}}
{"user_id":"anon_554dfa212a04b826","answerer_user_id":"anon_a1d9edb20dbb1ed5","subreddit":"programming","timestamp":"2009-07-15T20:04:44+00:00","post_id":"91j2o","question":"Dear Proggit: How did you get into the field that you are in?\n\nI am at somewhat of a crossroads in life. I have been doing web dev for a few years now (im 18, started when I was 15) and I have a lot of fun with it. I suck at design, but I'm getting pretty good at web-apps and things of those sorts. But it is starting to hit me, that web isn't everything and I should probably look into things like C++ / Java / Python. I took 3 years of schooling during highschool for network admin stuff, and loved that as well.\n\nI spend the last 2 or 3 weeks teaching myself python, and just feel that everything that I have learned how to do, can be easily accomplished with my js/php skills (with obvious pros and cons of each) and am starting to feel that I should just stick with my web stuff and expand my knowledge in them.\n\nI really enjoy doing stuff in linux, as well as screwing around with things such as active directory, but am not sure if thats what I want to focus on for my career. I am just as much on the fence about if I want to do programming for my career, and if so, what languages / types?\n\nWhat I am trying to get to here is, did any of you find yourself asking the same sort of questions, and how did you figure out what you wanted to go into?\n\nMany people have told me that since I am fairly knowledgeable in so many areas (networking, programming, etc) that I should look into getting a management position somewhere, or at least go to school for management. What are your thoughts? Thanks!","preferred_answer":"I am also 21 and was in the OP's shoes.\n\nI thought I didn't want to program for the rest of my life. Everyone made it seem like it would be something I'd hate, something that would burn me out and not make much money. I thought I'd just be a code monkey.\n\nAnd maybe I will end up a code monkey someday. But I am not going to listen to those people right now, I'm too busy making my own future starting a software company.\n\nIf you love doing it, keep doing it. \n\nAnd go to college, and DON'T just stick with js/php. Forget that shit for now and learn C/++ on Linux and read this: http://www.advancedlinuxprogramming.com/ it will change the way you code.","full_conversation":[{"role":"OP","user_id":"anon_554dfa212a04b826","comment_id":"91j2o","kind":"post","text":"Dear Proggit: How did you get into the field that you are in?\n\nI am at somewhat of a crossroads in life. I have been doing web dev for a few years now (im 18, started when I was 15) and I have a lot of fun with it. I suck at design, but I'm getting pretty good at web-apps and things of those sorts. But it is starting to hit me, that web isn't everything and I should probably look into things like C++ / Java / Python. I took 3 years of schooling during highschool for network admin stuff, and loved that as well.\n\nI spend the last 2 or 3 weeks teaching myself python, and just feel that everything that I have learned how to do, can be easily accomplished with my js/php skills (with obvious pros and cons of each) and am starting to feel that I should just stick with my web stuff and expand my knowledge in them.\n\nI really enjoy doing stuff in linux, as well as screwing around with things such as active directory, but am not sure if thats what I want to focus on for my career. I am just as much on the fence about if I want to do programming for my career, and if so, what languages / types?\n\nWhat I am trying to get to here is, did any of you find yourself asking the same sort of questions, and how did you figure out what you wanted to go into?\n\nMany people have told me that since I am fairly knowledgeable in so many areas (networking, programming, etc) that I should look into getting a management position somewhere, or at least go to school for management. What are your thoughts? Thanks!","timestamp":"2009-07-15T20:04:44+00:00","score":7},{"role":"answerer","user_id":"anon_a1d9edb20dbb1ed5","comment_id":"c0b68lz","kind":"comment","text":"I am also 21 and was in the OP's shoes.\n\nI thought I didn't want to program for the rest of my life. Everyone made it seem like it would be something I'd hate, something that would burn me out and not make much money. I thought I'd just be a code monkey.\n\nAnd maybe I will end up a code monkey someday. But I am not going to listen to those people right now, I'm too busy making my own future starting a software company.\n\nIf you love doing it, keep doing it. \n\nAnd go to college, and DON'T just stick with js/php. Forget that shit for now and learn C/++ on Linux and read this: http://www.advancedlinuxprogramming.com/ it will change the way you code.","timestamp":"2009-07-17T19:46:35+00:00","score":3},{"role":"OP","user_id":"anon_554dfa212a04b826","comment_id":"c0b6kb0","kind":"comment","text":"Would you recommend C/++ over Python? Why?\n\nAnd thanks for the tips everyone!","timestamp":"2009-07-18T02:06:46+00:00","score":1},{"role":"answerer","user_id":"anon_a1d9edb20dbb1ed5","comment_id":"c0b7a2m","kind":"comment","text":"No. I just think you should have enough exposure with C because it will really change the way you program even in languages like Python. It's really important knowledge to have even if you don't end up using the language in practice. For all practical purposes I use python.","timestamp":"2009-07-19T01:20:39+00:00","score":2}],"n_turns":4,"n_turns_after_thanks":1,"op_metadata":{"user_id":"anon_554dfa212a04b826","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_a1d9edb20dbb1ed5","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c0b68lz","thanks_reply_id":"c0b6kb0","post_score":7,"answer_score":3,"preferred_answer_is_top_level":false}}
{"user_id":"anon_eddfc93c7c391367","answerer_user_id":"anon_fafb625cefebdf25","subreddit":"programming","timestamp":"2009-07-17T14:09:11+00:00","post_id":"923k3","question":"I need to learn Python for my senior design project. Anyone have any good book suggestions?","preferred_answer":"Seems like this gets asked every day, so I did a search and here is one of the first results:\n\nhttp://www.reddit.com/r/programming/comments/6xsnm/10_free_python_programming_books/","full_conversation":[{"role":"OP","user_id":"anon_eddfc93c7c391367","comment_id":"923k3","kind":"post","text":"I need to learn Python for my senior design project. Anyone have any good book suggestions?","timestamp":"2009-07-17T14:09:11+00:00","score":0},{"role":"answerer","user_id":"anon_fafb625cefebdf25","comment_id":"c0b5vgt","kind":"comment","text":"Seems like this gets asked every day, so I did a search and here is one of the first results:\n\nhttp://www.reddit.com/r/programming/comments/6xsnm/10_free_python_programming_books/","timestamp":"2009-07-17T14:17:49+00:00","score":1},{"role":"OP","user_id":"anon_eddfc93c7c391367","comment_id":"c0b5vwp","kind":"comment","text":"Thanks I saw that earlier, but I was looking for suggestions about good books rather than just free ones, but I appreciate the help.","timestamp":"2009-07-17T14:30:22+00:00","score":0},{"role":"answerer","user_id":"anon_fafb625cefebdf25","comment_id":"c0b5wie","kind":"comment","text":"Free can also be good. Assuming you're not already an experienced programmer, you might try this one:\n\nhttp://www.swaroopch.com/notes/Python","timestamp":"2009-07-17T14:45:20+00:00","score":1}],"n_turns":4,"n_turns_after_thanks":1,"op_metadata":{"user_id":"anon_eddfc93c7c391367","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_fafb625cefebdf25","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c0b5vgt","thanks_reply_id":"c0b5vwp","post_score":0,"answer_score":1,"preferred_answer_is_top_level":true}}
{"user_id":"anon_c524916d7cd8a9cf","answerer_user_id":"anon_f370586346069072","subreddit":"programming","timestamp":"2009-07-17T20:46:38+00:00","post_id":"927l6","question":"WTF? Is anyone else getting an \"attack site\" warning from Firefox for softwareliberty.org?","preferred_answer":"At the end of the page are a couple hidden iframes for \"reycross.cn\" and \"reycross.net\".\r\n\r\nhttp://www.google.com/safebrowsing/diagnostic?site=reycross.cn \r\nhttp://www.google.com/safebrowsing/diagnostic?site=reycross.net\r\n\r\nare both indicated as \"intermediaries\" in distributing infections.","full_conversation":[{"role":"OP","user_id":"anon_c524916d7cd8a9cf","comment_id":"927l6","kind":"post","text":"WTF? Is anyone else getting an \"attack site\" warning from Firefox for softwareliberty.org?","timestamp":"2009-07-17T20:46:38+00:00","score":0},{"role":"answerer","user_id":"anon_f370586346069072","comment_id":"c0b6c4k","kind":"comment","text":"At the end of the page are a couple hidden iframes for \"reycross.cn\" and \"reycross.net\".\r\n\r\nhttp://www.google.com/safebrowsing/diagnostic?site=reycross.cn \r\nhttp://www.google.com/safebrowsing/diagnostic?site=reycross.net\r\n\r\nare both indicated as \"intermediaries\" in distributing infections.","timestamp":"2009-07-17T21:16:02+00:00","score":10},{"role":"OP","user_id":"anon_c524916d7cd8a9cf","comment_id":"c0b6c8n","kind":"comment","text":"Ah, I see that, thanks. Probably injected and the owner doesn't even know. I had to wget the page because Firefox's view source command doesn't work on that page. That's scary. Do you know why by any chance?","timestamp":"2009-07-17T21:19:25+00:00","score":2},{"role":"answerer","user_id":"anon_f370586346069072","comment_id":"c0b6cbi","kind":"comment","text":"It worked for me in both iceweasel and opera. So no. I'm guessing that the hidden iframes added some scripts that did it for you. And it looks like they give different results in different contexts to try to hide what's being injected.","timestamp":"2009-07-17T21:21:27+00:00","score":2}],"n_turns":4,"n_turns_after_thanks":1,"op_metadata":{"user_id":"anon_c524916d7cd8a9cf","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_f370586346069072","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c0b6c4k","thanks_reply_id":"c0b6c8n","post_score":0,"answer_score":10,"preferred_answer_is_top_level":true}}
{"user_id":"anon_c669445eca2dc311","answerer_user_id":"anon_a5cdc5b079e8c08f","subreddit":"programming","timestamp":"2009-07-21T18:50:04+00:00","post_id":"9393s","question":"I'm a programmer/musician and I'm interested in getting into adaptive music for video games. Is anyone aware of any open source projects for that out there, and if not, would anyone be interested in helping to start one?","preferred_answer":"Yeah, and it's patented, and the patents are openly available. It's also been reverse engineered a bunch of times by the ScummVM people, and would serve as a good starting point.","full_conversation":[{"role":"OP","user_id":"anon_c669445eca2dc311","comment_id":"9393s","kind":"post","text":"I'm a programmer/musician and I'm interested in getting into adaptive music for video games. Is anyone aware of any open source projects for that out there, and if not, would anyone be interested in helping to start one?","timestamp":"2009-07-21T18:50:04+00:00","score":23},{"role":"answerer","user_id":"anon_a5cdc5b079e8c08f","comment_id":"c0ba6gs","kind":"comment","text":"Yeah, and it's patented, and the patents are openly available. It's also been reverse engineered a bunch of times by the ScummVM people, and would serve as a good starting point.","timestamp":"2009-07-22T01:01:35+00:00","score":2},{"role":"OP","user_id":"anon_c669445eca2dc311","comment_id":"c0ba6qj","kind":"comment","text":"Cool, thanks.","timestamp":"2009-07-22T01:11:50+00:00","score":1},{"role":"answerer","user_id":"anon_a5cdc5b079e8c08f","comment_id":"c0bba7h","kind":"comment","text":"For the latest version of reverse-engineered iMuse (although incomplete if I recall), see the sources of a project called \"Residual\", also by the ScummVM people.\n\nAs all other ScummVM code, Residual's code looks like a bowl of pubes.\n\nGood luck.","timestamp":"2009-07-23T00:35:59+00:00","score":1}],"n_turns":4,"n_turns_after_thanks":1,"op_metadata":{"user_id":"anon_c669445eca2dc311","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_a5cdc5b079e8c08f","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c0ba6gs","thanks_reply_id":"c0ba6qj","post_score":23,"answer_score":2,"preferred_answer_is_top_level":false}}
{"user_id":"anon_512ee47200738bbd","answerer_user_id":"anon_be37d5ef76d50e03","subreddit":"programming","timestamp":"2009-07-23T20:23:55+00:00","post_id":"93yw3","question":"Is Linux a practical OS for a non-programmer?\n\nI've read up on the many pros of a Linux system, but for someone who isn't looking to delve into source code, I'd love to hear the ups and downs from a more pragmatic perspective. Is it an easy OS to get used to? Does it compare in any significant ways to a Windows or MacOS? Is the learning curve sharp (programming/customizing wise)?\n\nThanks!\n\nEdit: Thanks for all your help /r/programming. I'm going to keep doing my research so I don't end up destroying my new computer, but I really appreciate many helpful pointers.","preferred_answer":"It's like mac OS, pretty much. You'll be fine.","full_conversation":[{"role":"OP","user_id":"anon_512ee47200738bbd","comment_id":"93yw3","kind":"post","text":"Is Linux a practical OS for a non-programmer?\n\nI've read up on the many pros of a Linux system, but for someone who isn't looking to delve into source code, I'd love to hear the ups and downs from a more pragmatic perspective. Is it an easy OS to get used to? Does it compare in any significant ways to a Windows or MacOS? Is the learning curve sharp (programming/customizing wise)?\n\nThanks!\n\nEdit: Thanks for all your help /r/programming. I'm going to keep doing my research so I don't end up destroying my new computer, but I really appreciate many helpful pointers.","timestamp":"2009-07-23T20:23:55+00:00","score":4},{"role":"answerer","user_id":"anon_be37d5ef76d50e03","comment_id":"c0bc8l6","kind":"comment","text":"It's like mac OS, pretty much. You'll be fine.","timestamp":"2009-07-23T20:27:54+00:00","score":2},{"role":"OP","user_id":"anon_512ee47200738bbd","comment_id":"c0bc8pu","kind":"comment","text":"Thanks for the quick response. Ideally I would like to learn to start customizing it myself (I've coded a little in the past, but nothing too crazy). Are there any good guides or resources that you would recommend?","timestamp":"2009-07-23T20:30:22+00:00","score":1},{"role":"answerer","user_id":"anon_be37d5ef76d50e03","comment_id":"c0bc8uq","kind":"comment","text":"[This will give you more than you need to know](http://www.reddit.com/r/programming/comments/8sfim/30_useful_unix_and_linux_tutorials_for_beginners/)","timestamp":"2009-07-23T20:33:07+00:00","score":2}],"n_turns":4,"n_turns_after_thanks":1,"op_metadata":{"user_id":"anon_512ee47200738bbd","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_be37d5ef76d50e03","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c0bc8l6","thanks_reply_id":"c0bc8pu","post_score":4,"answer_score":2,"preferred_answer_is_top_level":true}}
{"user_id":"anon_0fcca1c4542b2d60","answerer_user_id":"anon_b7185245d64181c4","subreddit":"programming","timestamp":"2009-07-25T07:06:03+00:00","post_id":"94exx","question":"Ask Reddit: Google Code, Sourceforge, GitHub, etc. or in-house (public) trac/svn. Which is best for commercial code about to be released under GPL?\n\nMy employers are making encouraging noises about releasing one of our smaller projects as open source code.\nThe business would like some web traffic in return. Is it better to host the code in-house (on a separate trac/svn VM)? What have other small companies done?\nHow flexible are the various public code-hosting providers in allowing links to commercial sites? Sourceforge seems to allow a project's website to be separately hosted from the project's code.\nIs Sourceforge as slow as it was three years ago?\nAre there other popular, fast and reliable code hosting sites (in addition to Google Code, Sourceforge and GitHub)?","preferred_answer":"I admit Git probably isn't very useful for playing outside, however if he intends to do some programming or any other creative task involving text based formats learning a modern system will save him lots of time in the future, more time for him to spend outside playing.","full_conversation":[{"role":"OP","user_id":"anon_0fcca1c4542b2d60","comment_id":"94exx","kind":"post","text":"Ask Reddit: Google Code, Sourceforge, GitHub, etc. or in-house (public) trac/svn. Which is best for commercial code about to be released under GPL?\n\nMy employers are making encouraging noises about releasing one of our smaller projects as open source code.\nThe business would like some web traffic in return. Is it better to host the code in-house (on a separate trac/svn VM)? What have other small companies done?\nHow flexible are the various public code-hosting providers in allowing links to commercial sites? Sourceforge seems to allow a project's website to be separately hosted from the project's code.\nIs Sourceforge as slow as it was three years ago?\nAre there other popular, fast and reliable code hosting sites (in addition to Google Code, Sourceforge and GitHub)?","timestamp":"2009-07-25T07:06:03+00:00","score":13},{"role":"answerer","user_id":"anon_b7185245d64181c4","comment_id":"c0be9yp","kind":"comment","text":"I admit Git probably isn't very useful for playing outside, however if he intends to do some programming or any other creative task involving text based formats learning a modern system will save him lots of time in the future, more time for him to spend outside playing.","timestamp":"2009-07-25T18:55:43+00:00","score":4},{"role":"OP","user_id":"anon_0fcca1c4542b2d60","comment_id":"c0bepyj","kind":"comment","text":"Thanks, I already use Git and like it, but at work we use SVN. If all the developers at work were familiar with Git, we would use GitHub in a flash. It would seem more straightforward to use an SVN repo.\nI haven't used half of the features of Git - does it have compelling benefits when the project is only ~2KLOC, no one else knows Git, and the project needs a central repo?","timestamp":"2009-07-26T06:35:56+00:00","score":1},{"role":"answerer","user_id":"anon_b7185245d64181c4","comment_id":"c0besvr","kind":"comment","text":"The most compelling \"feature\" I found is that you don't have to worry about anything but the contents of your commit when you commit, in particular you can make smaller commits whenever you either complete a single feature or reach a point you might want to return to. You do not have to worry about breaking other developer's build.\n\nYou do not have to worry about how your history will look once it is pushed to the server while you are working either because you can use git rebase -i to edit and squash commits later when you are done and add a more complete and structured commit message then.\n\nIn general your commit history tends to look a lot cleaner and is more usable for stuff like reverting a fix that is later found to cause trouble or for cherry-picking a fix from the development to the stable branch.","timestamp":"2009-07-26T09:24:33+00:00","score":1}],"n_turns":4,"n_turns_after_thanks":1,"op_metadata":{"user_id":"anon_0fcca1c4542b2d60","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_b7185245d64181c4","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c0be9yp","thanks_reply_id":"c0bepyj","post_score":13,"answer_score":4,"preferred_answer_is_top_level":false}}
{"user_id":"anon_702c04c0a47d0aa3","answerer_user_id":"anon_6fa7896054334b24","subreddit":"programming","timestamp":"2009-07-27T18:23:29+00:00","post_id":"9512q","question":"Proggit, how does the for and range() work in this situation in Python?\n\nPlease look at [this](http://docs.python.org/tutorial/controlflow.html#break-and-continue-statements-and-else-clauses-on-loops) example in the tutorial.\n\nHow does Python find the prime number?\n\nI understand that if it's `for n in range(2, 10):` and it gets to `for x in range(2, n):` with the `n` as 2, the list is empty because it can't count from 2 to 2 so it immediately goes to the `else` clause.\n\nHowever, how does it work if it's, for example, `for x in range(2, n)` with 3, or 5 as the `n`?\n\nDoes it go to `if n % x == 0:` and the `n` is for example 9, and it starts with 2 as per `for x in range(2, n):`? \n\nIf so, it's 1 because 9 % 2 = 1, but on the output it comes out as `9 equals 3 * 3` which only happens if it equals 0?\n\nPerhaps I'm looking at this too hard, but I can't quite wrap my head around this? How does the interpreter go through the `range()` list and identify which is a prime number or not?\n\nKeep in mind I'm a complete n00b and this is my first programming language, I'm just trying to keep learning.","preferred_answer":"So I am a bit confused about what your confused on but basically here is the flow:\n\n for n in range(2, 10):\n\nThis code loops through the numbers 2,3,4,5,6,7,8,9. For EACH number, n = that number and the following body of code is run.\n\n for x in range(2, n):\n\nThis code then sets up a new for loop going through the numbers 2...n. Each time the outer loop increments (eg. n goes from 2 to 3) a new inner loop is setup with the new n. So the first time it goes through it tests \"for x in range(2,2):\". The second time it goes through it tests \"for x in range(2,3):\" and so on.\n\nWithin the inner loop it checks to see if \"n % x == 0\". If that comes out as True, then the inner loop breaks which skips the \"else:\" section which comes after the inner loop. In the break case, the outer loop increments right away and a new inner loop is setup. If the remainder test evaluates to false, the break never occurs and the inner loop increments [x increments through the inner loops range(2, n)]. If the inner loop goes through all the numbers in the inner loop's \"range(2, n)\" without breaking then the \"else:\" statement is executed which says that n is a prime number. This is of course because n is not divisible by any number less than n (apart from n and 1).\n\nDoes that make sense?","full_conversation":[{"role":"OP","user_id":"anon_702c04c0a47d0aa3","comment_id":"9512q","kind":"post","text":"Proggit, how does the for and range() work in this situation in Python?\n\nPlease look at [this](http://docs.python.org/tutorial/controlflow.html#break-and-continue-statements-and-else-clauses-on-loops) example in the tutorial.\n\nHow does Python find the prime number?\n\nI understand that if it's `for n in range(2, 10):` and it gets to `for x in range(2, n):` with the `n` as 2, the list is empty because it can't count from 2 to 2 so it immediately goes to the `else` clause.\n\nHowever, how does it work if it's, for example, `for x in range(2, n)` with 3, or 5 as the `n`?\n\nDoes it go to `if n % x == 0:` and the `n` is for example 9, and it starts with 2 as per `for x in range(2, n):`? \n\nIf so, it's 1 because 9 % 2 = 1, but on the output it comes out as `9 equals 3 * 3` which only happens if it equals 0?\n\nPerhaps I'm looking at this too hard, but I can't quite wrap my head around this? How does the interpreter go through the `range()` list and identify which is a prime number or not?\n\nKeep in mind I'm a complete n00b and this is my first programming language, I'm just trying to keep learning.","timestamp":"2009-07-27T18:23:29+00:00","score":0},{"role":"answerer","user_id":"anon_6fa7896054334b24","comment_id":"c0bg469","kind":"comment","text":"So I am a bit confused about what your confused on but basically here is the flow:\n\n for n in range(2, 10):\n\nThis code loops through the numbers 2,3,4,5,6,7,8,9. For EACH number, n = that number and the following body of code is run.\n\n for x in range(2, n):\n\nThis code then sets up a new for loop going through the numbers 2...n. Each time the outer loop increments (eg. n goes from 2 to 3) a new inner loop is setup with the new n. So the first time it goes through it tests \"for x in range(2,2):\". The second time it goes through it tests \"for x in range(2,3):\" and so on.\n\nWithin the inner loop it checks to see if \"n % x == 0\". If that comes out as True, then the inner loop breaks which skips the \"else:\" section which comes after the inner loop. In the break case, the outer loop increments right away and a new inner loop is setup. If the remainder test evaluates to false, the break never occurs and the inner loop increments [x increments through the inner loops range(2, n)]. If the inner loop goes through all the numbers in the inner loop's \"range(2, n)\" without breaking then the \"else:\" statement is executed which says that n is a prime number. This is of course because n is not divisible by any number less than n (apart from n and 1).\n\nDoes that make sense?","timestamp":"2009-07-27T18:39:26+00:00","score":2},{"role":"OP","user_id":"anon_702c04c0a47d0aa3","comment_id":"c0bh8om","kind":"comment","text":"Yes, thank you!\n\nPlease tell me if I'm right in my conclusion:\n\n**Even if the first item in a list from 2 to 9 ends up being 1, if there is another item in the list that ends up 0, it goes to the else clause**\n\nThat's all I need to know!\n\nALSO: If it is true, how does this apply to Python in general? Does it always look for the 'if' in a range?","timestamp":"2009-07-28T18:29:44+00:00","score":1},{"role":"answerer","user_id":"anon_6fa7896054334b24","comment_id":"c0bhfr5","kind":"comment","text":"Essentially the else clause is for the for loop, not the if statement. So the if statement runs for every number 2...9. Only if none of those numbers result in 0 does the else statement run.\n\nThink about the for...else like this:\n\nLoop x through each of the numbers in the range (for statement). For each number in the range run a test against x (if statement). If all of the tests fail, then run a separate piece of code (else statement). \n\nThe for...else construct is like a very through if...else construct. I guess. :D\n\nAnything else?","timestamp":"2009-07-28T21:10:35+00:00","score":1}],"n_turns":4,"n_turns_after_thanks":1,"op_metadata":{"user_id":"anon_702c04c0a47d0aa3","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_6fa7896054334b24","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c0bg469","thanks_reply_id":"c0bh8om","post_score":0,"answer_score":2,"preferred_answer_is_top_level":true}}
{"user_id":"anon_2990e3fdd160682d","answerer_user_id":"anon_90b6f33ab4b294bf","subreddit":"programming","timestamp":"2009-07-29T01:06:06+00:00","post_id":"95h98","question":"What is programming in the real world actually like?\n\nI'm a high school senior, looking for colleges. I love programming, I love computer science. I want to study this in college, (hopefully Waterloo) my problem is I am not sure I really want to have a job as a programmer.\r\n\r\nI guess the big problem is I don't know what programmers actually *do* in the real world. Let me clarify: right now, I get to work on whatever I want, and only do things I think are interesting. \"Hey, I bet I can build a cellular automaton.\" \"Hey, I wonder if I can rewrite that program using only recursion.\" Hell, I love going on Project Euler.\r\n\r\nI find this stuff really interesting, but I'm worried that programming as a job will be nothing like this. It'll be working on boring projects with straightforward solutions. I don't want to spend the rest of my life writing code that isn't engaging or interesting.\r\n\r\nSo to all the professional programmers out there: are your jobs engaging? Are you presented with challenges where you have to be creative? Can I realistically expect to have an interesting job? What are your experiences?","preferred_answer":"It all depends on your skills, where you work, and what interests you. I've worked in business applications forever (started with ar/ap/gl/delivery system, did some point of sale systems, did some work on an insurance system, did some work on a mutual fund system, did some work on a business website, now I run/am a micro isv). \n\nBusiness applications can be boring, though the problems can be challenging by times. \n\nEarly in a business applications programming career don't expect to be in charge of much of anything. You might, if you're lucky, get to write an entire module on your own. Though typically you'll be assigned maintenance work (change module x to do y instead of z).\n\nA lot of business applications program is maintenance, though the systems tend to expand and grow... but that's really just \"big\" maintenance. Sometimes, though not often, the entire system will be replaced. \n\nSome of the systems I worked on were pretty big... the estimates to rewrite always came out in the 10 to 25 million range which the business just wasn't willing to commit to (risky risky).\n\nWhen you're interviewing for a job you should also be finding out what exactly the business wants you to do, what sort of work you'd be assigned, and so forth. If the job just isn't what you've been told (this has happened to me) you can either gut it out for a year/18 months or quit very early on (and \"forget\" to put them on your resume).\n\nWorking at startups can involve creating brand new software from the ground up. It can also involve lots of unpaid overtime and the company going bankrupt/laying people off.\n\nGetting a masters or PHD in compsci won't typically help you get a job... but you'll have spent a lot of years/money for skills that are not often required by typically programmers.\n\nFormal compsci stuff (ie. PHD track) typically requires excellent math. The research these folks do is very much about improving on existing algorithms and finding new/novel algorithms to solve existing problems. Some folks can stay in university doing this sort of research (and teaching) for ever. Check out \"restricted boltzmann machine\" (http://www.machinelearning.org/proceedings/icml2007/papers/407.pdf) for an example of serious AI/compsci research (there's also a google talk from Hinton that's very interesting: http://www.youtube.com/watch?v=AyzOUbkUf3M).\n\nWaterloo has an excellent coop program that you should definitely enroll in. It will take you longer, but the real world experience will be of serious use to you. Also Waterloo has a wide variety of compsci tracks... iirc software engineering is more aimed at business stuff, compsci more of a serious research track. Don't stay in the wrong one (ie. if you dislike the serious research stuff switch to engineering track... or vice versa).\n\nRead \"The Wealth Barber\" and save your money :)","full_conversation":[{"role":"OP","user_id":"anon_2990e3fdd160682d","comment_id":"95h98","kind":"post","text":"What is programming in the real world actually like?\n\nI'm a high school senior, looking for colleges. I love programming, I love computer science. I want to study this in college, (hopefully Waterloo) my problem is I am not sure I really want to have a job as a programmer.\r\n\r\nI guess the big problem is I don't know what programmers actually *do* in the real world. Let me clarify: right now, I get to work on whatever I want, and only do things I think are interesting. \"Hey, I bet I can build a cellular automaton.\" \"Hey, I wonder if I can rewrite that program using only recursion.\" Hell, I love going on Project Euler.\r\n\r\nI find this stuff really interesting, but I'm worried that programming as a job will be nothing like this. It'll be working on boring projects with straightforward solutions. I don't want to spend the rest of my life writing code that isn't engaging or interesting.\r\n\r\nSo to all the professional programmers out there: are your jobs engaging? Are you presented with challenges where you have to be creative? Can I realistically expect to have an interesting job? What are your experiences?","timestamp":"2009-07-29T01:06:06+00:00","score":365},{"role":"answerer","user_id":"anon_90b6f33ab4b294bf","comment_id":"c0bhosq","kind":"comment","text":"It all depends on your skills, where you work, and what interests you. I've worked in business applications forever (started with ar/ap/gl/delivery system, did some point of sale systems, did some work on an insurance system, did some work on a mutual fund system, did some work on a business website, now I run/am a micro isv). \n\nBusiness applications can be boring, though the problems can be challenging by times. \n\nEarly in a business applications programming career don't expect to be in charge of much of anything. You might, if you're lucky, get to write an entire module on your own. Though typically you'll be assigned maintenance work (change module x to do y instead of z).\n\nA lot of business applications program is maintenance, though the systems tend to expand and grow... but that's really just \"big\" maintenance. Sometimes, though not often, the entire system will be replaced. \n\nSome of the systems I worked on were pretty big... the estimates to rewrite always came out in the 10 to 25 million range which the business just wasn't willing to commit to (risky risky).\n\nWhen you're interviewing for a job you should also be finding out what exactly the business wants you to do, what sort of work you'd be assigned, and so forth. If the job just isn't what you've been told (this has happened to me) you can either gut it out for a year/18 months or quit very early on (and \"forget\" to put them on your resume).\n\nWorking at startups can involve creating brand new software from the ground up. It can also involve lots of unpaid overtime and the company going bankrupt/laying people off.\n\nGetting a masters or PHD in compsci won't typically help you get a job... but you'll have spent a lot of years/money for skills that are not often required by typically programmers.\n\nFormal compsci stuff (ie. PHD track) typically requires excellent math. The research these folks do is very much about improving on existing algorithms and finding new/novel algorithms to solve existing problems. Some folks can stay in university doing this sort of research (and teaching) for ever. Check out \"restricted boltzmann machine\" (http://www.machinelearning.org/proceedings/icml2007/papers/407.pdf) for an example of serious AI/compsci research (there's also a google talk from Hinton that's very interesting: http://www.youtube.com/watch?v=AyzOUbkUf3M).\n\nWaterloo has an excellent coop program that you should definitely enroll in. It will take you longer, but the real world experience will be of serious use to you. Also Waterloo has a wide variety of compsci tracks... iirc software engineering is more aimed at business stuff, compsci more of a serious research track. Don't stay in the wrong one (ie. if you dislike the serious research stuff switch to engineering track... or vice versa).\n\nRead \"The Wealth Barber\" and save your money :)","timestamp":"2009-07-29T01:42:15+00:00","score":4},{"role":"OP","user_id":"anon_2990e3fdd160682d","comment_id":"c0bhv1v","kind":"comment","text":"Thanks, this was really helpful. I love math, I'd love to do the whole PHD/research/new algorithm thing, but is this at all realistic? I mean, sure, some people do it and get paid well, but I imagine (and am afraid) that this is only available to an amazingly small percent of programmers. Can I *realistically* expect to be able to do anything interesting in a job? Do you?\r\n\r\nI don't mind the whole 9-5 thing, I do mind the whole 9-5 thing in a jobe I hate/am bored with.","timestamp":"2009-07-29T05:12:56+00:00","score":2},{"role":"answerer","user_id":"anon_90b6f33ab4b294bf","comment_id":"c0biarx","kind":"comment","text":"It is a difficult question to answer. I haven't run into many PHD's over the years... but a PHD wouldn't really be looking for work in my area (business applications/systems).\n\nThere is work for PHDs however. Microsoft has an excellent research group that does some amazing stuff. Google has more than a few PHDs. The National Research Council does lots of heavy research. In the States the gov't does lots of research (crypto is always hot... but that's 99.9% math).\n\nThe trick would be to study an area that can be applied to problem areas that companies or governments have to deal with. For example that Boltzmann machine stuff could be very useful to Google because of how it could be applied to large quantities of text (see the talk... at the end Hinton mentions a few possibilities).\n\nOne very important area that's hot now and will continue to be hot is modeling of DNA, proteins, etc (for example simulations of protein folding is very useful). The current biochemistry/molecular chemistry/medicine field is at the start of a big change... DNA sequencing the protein database and so forth is letting the science types really figure out how cells/groups of cells actually work at a chemical level. This stuff needs computers like you wouldn't believe.\n\nAnother is surveillance and sensing. A magic box that identifies \"terrorists\" or weapons would be a huge seller. Something that helps ports (ships and containers) tackle smuggling would be useful. Systems that consume lots and lots of data to produce answers are also useful (imagine what some clever software could do with the IRS information).\n\nLastly robotics will continue hot, with still lots of room for better algorithms and approaches. Walking robots (2 leg, 4 leg, more) and \"hands\" are getting lots of research dollars and military money. Unmanned flight is also doing very well... though by the time you get out of school this could be well settled.\n\nGenerally speaking it takes years for research grade compsci stuff to make it to the market. Hinton's stuff is a good example... he's been working on RBM's for ages... but it's only now starting to get a serious look by businesses. \n\nYou can make a ton of money simply by realizing that someone else's research could be applied to specific business problems. I can't usually make much out of compsci research papers (far to much math), let alone see how they might apply to a business problem... someone that can do both could do very well for themselves. Also being able to talk to business people and compsci people on their own \"levels\" is itself a very useful skill.\n\nTalk to the prof's, talk to the post grads doing research. The prof's could tell you where the PHDs students ended up working. The post grads can tell you where they hope to work. If you buy a post grad a beer they'll spill their guts (post grad's don't make a lot of money so free anything will perk them up).\n\nWaterloo is an excellent school if you want to do serious compsci stuff, there's few better (U of T is also good, MIT is the gold standard, and a few other US places). Work your ass of to get into Waterloo... there's no place better in Canada. If you're turned down it might be worth doing grade 12 again just to get in (assuming you can pull 90's the second time around). As a plus Waterloo's software engineering side of things makes you very desirable as a new hire.\n\nWork is work... it's not always going to be fun. Sometimes it can be a drag, sometimes for a few weeks at a time even. The people you work with can make up for that quite a bit. BUT... if you find yourself in a job you're just not enjoying look for another one. Typically people move around roughly every the 3 to 5 years. It's usually people feed up with the current job looking for something more interesting. Sometimes it's the economy/nature of the business. Programmers rarely stay unemployed unless they have bad references or are incompetent. Managers tend to be former programmers, and often former bad programmers. Read \"The rules of work\" for a heads up on how deal with that sort of stuff (\"office politics\" and so forth).\n\nYou can make a lot of money working as a programmer. If you're careful with your money and save sensibly you can retire early with a big chunk of cash. Or start your own business (very risky... most fail and the money is gone). Then you answer to no one, and can do what you like. The Wealth Barber book is a simple sound strategy for saving/financial management that will make you rich (in a whole lot of years... but you're young you have lots of years).","timestamp":"2009-07-29T16:02:53+00:00","score":1}],"n_turns":4,"n_turns_after_thanks":1,"op_metadata":{"user_id":"anon_2990e3fdd160682d","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_90b6f33ab4b294bf","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c0bhosq","thanks_reply_id":"c0bhv1v","post_score":365,"answer_score":4,"preferred_answer_is_top_level":true}}
{"user_id":"anon_cf7309560b3bbbb3","answerer_user_id":"anon_32b4436323c23404","subreddit":"programming","timestamp":"2009-07-29T16:19:02+00:00","post_id":"95os7","question":"Anyone work abroad and would recommend it?\n\nI'm thinking of working in either Australia or New Zealand, as a programmer ofc... Currently employed as programmer now and don't forsee any layoffs, but insurance isn't exactly my dream industry or anything. Recomend? Tips? etc..","preferred_answer":"As an Australian just going enter the industry for the first time, I have heard that there is quite a shortage in regards to IT, as in its one of the most sought after sort of people, mostly programmers.","full_conversation":[{"role":"OP","user_id":"anon_cf7309560b3bbbb3","comment_id":"95os7","kind":"post","text":"Anyone work abroad and would recommend it?\n\nI'm thinking of working in either Australia or New Zealand, as a programmer ofc... Currently employed as programmer now and don't forsee any layoffs, but insurance isn't exactly my dream industry or anything. Recomend? Tips? etc..","timestamp":"2009-07-29T16:19:02+00:00","score":15},{"role":"answerer","user_id":"anon_32b4436323c23404","comment_id":"c0bj5lb","kind":"comment","text":"As an Australian just going enter the industry for the first time, I have heard that there is quite a shortage in regards to IT, as in its one of the most sought after sort of people, mostly programmers.","timestamp":"2009-07-30T08:08:52+00:00","score":2},{"role":"OP","user_id":"anon_cf7309560b3bbbb3","comment_id":"c0bjfeb","kind":"comment","text":"Ah thanks. Are you on LinkedIn by any chance?","timestamp":"2009-07-30T15:39:35+00:00","score":1},{"role":"answerer","user_id":"anon_32b4436323c23404","comment_id":"c0bjwx9","kind":"comment","text":"Not on LinkedIn sorry.","timestamp":"2009-07-30T22:15:55+00:00","score":1}],"n_turns":4,"n_turns_after_thanks":1,"op_metadata":{"user_id":"anon_cf7309560b3bbbb3","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_32b4436323c23404","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c0bj5lb","thanks_reply_id":"c0bjfeb","post_score":15,"answer_score":2,"preferred_answer_is_top_level":false}}
{"user_id":"anon_bfebee80fcd961ab","answerer_user_id":"anon_0f10f9905588a7c9","subreddit":"programming","timestamp":"2009-08-02T15:45:39+00:00","post_id":"96u39","question":"Need help with a proof of concept\n\nI am writing a few proof of concept programs for the gamma programming language, which is based on a chemical reaction model of programming(this is being implemented in Java on top of IBMs TSpaces, but I don't think the TSpaces server was designed for hpc).\n\n\nWhat it boils down to is I can't think of any useful programs that fulfill the following requirements:\n\n1. large input data set\n\n2. input can be taken in randomly and operated on (and I assume then rewritten and operated on iteratively.)\n\n3. operation on data computationally intensive to create a speedup when done on a cluster\n\nThe same number of output as input is preferable, but more/fewer outputs would make it more interesting\n\nThe only thing I have found so far is a sorting program (that is (n^2)/p, where is is the number of processors and must be n/2 or less) and that never achieves a speedup to compensate for the networking/Java overhead.\n\nTechnically I am done with my summer research, but I have a week left, and I would like to do something that might be useful.\n\nedit:\n\nquick overview of the CRM:\n\ncomputation is a chemical reaction, and each 'molecule' is a compute node, so each node pulls N data elements(N=2 in the case of the sorter) randomly from a pool and operates on them, writes them back and repeats until the pool is 'inert' and no more calculations can be done.","preferred_answer":"Other simple options are matrix-matrix multiplication and matrix-vector multiplication. These require a slightly more sophisticated data distribution (look up Fox's algorithm).","full_conversation":[{"role":"OP","user_id":"anon_bfebee80fcd961ab","comment_id":"96u39","kind":"post","text":"Need help with a proof of concept\n\nI am writing a few proof of concept programs for the gamma programming language, which is based on a chemical reaction model of programming(this is being implemented in Java on top of IBMs TSpaces, but I don't think the TSpaces server was designed for hpc).\n\n\nWhat it boils down to is I can't think of any useful programs that fulfill the following requirements:\n\n1. large input data set\n\n2. input can be taken in randomly and operated on (and I assume then rewritten and operated on iteratively.)\n\n3. operation on data computationally intensive to create a speedup when done on a cluster\n\nThe same number of output as input is preferable, but more/fewer outputs would make it more interesting\n\nThe only thing I have found so far is a sorting program (that is (n^2)/p, where is is the number of processors and must be n/2 or less) and that never achieves a speedup to compensate for the networking/Java overhead.\n\nTechnically I am done with my summer research, but I have a week left, and I would like to do something that might be useful.\n\nedit:\n\nquick overview of the CRM:\n\ncomputation is a chemical reaction, and each 'molecule' is a compute node, so each node pulls N data elements(N=2 in the case of the sorter) randomly from a pool and operates on them, writes them back and repeats until the pool is 'inert' and no more calculations can be done.","timestamp":"2009-08-02T15:45:39+00:00","score":0},{"role":"answerer","user_id":"anon_0f10f9905588a7c9","comment_id":"c0bmq7a","kind":"comment","text":"Other simple options are matrix-matrix multiplication and matrix-vector multiplication. These require a slightly more sophisticated data distribution (look up Fox's algorithm).","timestamp":"2009-08-02T17:04:48+00:00","score":2},{"role":"OP","user_id":"anon_bfebee80fcd961ab","comment_id":"c0bms08","kind":"comment","text":"Thanks for the suggestions, but I don't see how those can be broken up in to data elements: individual entries in a matrix or columns/rows, in a way that will allow them to be randomly selected.","timestamp":"2009-08-02T18:08:43+00:00","score":1},{"role":"answerer","user_id":"anon_0f10f9905588a7c9","comment_id":"c0bmt05","kind":"comment","text":"Ah, ok I misunderstood. I thought you meant randomly generated. Thanks for the summary. Maybe a particle simulation? Although I guess you would have difficulties handling interaction between particles.","timestamp":"2009-08-02T18:42:01+00:00","score":2}],"n_turns":4,"n_turns_after_thanks":1,"op_metadata":{"user_id":"anon_bfebee80fcd961ab","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_0f10f9905588a7c9","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c0bmq7a","thanks_reply_id":"c0bms08","post_score":0,"answer_score":2,"preferred_answer_is_top_level":true}}
{"user_id":"anon_f18e3d4d7027361d","answerer_user_id":"anon_335af4469863a4ba","subreddit":"programming","timestamp":"2009-08-02T17:17:34+00:00","post_id":"96upw","question":"Numerically integrate a function until certain value?","preferred_answer":"And, I suppose you'll want a first guess. How about treating the function as a rectangle first:\n\n target = f(a) * (b-a)\n ...\n b = (a*f(a) + target)/f(a)\n\nThen, you can find a good value of h as above.\n\nYou can add another step to make the first guess better by finding b as above, and then using linear interpolation to refine the value of b.","full_conversation":[{"role":"OP","user_id":"anon_f18e3d4d7027361d","comment_id":"96upw","kind":"post","text":"Numerically integrate a function until certain value?","timestamp":"2009-08-02T17:17:34+00:00","score":0},{"role":"answerer","user_id":"anon_335af4469863a4ba","comment_id":"c0bmu1q","kind":"comment","text":"And, I suppose you'll want a first guess. How about treating the function as a rectangle first:\n\n target = f(a) * (b-a)\n ...\n b = (a*f(a) + target)/f(a)\n\nThen, you can find a good value of h as above.\n\nYou can add another step to make the first guess better by finding b as above, and then using linear interpolation to refine the value of b.","timestamp":"2009-08-02T19:16:27+00:00","score":1},{"role":"OP","user_id":"anon_f18e3d4d7027361d","comment_id":"c0bmzf1","kind":"comment","text":"Hi, soapdish. Thank you for your responses.\n\nThis is pretty much the same thing that I invented from scratch. The rectangle idea is a good one.\n\nI was asking just in case, there was some super clever method that I was overlooking but I guess to some extent there's not.\n\nIt's a hard question to Google search for the answer because there are simply too many unrelated hits.\n\nCheers.","timestamp":"2009-08-02T22:18:09+00:00","score":1},{"role":"answerer","user_id":"anon_335af4469863a4ba","comment_id":"c0bn0v3","kind":"comment","text":"What exactly are you using it for? Maybe there's a completely different method to find what you need.","timestamp":"2009-08-02T23:11:20+00:00","score":1},{"role":"OP","user_id":"anon_f18e3d4d7027361d","comment_id":"c0bn2v1","kind":"comment","text":"I'm calculating 68%, 95%, and 99% confidence intervals (with equally likely error above or below the CI). The distribution does not have an anti-derivative.\n\nMy current code already works to find the numbers but I'm a real stickler for beautiful code. Not only for aesthetic appeal but because I frequently find that I can more easily re-use well-written code. I assumed that some dead mathematician would have his name attached to my particular problem but guess not. I should put mine version in print. How does the Turd Burglar Algorithm sound?","timestamp":"2009-08-03T00:25:55+00:00","score":1}],"n_turns":5,"n_turns_after_thanks":2,"op_metadata":{"user_id":"anon_f18e3d4d7027361d","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_335af4469863a4ba","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c0bmu1q","thanks_reply_id":"c0bmzf1","post_score":0,"answer_score":1,"preferred_answer_is_top_level":false}}
{"user_id":"anon_cf1145d96f5f8ded","answerer_user_id":"anon_3796730c35f729be","subreddit":"programming","timestamp":"2009-08-03T04:56:39+00:00","post_id":"96yyg","question":"What DIDN'T college teach you about programming/computers? [asked by a College Student]","preferred_answer":"The biggest blindspot college usually teach you is that they'll tell you that all languages are the same thing with a different syntax and that if you know one, you can learn any of them very quickly.\n\nThis is bullshit. If they were the same thing, there would be no reason to have more than one language and don't ever believe that because you know the syntax of a language, you can write proper, idiomatic code in it.","full_conversation":[{"role":"OP","user_id":"anon_cf1145d96f5f8ded","comment_id":"96yyg","kind":"post","text":"What DIDN'T college teach you about programming/computers? [asked by a College Student]","timestamp":"2009-08-03T04:56:39+00:00","score":120},{"role":"answerer","user_id":"anon_3796730c35f729be","comment_id":"c0bnb6m","kind":"comment","text":"The biggest blindspot college usually teach you is that they'll tell you that all languages are the same thing with a different syntax and that if you know one, you can learn any of them very quickly.\n\nThis is bullshit. If they were the same thing, there would be no reason to have more than one language and don't ever believe that because you know the syntax of a language, you can write proper, idiomatic code in it.","timestamp":"2009-08-03T05:16:53+00:00","score":24},{"role":"OP","user_id":"anon_cf1145d96f5f8ded","comment_id":"c0bnbfp","kind":"comment","text":"Thanks! So, if I experience in C++ and Java, what are the languages that are different? And, which one of those would you recommend taking a look into?","timestamp":"2009-08-03T05:26:43+00:00","score":9},{"role":"answerer","user_id":"anon_3796730c35f729be","comment_id":"c0bncec","kind":"comment","text":"Many actually! In no particular order:\n\nPython. It's a scripting language that's meant to be very easy to write and to read. It's much more expressive than C++ or Java so you can finish your program in much less lines (as little as 1/10th of your C++ program).\n\nYou can pick it up easily from the [tutorial](http://docs.python.org/3.1/tutorial/) and once you are done you can read Mark Pilgrim's [Dive into Python 3](http://diveintopython3.org/) for free on his site. If you don't start with Python, still read the chapter about [Why everything you know about strings is wrong](http://diveintopython3.org/strings.html) as soon as possible because that's a critical thing that's valid in all languages they certainly won't teach you in college.\n\nHaskell. It's *the* functional language you have to learn. Functional programming is inspired by math (lambda calculus more precisely) radically different paradigm from Object Oriented (what do you mean I can't change my variable? Where's my for loop? Hey, did you pass an infinite list will *all* the prime numbers to infinity to that function?) and learning Haskell should give you a brand new perspective on programming, even in non-functional languages. The weakness of Haskell for someone who wants to learn it is that they suck at communicating with mere mortals so even if the language itself is not that hard, it may be hard to grok because sometimes, the explanation given is just undecipherable.\n\nThat said, try it whatever you learn from it will be valuable. The best book in know about it (also freely available) is [Real World Haskell](http://book.realworldhaskell.org/).\n\nD. If you want a language that compile to native executable with the same performance as C/C++ but that is much more expressive and makes it much harder to shoot yourself in the foot because of brain damaged feature that have to be kept for backward compatibility, D is the language. However, it's a young language, doesn't have much libraries for it yet and version 2 (which is a great improvement over version 1) is still in beta so you might keep an eye on that one until it's released.\n\nClojure. It's a modern Lisp (which means it has been clean of lots of the cruft of old Lisps) and this means that in it code is data and data is code. This may seem cryptic for now but it's also going to be enlightening when you can really understand what it means. It runs on the JVM which mean you can call your Java code from it and it's especially designed for concurrency.\n\nThe only book, as far as I know (but it's a great book) is [Programming Clojure](http://www.pragprog.com/titles/shcloj/programming-clojure) (not free).\n\nQt. Actually, Qt is not a language, it's a cross-platform C++ framework for building GUI apps but it rewrites lots of bad standard part of C++ and makes C++ a much better language to use.\n\nThe book you want for this one is [C++ GUI Programming with Qt 4 (2nd Edition)](http://www.amazon.com/Programming-Prentice-Source-Software-Development/dp/0132354160/ref=pd_sim_b_3)\n\nThat should be a bunch of fairly different from each other languages to learn, start from wherever you feel like.","timestamp":"2009-08-03T06:03:27+00:00","score":41}],"n_turns":4,"n_turns_after_thanks":1,"op_metadata":{"user_id":"anon_cf1145d96f5f8ded","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_3796730c35f729be","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c0bnb6m","thanks_reply_id":"c0bnbfp","post_score":120,"answer_score":24,"preferred_answer_is_top_level":false}}
{"user_id":"anon_2f68cb46e9f6fa22","answerer_user_id":"anon_83b11300c88fbedb","subreddit":"programming","timestamp":"2009-08-03T21:56:15+00:00","post_id":"97758","question":"AskProgrammers: What's a good library to build PDFs?\n\nI just want to make a straightforward layout of images, but I'd like to have good control of the image's position and dimensions. The libraries I've found are a little convoluted when it comes to dealing with images. A .NET library would be ideal, I'm working in C#. But not absolutely necessary.","preferred_answer":"iText.NET -- it will do anything you want it to do. Images, Form Fields, javascript, you name it. Best PDF library I have ever used and it is written in C#. Enjoy","full_conversation":[{"role":"OP","user_id":"anon_2f68cb46e9f6fa22","comment_id":"97758","kind":"post","text":"AskProgrammers: What's a good library to build PDFs?\n\nI just want to make a straightforward layout of images, but I'd like to have good control of the image's position and dimensions. The libraries I've found are a little convoluted when it comes to dealing with images. A .NET library would be ideal, I'm working in C#. But not absolutely necessary.","timestamp":"2009-08-03T21:56:15+00:00","score":8},{"role":"answerer","user_id":"anon_83b11300c88fbedb","comment_id":"c0bnyd4","kind":"comment","text":"iText.NET -- it will do anything you want it to do. Images, Form Fields, javascript, you name it. Best PDF library I have ever used and it is written in C#. Enjoy","timestamp":"2009-08-03T22:17:24+00:00","score":10},{"role":"OP","user_id":"anon_2f68cb46e9f6fa22","comment_id":"c0bnyoe","kind":"comment","text":"Great, thanks very much!\n\nEDIT: [iText.NET PDF creator for C# .NET home page](http://www.ujihara.jp/iTextdotNET/en/)","timestamp":"2009-08-03T22:33:26+00:00","score":3},{"role":"answerer","user_id":"anon_83b11300c88fbedb","comment_id":"c0bnz71","kind":"comment","text":"I actually meant iTextSharp. Sorry for the confusion. It is just like iText (Java) and iText.NET (java port to J#), but iTextSharp is the C# version.","timestamp":"2009-08-03T22:49:55+00:00","score":6}],"n_turns":4,"n_turns_after_thanks":1,"op_metadata":{"user_id":"anon_2f68cb46e9f6fa22","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_83b11300c88fbedb","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c0bnyd4","thanks_reply_id":"c0bnyoe","post_score":8,"answer_score":10,"preferred_answer_is_top_level":true}}
{"user_id":"anon_9f6b30ed0aad11dd","answerer_user_id":"anon_db184f2c30e9aa89","subreddit":"programming","timestamp":"2009-08-04T18:10:53+00:00","post_id":"97hnt","question":"Can't Figure Out This AppleScript Error\n\n[EDIT] I can't figure out how to keep the formatting when I paste into Reddit. Sorry, trying to redo it.\n[EDIT x2] This is the best I can do with formatting, sorry it takes up so much space.\n\nSo here's what will compile (although the Growl portion doesn't work):\n\nset beth to \"eppc://user:pass@address\"\n\nset brian to \"eppc://user:pass@address\"\n\nset molly to \"eppc://user:pass@address\"\n\nset sarah to \"eppc://user:pass@address\"\n\n\n\n\nset theList to choose from list {\"brian\", \"beth\", \"molly\", \"sarah\"} \n with title \"Messaging Service\" with multiple selections allowed\nrepeat with i in theList\n\n\tif (i as text) is equal to \"brian\" then\n\n\t\tset machine_chosen to brian\n\n\t\tset user to (i as text)\n\n\telse if (i as text) is equal to \"beth\" then\n\n\t\tset machine_chosen to beth\n\n\t\tset user to (i as text)\n\n\telse if (i as text) is equal to \"molly\" then\n\n\t\tset machine_chosen to molly\n\n\t\tset user to (i as text)\n\n\telse if (i as text) is equal to \"sarah\" then\n\n\t\tset machine_chosen to sarah\n\n\t\tset user to (i as text)\n\n\tend if\n\n\tdisplay dialog (\"Messaging \" & user) default answer \"How are you doing\" buttons ¬\n\n\t\t{\"Cancel\", \"Send\"} default button 2\n\n\ttry\n\n\t\tcopy the result as list to {text_returned, button_pressed}\n\n\t\ttell application \"Finder\" of machine machine_chosen\n\n\t\t\tactivate\n\n\t\t\tdo shell script (say text_returned) password \"\" with administrator privileges\n\n\t\t\t#do shell script (say \"They're always in the last place you look, you know.\")\n\n\t\tend tell\n\t\ttell application \"GrowlHelperApp\"\n\t\t\t-- Make a list of all the notification types \n\t\t\t-- that this script will ever send:\n\t\t\tset the allNotificationsList to ¬\n\t\t\t\t{\"Test Notification\", \"Another Test Notification\"}\n\t\t\t\n\t\t\t-- Make a list of the notifications \n\t\t\t-- that will be enabled by default. \n\t\t\t-- Those not enabled by default can be enabled later \n\t\t\t-- in the 'Applications' tab of the growl prefpane.\n\t\t\tset the enabledNotificationsList to ¬\n\t\t\t\t{\"Test Notification\"}\n\t\t\t\n\t\t\t-- Register our script with growl.\n\t\t\t-- You can optionally (as here) set a default icon \n\t\t\t-- for this script's notifications.\n\t\t\tregister as application ¬\n\t\t\t\t\"Growl AppleScript Sample\" all notifications allNotificationsList ¬\n\t\t\t\tdefault notifications enabledNotificationsList ¬\n\t\t\t\ticon of application \"Script Editor\"\n\t\t\t\n\t\t\t--\tSend a Notification...\n\t\t\tnotify with name ¬\n\t\t\t\t\"Test Notification\" title ¬\n\t\t\t\t\"Test Notification\" description ¬\n\t\t\t\t\"This is a test AppleScript notification.\" application name \"Growl AppleScript Sample\"\n\t\t\t\n\t\t\tnotify with name ¬\n\t\t\t\t\"Another Test Notification\" title ¬\n\t\t\t\t\"Another Test Notification :) \" description ¬\n\t\t\t\t\"Alas — you won't see me until you enable me...\" application name \"Growl AppleScript Sample\"\n\t\t\t\n\t\tend tell\n\tend try\n\tset theList to rest of theList\nend repeat\n\nWhen I try to change the first Growl line to:\ntell application \"GrowlHelperApp\" of machine machine_chosen\n\nI get the error: Expected end of line, etc. but found “\"”.\n\nYes, it's very basic and kluj-y and there's a lot I could do better, but I'm trying to do one thing at a time. \n\nPlease note that the Growl tell, by itself, will run in a separate script WITH the \"of machine X\" inclusion.\n\nThanks for your help, Reddit!","preferred_answer":"What happens if you move the remote \"GrowlHelperApp\" tell block inside the remote \"Finder\" tell block?\n\nIs it possible to save the remote application reference in a variable that you can \"tell\" later on? e.g. set remoteGrowl to application \"GrowlHelperApp\" of machine machine_chosen\n\nAs a last resort, you can use do shell script on the remote machine with a shell script that uses osascript to compile and run the AppleScript driving GrowlHelperApp on-the-fly","full_conversation":[{"role":"OP","user_id":"anon_9f6b30ed0aad11dd","comment_id":"97hnt","kind":"post","text":"Can't Figure Out This AppleScript Error\n\n[EDIT] I can't figure out how to keep the formatting when I paste into Reddit. Sorry, trying to redo it.\n[EDIT x2] This is the best I can do with formatting, sorry it takes up so much space.\n\nSo here's what will compile (although the Growl portion doesn't work):\n\nset beth to \"eppc://user:pass@address\"\n\nset brian to \"eppc://user:pass@address\"\n\nset molly to \"eppc://user:pass@address\"\n\nset sarah to \"eppc://user:pass@address\"\n\n\n\n\nset theList to choose from list {\"brian\", \"beth\", \"molly\", \"sarah\"} \n with title \"Messaging Service\" with multiple selections allowed\nrepeat with i in theList\n\n\tif (i as text) is equal to \"brian\" then\n\n\t\tset machine_chosen to brian\n\n\t\tset user to (i as text)\n\n\telse if (i as text) is equal to \"beth\" then\n\n\t\tset machine_chosen to beth\n\n\t\tset user to (i as text)\n\n\telse if (i as text) is equal to \"molly\" then\n\n\t\tset machine_chosen to molly\n\n\t\tset user to (i as text)\n\n\telse if (i as text) is equal to \"sarah\" then\n\n\t\tset machine_chosen to sarah\n\n\t\tset user to (i as text)\n\n\tend if\n\n\tdisplay dialog (\"Messaging \" & user) default answer \"How are you doing\" buttons ¬\n\n\t\t{\"Cancel\", \"Send\"} default button 2\n\n\ttry\n\n\t\tcopy the result as list to {text_returned, button_pressed}\n\n\t\ttell application \"Finder\" of machine machine_chosen\n\n\t\t\tactivate\n\n\t\t\tdo shell script (say text_returned) password \"\" with administrator privileges\n\n\t\t\t#do shell script (say \"They're always in the last place you look, you know.\")\n\n\t\tend tell\n\t\ttell application \"GrowlHelperApp\"\n\t\t\t-- Make a list of all the notification types \n\t\t\t-- that this script will ever send:\n\t\t\tset the allNotificationsList to ¬\n\t\t\t\t{\"Test Notification\", \"Another Test Notification\"}\n\t\t\t\n\t\t\t-- Make a list of the notifications \n\t\t\t-- that will be enabled by default. \n\t\t\t-- Those not enabled by default can be enabled later \n\t\t\t-- in the 'Applications' tab of the growl prefpane.\n\t\t\tset the enabledNotificationsList to ¬\n\t\t\t\t{\"Test Notification\"}\n\t\t\t\n\t\t\t-- Register our script with growl.\n\t\t\t-- You can optionally (as here) set a default icon \n\t\t\t-- for this script's notifications.\n\t\t\tregister as application ¬\n\t\t\t\t\"Growl AppleScript Sample\" all notifications allNotificationsList ¬\n\t\t\t\tdefault notifications enabledNotificationsList ¬\n\t\t\t\ticon of application \"Script Editor\"\n\t\t\t\n\t\t\t--\tSend a Notification...\n\t\t\tnotify with name ¬\n\t\t\t\t\"Test Notification\" title ¬\n\t\t\t\t\"Test Notification\" description ¬\n\t\t\t\t\"This is a test AppleScript notification.\" application name \"Growl AppleScript Sample\"\n\t\t\t\n\t\t\tnotify with name ¬\n\t\t\t\t\"Another Test Notification\" title ¬\n\t\t\t\t\"Another Test Notification :) \" description ¬\n\t\t\t\t\"Alas — you won't see me until you enable me...\" application name \"Growl AppleScript Sample\"\n\t\t\t\n\t\tend tell\n\tend try\n\tset theList to rest of theList\nend repeat\n\nWhen I try to change the first Growl line to:\ntell application \"GrowlHelperApp\" of machine machine_chosen\n\nI get the error: Expected end of line, etc. but found “\"”.\n\nYes, it's very basic and kluj-y and there's a lot I could do better, but I'm trying to do one thing at a time. \n\nPlease note that the Growl tell, by itself, will run in a separate script WITH the \"of machine X\" inclusion.\n\nThanks for your help, Reddit!","timestamp":"2009-08-04T18:10:53+00:00","score":0},{"role":"answerer","user_id":"anon_db184f2c30e9aa89","comment_id":"c0bp7ll","kind":"comment","text":"What happens if you move the remote \"GrowlHelperApp\" tell block inside the remote \"Finder\" tell block?\n\nIs it possible to save the remote application reference in a variable that you can \"tell\" later on? e.g. set remoteGrowl to application \"GrowlHelperApp\" of machine machine_chosen\n\nAs a last resort, you can use do shell script on the remote machine with a shell script that uses osascript to compile and run the AppleScript driving GrowlHelperApp on-the-fly","timestamp":"2009-08-04T21:59:34+00:00","score":1},{"role":"OP","user_id":"anon_9f6b30ed0aad11dd","comment_id":"c0bpcek","kind":"comment","text":"Thanks for the suggestions, but:\n-Moving the Growl tell inside the Finder tell doesn't make a difference\n-Making a remoteGrowl replace doesn't make a difference\n\nI'll look into the osascript option, any ideas?\n\nThanks for the response. :)","timestamp":"2009-08-05T00:03:02+00:00","score":0},{"role":"answerer","user_id":"anon_db184f2c30e9aa89","comment_id":"c0bu1ke","kind":"comment","text":"Be prepared to do some quote escaping.\n\nEssentially, you would \"do shell script\" on the remote machine, just like you've tried with the \"say\" command up there.\n\nHowever, the shell script you would run will echo the source text of the AppleScript you want to run into a pipe to the osascript command. osascript will compile the AppleScript passed into its stdin by the pipe and then execute it.","timestamp":"2009-08-09T00:10:06+00:00","score":1}],"n_turns":4,"n_turns_after_thanks":1,"op_metadata":{"user_id":"anon_9f6b30ed0aad11dd","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_db184f2c30e9aa89","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c0bp7ll","thanks_reply_id":"c0bpcek","post_score":0,"answer_score":1,"preferred_answer_is_top_level":true}}
{"user_id":"anon_43c3dbfba7a7d947","answerer_user_id":"anon_6576462014878bec","subreddit":"programming","timestamp":"2009-08-05T20:23:20+00:00","post_id":"97vio","question":"What are the best introductions to Evolutionary Algorithmns/Genetic Programming?","preferred_answer":"It's a little like asking for a list of the books needed to be proficient in math: it's a wide and deep group of fields, not a single field.\n\nIf you're looking to jump right in, one good place to start is \"Practical Genetic Algorithms\" by Haupt.\n\nBanzhaf/Norton's \"Genetic Programming: An Introduction\" is a decent place to get started, as is Langdon's \"Foundations of Genetic Programming\". Riolo/Warzel's \"Genetic Programming Theory and Practice\" is pretty good, but a bit dense, so not a great place to start. (The later books in that series get better both in content and in ease of reading.) Baoding Lu's \"Theory and Practice of Uncertain Programming\" is great, but not beginner's material.\n\nFogel's \"Blondie24: Playing at the Edge of AI\" and \"Evolutionary Computation: Toward a New Philosophy of Machine Intelligence\" are both great, though the former is much easier than the latter, and written in more of a prose form; Blondie is actually palattable enough that people who aren't programmers can take a fair amount from it, and I recommend it frequently.\n\nEiben's \"Introduction to Evolutionary Computing\" is pretty good, though it sets the learning curve initially very low, and the way in which it assumes so little of the student frequently turns more experienced programmers off, so if you've a long traditional programming background, you might skip it.\n\nOnce you're a bit more solid on your feet, you can move on to more complete books, like Zbigniew Michalewicz' \"How to Solve It: Modern Heuristics\", Koza's \"Genetic Programming: On the Programming of Computers by Means of Natural Selection\", Poli's \"A Field Guide to Genetic Programming\", et cetera. I've heard good things from people I trust about Goldberg's \"Genetic Algorithms in Search, Optimization, and Machine Learning\", though I've not read it myself.\n\nWhen you start getting serious, it's time to play hardball. This includes things like \"Evolutionary Dynamics: Exploring the Equations of Life\" by Nowak, Hastie's \"The Elements of Statistical Learning: Data Mining, Inference, and Prediction\", or Russel/Norwig's classic \"Artificial Intelligence: A Modern Approach\".\n\nBut, I mean, genetic programming is a small subfield of a larger group, machine learning techniques. I wonder whether you realize you're excluding large blocks of interesting other crap. Ant search algoriths, emergent flocking, various forms of automatic pattern classification, modal clustering, etc. It may be appropriate to take some more general books on, as a way to get a flavor for other related fields you might want to search. Good books to that end include Alpaydin's \"Introduction to Machine Learning\", Bishop's \"Pattern Recognition and Machine Learning\", \n\nDuda/Hart's \"Pattern Classification\", Bishop's \"Neural Networks for Pattern Recognition\", Witten/Frank's \"Data Mining: Practical Machine Learning Tools and Techniques\", Schlkoph/Smola's \"Learning with Kernels: Support Vector Machines, Regularization, Optimization, and Beyond\", Hastie/Tibshirani/Friedman's \"The Elements of Statistical Learning: Data Mining, Inference, and Prediction, Second Edition\", Gelman's \"Bayesian Data Analysis\", Dorigo's \"Ant Colony Optimization\", Clerc's \"Particle Swarm Optimization\", Price/Storm/Lampinen's \"Differential Evolution: A Practical Approach to Global Optimization\", Engelbrecht's \"Fundamentals of Computational Swarm Intelligence\", Bonobeau/Dorigo/Theauraz' \"Swarm Intelligence: From Natural to Artificial Systems\" and Casella's \"Statistical Inference\" are all examples of books that don't fit your question, but which I'm guessing you might really dig anyway.\n\nBooks on similar topics from the perspective of math people instead of computer people, if you can work with those, are also very valuable. Consider \"Nonlinear Dynamics And Chaos: With Applications To Physics, Biology, Chemistry, And Engineering\", \"Calculus of Variations\" and \"Complex Adaptive Systems: An Introduction to Computational Models of Social Life\". Oddly, a market book is also fascinating in this direction: \"Origin of Wealth: Evolution, Complexity, and Economics.\"\n\nYou may need some statistics background. Wasserman's \"All of Statistics\" is a great place to get started.\n\nThat should get you underway. If you need more, ask my blog, http://fullof.bs/ .","full_conversation":[{"role":"OP","user_id":"anon_43c3dbfba7a7d947","comment_id":"97vio","kind":"post","text":"What are the best introductions to Evolutionary Algorithmns/Genetic Programming?","timestamp":"2009-08-05T20:23:20+00:00","score":0},{"role":"answerer","user_id":"anon_6576462014878bec","comment_id":"c0brjvm","kind":"comment","text":"It's a little like asking for a list of the books needed to be proficient in math: it's a wide and deep group of fields, not a single field.\n\nIf you're looking to jump right in, one good place to start is \"Practical Genetic Algorithms\" by Haupt.\n\nBanzhaf/Norton's \"Genetic Programming: An Introduction\" is a decent place to get started, as is Langdon's \"Foundations of Genetic Programming\". Riolo/Warzel's \"Genetic Programming Theory and Practice\" is pretty good, but a bit dense, so not a great place to start. (The later books in that series get better both in content and in ease of reading.) Baoding Lu's \"Theory and Practice of Uncertain Programming\" is great, but not beginner's material.\n\nFogel's \"Blondie24: Playing at the Edge of AI\" and \"Evolutionary Computation: Toward a New Philosophy of Machine Intelligence\" are both great, though the former is much easier than the latter, and written in more of a prose form; Blondie is actually palattable enough that people who aren't programmers can take a fair amount from it, and I recommend it frequently.\n\nEiben's \"Introduction to Evolutionary Computing\" is pretty good, though it sets the learning curve initially very low, and the way in which it assumes so little of the student frequently turns more experienced programmers off, so if you've a long traditional programming background, you might skip it.\n\nOnce you're a bit more solid on your feet, you can move on to more complete books, like Zbigniew Michalewicz' \"How to Solve It: Modern Heuristics\", Koza's \"Genetic Programming: On the Programming of Computers by Means of Natural Selection\", Poli's \"A Field Guide to Genetic Programming\", et cetera. I've heard good things from people I trust about Goldberg's \"Genetic Algorithms in Search, Optimization, and Machine Learning\", though I've not read it myself.\n\nWhen you start getting serious, it's time to play hardball. This includes things like \"Evolutionary Dynamics: Exploring the Equations of Life\" by Nowak, Hastie's \"The Elements of Statistical Learning: Data Mining, Inference, and Prediction\", or Russel/Norwig's classic \"Artificial Intelligence: A Modern Approach\".\n\nBut, I mean, genetic programming is a small subfield of a larger group, machine learning techniques. I wonder whether you realize you're excluding large blocks of interesting other crap. Ant search algoriths, emergent flocking, various forms of automatic pattern classification, modal clustering, etc. It may be appropriate to take some more general books on, as a way to get a flavor for other related fields you might want to search. Good books to that end include Alpaydin's \"Introduction to Machine Learning\", Bishop's \"Pattern Recognition and Machine Learning\", \n\nDuda/Hart's \"Pattern Classification\", Bishop's \"Neural Networks for Pattern Recognition\", Witten/Frank's \"Data Mining: Practical Machine Learning Tools and Techniques\", Schlkoph/Smola's \"Learning with Kernels: Support Vector Machines, Regularization, Optimization, and Beyond\", Hastie/Tibshirani/Friedman's \"The Elements of Statistical Learning: Data Mining, Inference, and Prediction, Second Edition\", Gelman's \"Bayesian Data Analysis\", Dorigo's \"Ant Colony Optimization\", Clerc's \"Particle Swarm Optimization\", Price/Storm/Lampinen's \"Differential Evolution: A Practical Approach to Global Optimization\", Engelbrecht's \"Fundamentals of Computational Swarm Intelligence\", Bonobeau/Dorigo/Theauraz' \"Swarm Intelligence: From Natural to Artificial Systems\" and Casella's \"Statistical Inference\" are all examples of books that don't fit your question, but which I'm guessing you might really dig anyway.\n\nBooks on similar topics from the perspective of math people instead of computer people, if you can work with those, are also very valuable. Consider \"Nonlinear Dynamics And Chaos: With Applications To Physics, Biology, Chemistry, And Engineering\", \"Calculus of Variations\" and \"Complex Adaptive Systems: An Introduction to Computational Models of Social Life\". Oddly, a market book is also fascinating in this direction: \"Origin of Wealth: Evolution, Complexity, and Economics.\"\n\nYou may need some statistics background. Wasserman's \"All of Statistics\" is a great place to get started.\n\nThat should get you underway. If you need more, ask my blog, http://fullof.bs/ .","timestamp":"2009-08-06T19:30:11+00:00","score":2},{"role":"OP","user_id":"anon_43c3dbfba7a7d947","comment_id":"c0brlwo","kind":"comment","text":"Everyone on proggit should be upvoting you. Thank you a lot!","timestamp":"2009-08-06T20:14:16+00:00","score":1},{"role":"answerer","user_id":"anon_6576462014878bec","comment_id":"c0bsxjx","kind":"comment","text":"No problem, boblem; I got most of those by recommendation, so I'd have to be a dick not to pay it forward.\n\nI mean, I am a dick. But I'll still pay it forward.\n\nAnyway, I stick by my original recommendation: Blondie24 and the book I misremembered the name of, \"Growing Artificial Societies\", are both great places to get your feet wet.","timestamp":"2009-08-07T20:43:52+00:00","score":2}],"n_turns":4,"n_turns_after_thanks":1,"op_metadata":{"user_id":"anon_43c3dbfba7a7d947","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_6576462014878bec","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c0brjvm","thanks_reply_id":"c0brlwo","post_score":0,"answer_score":2,"preferred_answer_is_top_level":false}}
{"user_id":"anon_2a3c5fe927851068","answerer_user_id":"anon_09bdead4ee5b94a3","subreddit":"programming","timestamp":"2009-08-09T01:52:02+00:00","post_id":"98uz8","question":"Ask Proggit: does Emacs Lisp have the elements of a Lisp that makes learning it \"life-changing\"?\n\nI already program in Python for data mining so I thought the most immediately useful Lisp to learn would be Emacs Lisp (for text-processing, mostly). It's really great... but hasn't blown my mind like I thought it would. If I already program semi-functionally in Python, did I get my hopes up too much?","preferred_answer":"Me neither.\r\n\r\nhttp://www.jasani.org/2008/07/19/elisp-doesnt-support-closures\r\n\r\nThe problem isn't just adding something to your macro; but that a macro can't wrap a body of code/form that behaves expectedly in its dynamic world and have it do the same thing by dropping it trivially into a lambda.\r\n\r\nThe mind-blowing stuff in CL, and by god it is mindblowing, is in macro cases. With such different language properties in ELisp, at the very least I can say you won't be writing the same macros.","full_conversation":[{"role":"OP","user_id":"anon_2a3c5fe927851068","comment_id":"98uz8","kind":"post","text":"Ask Proggit: does Emacs Lisp have the elements of a Lisp that makes learning it \"life-changing\"?\n\nI already program in Python for data mining so I thought the most immediately useful Lisp to learn would be Emacs Lisp (for text-processing, mostly). It's really great... but hasn't blown my mind like I thought it would. If I already program semi-functionally in Python, did I get my hopes up too much?","timestamp":"2009-08-09T01:52:02+00:00","score":11},{"role":"answerer","user_id":"anon_09bdead4ee5b94a3","comment_id":"c0bu8e9","kind":"comment","text":"Me neither.\r\n\r\nhttp://www.jasani.org/2008/07/19/elisp-doesnt-support-closures\r\n\r\nThe problem isn't just adding something to your macro; but that a macro can't wrap a body of code/form that behaves expectedly in its dynamic world and have it do the same thing by dropping it trivially into a lambda.\r\n\r\nThe mind-blowing stuff in CL, and by god it is mindblowing, is in macro cases. With such different language properties in ELisp, at the very least I can say you won't be writing the same macros.","timestamp":"2009-08-09T04:26:16+00:00","score":3},{"role":"OP","user_id":"anon_2a3c5fe927851068","comment_id":"c0bu8ox","kind":"comment","text":"Thanks for the response -\nI think emacs lisp can implement closures through lexical-let form:\nhttp://www.delorie.com/gnu/docs/emacs/cl_21.html\nI wonder if that can be used to construct CL-like macros? I'm still trying to figure out the utility of a macro beyond delaying argument evaluation...","timestamp":"2009-08-09T04:37:18+00:00","score":1},{"role":"answerer","user_id":"anon_09bdead4ee5b94a3","comment_id":"c0bu96b","kind":"comment","text":"Right - but you can't put (mymacro .. . . ) around mycode and have the macro able to just wrap it in a lambda and have all the variables just work.\r\n\r\n> I'm still trying to figure out the utility of a macro beyond delaying argument evaluation...\r\n\r\nMacros run at a different time in a different context. Delaying parameters? That's about the most trivial thing you could do with a macro. It runs at a different time. Your \"parameter\" can be your whole program, which the macro could pick apart and put back together in some different way pre-execution. It could also define macros at inner scopes (macrolet), or expand macros that use different definititions at different scopes. Your macro could take any code that's inside it, download all the prices off of ebay, and interleave them in a \"print\" between every expression, all during your (compile/pre-execution) step.\r\n\r\n You can find this question posed. The person answering it responds with a simple macro that the audience can understand. \"Big deal, that's pretty simple to do without\". Then the person answering puts a complex/cool macro. \"But I can't read *that*\".\r\n\r\nBut that's enough about that on an EMACS thread.\r\n\r\nI'm not going to expand on it here beyond saying that ELisp and CL code and macro development will be very different.","timestamp":"2009-08-09T04:57:32+00:00","score":2},{"role":"OP","user_id":"anon_2a3c5fe927851068","comment_id":"c0bua7n","kind":"comment","text":"Good to know. I can certainly see the usefulness of the macrolet, the more complex examples... probably I will have to build up to it. Thank you much for the enlightenment. [in all honesty, this is an emacs LISP thread though :)]","timestamp":"2009-08-09T05:38:09+00:00","score":1}],"n_turns":5,"n_turns_after_thanks":2,"op_metadata":{"user_id":"anon_2a3c5fe927851068","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_09bdead4ee5b94a3","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c0bu8e9","thanks_reply_id":"c0bu8ox","post_score":11,"answer_score":3,"preferred_answer_is_top_level":false}}
{"user_id":"anon_dbfd9fd55f25af4a","answerer_user_id":"anon_36e5236fcd4c6104","subreddit":"programming","timestamp":"2009-08-09T17:18:30+00:00","post_id":"98zl3","question":"I found this on the yourworldoftext.com guy's website. Anyone want to help unravel the mysteries?","preferred_answer":"There are 5 different messages you can get, but once you've found those that's about it. Anything you could possibly draw using the boxes would be unoriginal since it's already one of the trillion pages. ;)","full_conversation":[{"role":"OP","user_id":"anon_dbfd9fd55f25af4a","comment_id":"98zl3","kind":"post","text":"I found this on the yourworldoftext.com guy's website. Anyone want to help unravel the mysteries?","timestamp":"2009-08-09T17:18:30+00:00","score":15},{"role":"answerer","user_id":"anon_36e5236fcd4c6104","comment_id":"c0buz0s","kind":"comment","text":"There are 5 different messages you can get, but once you've found those that's about it. Anything you could possibly draw using the boxes would be unoriginal since it's already one of the trillion pages. ;)","timestamp":"2009-08-09T23:34:44+00:00","score":7},{"role":"OP","user_id":"anon_dbfd9fd55f25af4a","comment_id":"c0bv3u4","kind":"comment","text":"Ah! thanks for clearing that up. I've found 4 of the 5 so far. I hope the 5th one is utterly grand.\n\nEdit: Argh. I found the 5th one. What a let down :(","timestamp":"2009-08-10T02:14:07+00:00","score":2},{"role":"answerer","user_id":"anon_36e5236fcd4c6104","comment_id":"c0bve8c","kind":"comment","text":"Well, sorry. There are plenty of hidden things on yourworldoftext, but I didn't make them.","timestamp":"2009-08-10T08:50:06+00:00","score":3},{"role":"OP","user_id":"anon_dbfd9fd55f25af4a","comment_id":"c0bvez9","kind":"comment","text":"That's okay. I made the made the mistake of taking \"Maybe you could try drawing something\" as a hint of some kind...","timestamp":"2009-08-10T09:38:49+00:00","score":2}],"n_turns":5,"n_turns_after_thanks":2,"op_metadata":{"user_id":"anon_dbfd9fd55f25af4a","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_36e5236fcd4c6104","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c0buz0s","thanks_reply_id":"c0bv3u4","post_score":15,"answer_score":7,"preferred_answer_is_top_level":true}}
{"user_id":"anon_7124d080fd29bd5c","answerer_user_id":"anon_1be42b76d9a80720","subreddit":"programming","timestamp":"2009-08-11T18:43:53+00:00","post_id":"99o1k","question":"Help me find my perfect HTML/PHP/CSS/Python IDE\n\nRequirements:\n\n* Linux compatibility\n* FTP support (must be able to find a file remotely, edit, and save it remotely without downloading the whole freaking site and synching it. Bonus points for the ability to save FTP login info for sites)\n* Syntax checking (aka squiggly red lines)\n* NOT Aptana or Eclipse (both have wayyyy more than what I need and take up needless resources)\n\nIs there anything out there for me?","preferred_answer":"Geany might be ok for you, but there's no FTP support.","full_conversation":[{"role":"OP","user_id":"anon_7124d080fd29bd5c","comment_id":"99o1k","kind":"post","text":"Help me find my perfect HTML/PHP/CSS/Python IDE\n\nRequirements:\n\n* Linux compatibility\n* FTP support (must be able to find a file remotely, edit, and save it remotely without downloading the whole freaking site and synching it. Bonus points for the ability to save FTP login info for sites)\n* Syntax checking (aka squiggly red lines)\n* NOT Aptana or Eclipse (both have wayyyy more than what I need and take up needless resources)\n\nIs there anything out there for me?","timestamp":"2009-08-11T18:43:53+00:00","score":0},{"role":"answerer","user_id":"anon_1be42b76d9a80720","comment_id":"c0bxvkw","kind":"comment","text":"Geany might be ok for you, but there's no FTP support.","timestamp":"2009-08-12T06:44:10+00:00","score":2},{"role":"OP","user_id":"anon_7124d080fd29bd5c","comment_id":"c0by7b0","kind":"comment","text":"Yeah, I might just go with Geany. It's basically the perfect editor for me minus the FTP support.","timestamp":"2009-08-12T15:16:32+00:00","score":1},{"role":"answerer","user_id":"anon_1be42b76d9a80720","comment_id":"c0byx89","kind":"comment","text":"As regards the FTP support, since you're developing on a linux machine, can't you mount the FTP as a share (or use Nautilus), and just use Geany as you would use it on your local documents?","timestamp":"2009-08-13T00:24:19+00:00","score":1},{"role":"OP","user_id":"anon_7124d080fd29bd5c","comment_id":"c0bz7dq","kind":"comment","text":"Yeah, that's what I'll probably do. But integration would be nice, that's all :)","timestamp":"2009-08-13T05:07:47+00:00","score":1}],"n_turns":5,"n_turns_after_thanks":2,"op_metadata":{"user_id":"anon_7124d080fd29bd5c","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_1be42b76d9a80720","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c0bxvkw","thanks_reply_id":"c0by7b0","post_score":0,"answer_score":2,"preferred_answer_is_top_level":false}}
{"user_id":"anon_45be57cc4da750a3","answerer_user_id":"anon_d063cf53ebcd44ef","subreddit":"programming","timestamp":"2009-08-18T09:29:17+00:00","post_id":"9bnuv","question":"AskProggit: is there an open source php/mysql ecommerce to sell photos?\n\nI'm looking for something very simple (but if Magento does it that's good) to allow the site administrator to upload pictures, and customers to browse through (watermarked) images and buy them. After payment they will receive a link and be able to download the image.\nI did some googling and couldn't find any.\nPlease, don't downmod me too much before I get some answers.","preferred_answer":"tried drupal with übercart to sell digital assets ?","full_conversation":[{"role":"OP","user_id":"anon_45be57cc4da750a3","comment_id":"9bnuv","kind":"post","text":"AskProggit: is there an open source php/mysql ecommerce to sell photos?\n\nI'm looking for something very simple (but if Magento does it that's good) to allow the site administrator to upload pictures, and customers to browse through (watermarked) images and buy them. After payment they will receive a link and be able to download the image.\nI did some googling and couldn't find any.\nPlease, don't downmod me too much before I get some answers.","timestamp":"2009-08-18T09:29:17+00:00","score":0},{"role":"answerer","user_id":"anon_d063cf53ebcd44ef","comment_id":"c0c5dfs","kind":"comment","text":"tried drupal with übercart to sell digital assets ?","timestamp":"2009-08-18T09:38:17+00:00","score":2},{"role":"OP","user_id":"anon_45be57cc4da750a3","comment_id":"c0c5dre","kind":"comment","text":"That's probably what I'm looking for. Thanks.","timestamp":"2009-08-18T09:59:12+00:00","score":0},{"role":"answerer","user_id":"anon_d063cf53ebcd44ef","comment_id":"c0c5dsm","kind":"comment","text":"there's a thing called the download module. perhaps that could be useful.","timestamp":"2009-08-18T10:02:09+00:00","score":1}],"n_turns":4,"n_turns_after_thanks":1,"op_metadata":{"user_id":"anon_45be57cc4da750a3","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_d063cf53ebcd44ef","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c0c5dfs","thanks_reply_id":"c0c5dre","post_score":0,"answer_score":2,"preferred_answer_is_top_level":true}}
{"user_id":"anon_2346fd09fbe8aee0","answerer_user_id":"anon_65b5b8a58baa699a","subreddit":"programming","timestamp":"2009-08-21T15:52:08+00:00","post_id":"9ctum","question":"I want to learn Django; recommendations? Details in text.\n\nI just finished going through \"How to think like a computer scientist (Python)\". That is my only programming experience. If I want to learn Django, where do I go from here? Any recommended resources and/or projects?","preferred_answer":"Start with the official Django tutorial (note: you might want to read Dive Into Python for Python, too).\n\nAlong with the rest of the official doc (which is pretty darn good) that should get you started. If you feel this isn't enough, swing by the Django Book.\n\nIf you want a \"paper\" book, Practical Django Projects 2nd ed is your friend.","full_conversation":[{"role":"OP","user_id":"anon_2346fd09fbe8aee0","comment_id":"9ctum","kind":"post","text":"I want to learn Django; recommendations? Details in text.\n\nI just finished going through \"How to think like a computer scientist (Python)\". That is my only programming experience. If I want to learn Django, where do I go from here? Any recommended resources and/or projects?","timestamp":"2009-08-21T15:52:08+00:00","score":0},{"role":"answerer","user_id":"anon_65b5b8a58baa699a","comment_id":"c0c9yp7","kind":"comment","text":"Start with the official Django tutorial (note: you might want to read Dive Into Python for Python, too).\n\nAlong with the rest of the official doc (which is pretty darn good) that should get you started. If you feel this isn't enough, swing by the Django Book.\n\nIf you want a \"paper\" book, Practical Django Projects 2nd ed is your friend.","timestamp":"2009-08-21T16:44:24+00:00","score":3},{"role":"OP","user_id":"anon_2346fd09fbe8aee0","comment_id":"c0c9z3m","kind":"comment","text":"Thank you!","timestamp":"2009-08-21T16:53:39+00:00","score":2},{"role":"answerer","user_id":"anon_65b5b8a58baa699a","comment_id":"c0ca0yc","kind":"comment","text":"You can also subscribe to the django-users mailing list and visit #django@irc.freenode.net\n\nYou might also want to subscribe to the blogs of [Brian Rosner](http://oebfare.com/), [Jeff Croft](http://jeffcroft.com/), [James Bennett](http://www.b-list.org/), [Jacob Kaplan-Moss](http://jacobian.org/writing/), [Adrian Holovaty](http://www.holovaty.com/) and [Simon Willison](http://simonwillison.net/) (among others) and browse their archives: they are or used to be Django developers (both users of django and core devs of it) and are as a result pretty important resources on quite a bunch of stuff (I very strongly recommend James Bennett's archives in particular when getting started).\n\nAlso, if you have problems start by searching the documentation, the intarwebs and the mailing list's archives: chances are, somebody else had the same issue.\n\nIf you can't find anything, ask on IRC its resident tend to be pretty friendly (though asking questions that can be answered by the doc or a quick googling isn't the best way to get on their good side).\n\nFinally, don't hesitate diving in Django's source itself, and if you find things that are incomplete or incorrect in the official documentation do open bugs on the tracker (if the issues aren't tracked already, don't forget to do a quick search) and, if you can, provide patches: documentation contributions are first-class contribs to the django project, they aren't considered second-class citizens.","timestamp":"2009-08-21T17:36:19+00:00","score":1}],"n_turns":4,"n_turns_after_thanks":1,"op_metadata":{"user_id":"anon_2346fd09fbe8aee0","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_65b5b8a58baa699a","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c0c9yp7","thanks_reply_id":"c0c9z3m","post_score":0,"answer_score":3,"preferred_answer_is_top_level":true}}
{"user_id":"anon_a632ba34bc86fa92","answerer_user_id":"anon_7eac1447fe0d2d31","subreddit":"programming","timestamp":"2009-08-22T03:07:26+00:00","post_id":"9czsi","question":"Ask proggit: Building up a sparse matrix from a set of data points?\n\nI'm wondering if there may be any (efficient?) way of 'building up' a sparse matrix representation of a data set?\n\nAll the information I have found about sparse matrices require the original matrix to exist, then reduce it to a sparse matrix representation.\n\nUnfortunately, the datasets I'm dealing with are stored as many-millions of individual events accumulated over time (each event has a spatial coordinate, but sequential events may have vastly different spatial coordinates) and can end up creating arrays that are 256MB or more.\n\nAfter populating the matrix, anywhere from 80-99% of the matrix elements are zero, so a sparse matrix representation would greatly reduce the space requirements. However, I have no idea if it is possible to 'build up' a sparse matrix from a stream of incoming data points without having to initially populate a large 256MB+ matrix.\n\nAny ideas or suggestions would be greatly appreciated!\n\nedit: I'll be using C++","preferred_answer":"You could use a [Yale Sparse Matrix Format](http://en.wikipedia.org/wiki/Sparse_matrix). As points come in, extend the arrays as needed.\n\nYou'll probably want to think of something clever in terms of using sorted lists. I imagine with some tweaking, adding all values should be nlogn. \n\nYou might want to try the stupid thing first -- store triples for all filled in points and aggregate them in a hashtable or binary tree.\n\nWhat language you are using is important here. If you can implement a 'matrix' interface that a sparse matrix package from a library can read, you should just use the stupid hash table approach and see what that does for you. I imagine if you intend to crunch this data, you won't want to screw around with optimizing this process so much right now.","full_conversation":[{"role":"OP","user_id":"anon_a632ba34bc86fa92","comment_id":"9czsi","kind":"post","text":"Ask proggit: Building up a sparse matrix from a set of data points?\n\nI'm wondering if there may be any (efficient?) way of 'building up' a sparse matrix representation of a data set?\n\nAll the information I have found about sparse matrices require the original matrix to exist, then reduce it to a sparse matrix representation.\n\nUnfortunately, the datasets I'm dealing with are stored as many-millions of individual events accumulated over time (each event has a spatial coordinate, but sequential events may have vastly different spatial coordinates) and can end up creating arrays that are 256MB or more.\n\nAfter populating the matrix, anywhere from 80-99% of the matrix elements are zero, so a sparse matrix representation would greatly reduce the space requirements. However, I have no idea if it is possible to 'build up' a sparse matrix from a stream of incoming data points without having to initially populate a large 256MB+ matrix.\n\nAny ideas or suggestions would be greatly appreciated!\n\nedit: I'll be using C++","timestamp":"2009-08-22T03:07:26+00:00","score":0},{"role":"answerer","user_id":"anon_7eac1447fe0d2d31","comment_id":"c0cape0","kind":"comment","text":"You could use a [Yale Sparse Matrix Format](http://en.wikipedia.org/wiki/Sparse_matrix). As points come in, extend the arrays as needed.\n\nYou'll probably want to think of something clever in terms of using sorted lists. I imagine with some tweaking, adding all values should be nlogn. \n\nYou might want to try the stupid thing first -- store triples for all filled in points and aggregate them in a hashtable or binary tree.\n\nWhat language you are using is important here. If you can implement a 'matrix' interface that a sparse matrix package from a library can read, you should just use the stupid hash table approach and see what that does for you. I imagine if you intend to crunch this data, you won't want to screw around with optimizing this process so much right now.","timestamp":"2009-08-22T06:25:46+00:00","score":2},{"role":"OP","user_id":"anon_a632ba34bc86fa92","comment_id":"c0cb33e","kind":"comment","text":"Thanks for the comment! I'll most likely be using C++ unless there is some compelling reason to use something else.\nI hadn't thought to store them in a hash table or binary tree. I guess I would just have to include a 'counter' in the event's data structure (because events with same x,y,energy need to be accumulated). I'm curious though, why do you refer to using a hashtable or binary tree as 'the stupid thing' ?\n\nAlso, any suggestions on where I could search for (or names of) libraries that have a sparse matrix package?\nThanks again","timestamp":"2009-08-22T17:56:06+00:00","score":1},{"role":"answerer","user_id":"anon_7eac1447fe0d2d31","comment_id":"c0cb6uc","kind":"comment","text":"> I'm curious though, why do you refer to using a hashtable or binary tree as 'the stupid thing' \n\nWhen I say 'the stupid thing', I mean it in the sense of 'the easiest thing to do, that might not work, but try it anyway'. Its a bit of a mantra for some CS folks -- always do the stupid thing first, and then make that better if it doesn't work.\n\nIn this regard, its 'stupid' because neither solution would scale particularly well. a hashtable is going to fuck you up on memory for enough inputs, and a binary tree will eventually fuck you up in performance. Thats why super optimized forms for sparse matrices exist. \n\nIts likely though you have a small enough scale so that none of that matters, and so the easiest thing to do will work perfectly. \n\nWhat kind of post processing are you going to do on the data?","timestamp":"2009-08-22T19:55:36+00:00","score":1},{"role":"OP","user_id":"anon_a632ba34bc86fa92","comment_id":"c0cbj09","kind":"comment","text":"Ah yes, I've definitely come across the 'make it work, then worry about performance' mantra before.. Unfortunately I sort of have to think about performance from the get-go (at least in terms of memory footprint).\n\n\n>What kind of post processing are you going to do on the data?\n\nWell, each event has a detector#, x position, y position and energy (or bin number). The detectors are to be considered separately, so the 'event space' created is a 3D space (x-position) x (y-position) x (energy/bin number) that can be as large as 256x256x4096. The only post-processing I need to do on the data is read through the (sparse) matrix to create 2D density maps (using pixel counts that are between some energy threshold).\n\nI have a feeling the Yale Sparse Matrix Format will be very useful, I'm going to give that a try.","timestamp":"2009-08-23T02:53:24+00:00","score":1}],"n_turns":5,"n_turns_after_thanks":2,"op_metadata":{"user_id":"anon_a632ba34bc86fa92","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_7eac1447fe0d2d31","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c0cape0","thanks_reply_id":"c0cb33e","post_score":0,"answer_score":2,"preferred_answer_is_top_level":true}}
{"user_id":"anon_9cf4b96061eb5193","answerer_user_id":"anon_d8a8a5c337b70876","subreddit":"programming","timestamp":"2009-08-28T14:03:03+00:00","post_id":"9f1o6","question":"AskProggit: I have a ton of bookmarks and I'm beginning to fear that I'll lose some of the content over time. Can you help me find/make a utility to convert the links into pdfs?\n\nI run OS X 10.5.8. and have the bookmarks on Firefox, meaning I can export the bookmark list itself as .html (and do for backup purposes) and I have a lot of folders for categorizing, which would be nice to keep in the conversion process.\n\nI have a lot of diskspace and CPU power to handle such things, the problem is is that I don't know of any convenient program or method to do this automatically. We're talking about a 4 mbyte file of just links when exported to HTML.\n\n**What I want/need to do is to somehow get a program to go to each URL I have bookmarked and to print it out as a PDF copy so I can locally archive the content (text, images) of the pages** just in case the server goes down and its content isn't found elsewhere on the net. Unlikely, but I don't want to risk it.\n\nI'm using these bookmarks as source material to make documentaries for a website that I've been working on for ages. *Please* help me, this will pay itself back once I get the funds together to start developing the actual doc's, I swear there's such a large array of topics there's going to be something for everyone (and not superficial garbage either). The links provide easy dive-in points for my writing and research.\n\nThank you.\n\n**EDIT:** I see that people have been slightly confused as to what I meant, added some text (mostly in bold).\n\n**EDIT 2:** I forgot to mention that I have near-zero knowledge in command lines or programming. I am a total newb. Be gentle. The advice I'm getting is gold, but I still feel that the essence of what I'm getting at isn't getting addressed. I sent the developer of [wkpdf](http://plessl.github.com/wkpdf/) an email for some advice, hopefully that'll get me somewhere. Serious thanks to everyone, please share your advice if you have ideas.","preferred_answer":"It should be possible to point wget at your HTML file of exported bookmarks, and get it to follow every link therein. Do you just want the pages you bookmarked, or the whole of each site?\n\n**Edit**: I had a brief go at doing this, but I appear to be having a bit of trouble getting the options to wget right. For reference, here's how you extract the list of links from a Firefox bookmarks file:\n\n1. Save the file as, say, `bookmarks.html` in `/home/srussian/bookmarks` (ie, the \"bookmarks\" subdirectory of your home directory).\n2. Open a command prompt.\n3. Type `cd bookmarks`, and then press \"RETURN\" to change to the bookmarks directory.\n4. Type (or better, copy-and-paste) the line `perl -ne 'if (/href=\"(.*?)\"/i) { print \"$1\\n\"; }' bookmarks.html > bookmarks` into the command prompt, and press RETURN.\n5. All being well, there should now be a file called called `bookmarks` in the directory, that contains just the links, one per line.\n\nThis file can now be passed as an argument to wget's `-i` option. The original `bookmarks.html` ought to work here too, but it doesn't (at least, not for me), for reasons I don't care enough to investigate. Seasoned programmers will castigate me for operating on HTML with a regex, but Firefox's bookmarks file is not valid XML, so using xpath on it doesn't work either.\n\n**Further edit**: I think the correct `wget` invocation is `wget -E -H -k -K -p -i bookmarks`. Your mission is now to type `man wget`, find out what all those switches do, and work out why I suggest that you use them and what will happen. NB: this will not preserve your directory structure at all. Nor will it save things as PDF, but I don't think that's really helpful for your purposes anyway.","full_conversation":[{"role":"OP","user_id":"anon_9cf4b96061eb5193","comment_id":"9f1o6","kind":"post","text":"AskProggit: I have a ton of bookmarks and I'm beginning to fear that I'll lose some of the content over time. Can you help me find/make a utility to convert the links into pdfs?\n\nI run OS X 10.5.8. and have the bookmarks on Firefox, meaning I can export the bookmark list itself as .html (and do for backup purposes) and I have a lot of folders for categorizing, which would be nice to keep in the conversion process.\n\nI have a lot of diskspace and CPU power to handle such things, the problem is is that I don't know of any convenient program or method to do this automatically. We're talking about a 4 mbyte file of just links when exported to HTML.\n\n**What I want/need to do is to somehow get a program to go to each URL I have bookmarked and to print it out as a PDF copy so I can locally archive the content (text, images) of the pages** just in case the server goes down and its content isn't found elsewhere on the net. Unlikely, but I don't want to risk it.\n\nI'm using these bookmarks as source material to make documentaries for a website that I've been working on for ages. *Please* help me, this will pay itself back once I get the funds together to start developing the actual doc's, I swear there's such a large array of topics there's going to be something for everyone (and not superficial garbage either). The links provide easy dive-in points for my writing and research.\n\nThank you.\n\n**EDIT:** I see that people have been slightly confused as to what I meant, added some text (mostly in bold).\n\n**EDIT 2:** I forgot to mention that I have near-zero knowledge in command lines or programming. I am a total newb. Be gentle. The advice I'm getting is gold, but I still feel that the essence of what I'm getting at isn't getting addressed. I sent the developer of [wkpdf](http://plessl.github.com/wkpdf/) an email for some advice, hopefully that'll get me somewhere. Serious thanks to everyone, please share your advice if you have ideas.","timestamp":"2009-08-28T14:03:03+00:00","score":0},{"role":"answerer","user_id":"anon_d8a8a5c337b70876","comment_id":"c0ck2w5","kind":"comment","text":"It should be possible to point wget at your HTML file of exported bookmarks, and get it to follow every link therein. Do you just want the pages you bookmarked, or the whole of each site?\n\n**Edit**: I had a brief go at doing this, but I appear to be having a bit of trouble getting the options to wget right. For reference, here's how you extract the list of links from a Firefox bookmarks file:\n\n1. Save the file as, say, `bookmarks.html` in `/home/srussian/bookmarks` (ie, the \"bookmarks\" subdirectory of your home directory).\n2. Open a command prompt.\n3. Type `cd bookmarks`, and then press \"RETURN\" to change to the bookmarks directory.\n4. Type (or better, copy-and-paste) the line `perl -ne 'if (/href=\"(.*?)\"/i) { print \"$1\\n\"; }' bookmarks.html > bookmarks` into the command prompt, and press RETURN.\n5. All being well, there should now be a file called called `bookmarks` in the directory, that contains just the links, one per line.\n\nThis file can now be passed as an argument to wget's `-i` option. The original `bookmarks.html` ought to work here too, but it doesn't (at least, not for me), for reasons I don't care enough to investigate. Seasoned programmers will castigate me for operating on HTML with a regex, but Firefox's bookmarks file is not valid XML, so using xpath on it doesn't work either.\n\n**Further edit**: I think the correct `wget` invocation is `wget -E -H -k -K -p -i bookmarks`. Your mission is now to type `man wget`, find out what all those switches do, and work out why I suggest that you use them and what will happen. NB: this will not preserve your directory structure at all. Nor will it save things as PDF, but I don't think that's really helpful for your purposes anyway.","timestamp":"2009-08-29T16:36:27+00:00","score":2},{"role":"OP","user_id":"anon_9cf4b96061eb5193","comment_id":"c0cku64","kind":"comment","text":"Whoa, thanks a million! Very detailed and thorough advice.","timestamp":"2009-08-30T09:42:12+00:00","score":1},{"role":"answerer","user_id":"anon_d8a8a5c337b70876","comment_id":"c0ckxz8","kind":"comment","text":"No problem, and I hope it works for you. I think it may be possible to recover your directory structure by hacking the original `bookmarks.html` file to point to your local copies, but I'll have to experiment with that a bit. Actually, you could probably do it yourself by opening the file in a text editor, and replacing `href=\"http://` with `href=\"file:///home/srussian/bookmarks/` throughout.","timestamp":"2009-08-30T14:01:05+00:00","score":1}],"n_turns":4,"n_turns_after_thanks":1,"op_metadata":{"user_id":"anon_9cf4b96061eb5193","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_d8a8a5c337b70876","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c0ck2w5","thanks_reply_id":"c0cku64","post_score":0,"answer_score":2,"preferred_answer_is_top_level":false}}
{"user_id":"anon_00759792d4c4802f","answerer_user_id":"anon_b0df641dd31cbfd6","subreddit":"programming","timestamp":"2009-08-29T01:53:41+00:00","post_id":"9f8bt","question":"Any PHP framework suggestions?\n\nI'm kinda hoping someone has a suggestion of a magic bullet framework. Here are the particulars:\n\n\nI'm contracting to supporting a PHP website. The original developer learned PHP and web dev with this site and left when it became too cumbersome... The site mainly loads data from the DB into forms users can edit. It has minimal locking, some authentication, and is mostly table layouts.\n\nSome notes.\n\n* It's about 55K lines of PHP4, about 40 web pages\n* There are very few functions, no classes (lots of duplication)\n* A framework would need to run in Apache 1.3\n* I might be able to upgrade to PHP5 (more of a hosting issue)\n* I've got MySQL 5.0.X\n\nThis is my first real contract... I don't want spend much more than 80 hours \"doing nothing\" since they don't get to see how much better the framework is. Ideally, I can support the current pages and use the framework piecemeal as I add features.\n\nHere are some frameworks I've found online: [symfony](http://www.symfony-project.org/), [CakePHP](http://cakephp.org/), [FLOW3](http://flow3.typo3.org/), [Friendly](http://friendlyphp.org/), and [A Big List](http://php.devreview.com/big-list-of-php-frameworks). The problem isn't finding them. I'd like to know if anyone can recommend a framework from personal experience.","preferred_answer":"Propel can be molded quite well to most existing schemas.","full_conversation":[{"role":"OP","user_id":"anon_00759792d4c4802f","comment_id":"9f8bt","kind":"post","text":"Any PHP framework suggestions?\n\nI'm kinda hoping someone has a suggestion of a magic bullet framework. Here are the particulars:\n\n\nI'm contracting to supporting a PHP website. The original developer learned PHP and web dev with this site and left when it became too cumbersome... The site mainly loads data from the DB into forms users can edit. It has minimal locking, some authentication, and is mostly table layouts.\n\nSome notes.\n\n* It's about 55K lines of PHP4, about 40 web pages\n* There are very few functions, no classes (lots of duplication)\n* A framework would need to run in Apache 1.3\n* I might be able to upgrade to PHP5 (more of a hosting issue)\n* I've got MySQL 5.0.X\n\nThis is my first real contract... I don't want spend much more than 80 hours \"doing nothing\" since they don't get to see how much better the framework is. Ideally, I can support the current pages and use the framework piecemeal as I add features.\n\nHere are some frameworks I've found online: [symfony](http://www.symfony-project.org/), [CakePHP](http://cakephp.org/), [FLOW3](http://flow3.typo3.org/), [Friendly](http://friendlyphp.org/), and [A Big List](http://php.devreview.com/big-list-of-php-frameworks). The problem isn't finding them. I'd like to know if anyone can recommend a framework from personal experience.","timestamp":"2009-08-29T01:53:41+00:00","score":0},{"role":"answerer","user_id":"anon_b0df641dd31cbfd6","comment_id":"c0ck38x","kind":"comment","text":"Propel can be molded quite well to most existing schemas.","timestamp":"2009-08-29T16:47:55+00:00","score":2},{"role":"OP","user_id":"anon_00759792d4c4802f","comment_id":"c0ckdn0","kind":"comment","text":"Thanks. I'll check that one out too.","timestamp":"2009-08-29T22:39:52+00:00","score":1},{"role":"answerer","user_id":"anon_b0df641dd31cbfd6","comment_id":"c0ckjfa","kind":"comment","text":"Just to clear up some confusion, [Propel](http://propel.phpdb.org/trac/wiki/Users/Documentation/1.3/UserGuide) is the (default) ORM included in [Symfony](http://www.symfony-project.org/getting-started/1_2/en/).","timestamp":"2009-08-30T02:08:33+00:00","score":2}],"n_turns":4,"n_turns_after_thanks":1,"op_metadata":{"user_id":"anon_00759792d4c4802f","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_b0df641dd31cbfd6","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c0ck38x","thanks_reply_id":"c0ckdn0","post_score":0,"answer_score":2,"preferred_answer_is_top_level":false}}
{"user_id":"anon_fe4ba7af69aaef93","answerer_user_id":"anon_3db47d29f33903f6","subreddit":"programming","timestamp":"2009-09-06T01:39:19+00:00","post_id":"9hqaf","question":"Is there a school that offers web design/development (or something similar) as a masters program?\n\nI was wanting to go to Notre Dame, but it's not looking like there's anything offered other than computer science. Can I customize a program to focus around something that I'd like to study (i.e.: web development)?\n\nHelp! \n\nEDIT: I've been doing web design/development for a while and started my own company and I am still in school with a major of Business Information Systems, minoring in Computer Science and Media Communications (and trying to combine them into a more useful major for me). I fully understand the concepts of programming, and have made plenty of websites. I've done work with databases and have taken classes on data communication, assembly programming, computer architecture, etc...\n\nI'm basically just looking for something after this for something that is MORE than just online tutorials. I want to advance the field, not just do what somebody else has already done.","preferred_answer":"Your best bet is to study Computer Science and specialize in Human-Computer Interaction, if you want a Masters, and do research in web development in relation to design.\n\nAnother budding field of interest might be Data/Information Visualization.","full_conversation":[{"role":"OP","user_id":"anon_fe4ba7af69aaef93","comment_id":"9hqaf","kind":"post","text":"Is there a school that offers web design/development (or something similar) as a masters program?\n\nI was wanting to go to Notre Dame, but it's not looking like there's anything offered other than computer science. Can I customize a program to focus around something that I'd like to study (i.e.: web development)?\n\nHelp! \n\nEDIT: I've been doing web design/development for a while and started my own company and I am still in school with a major of Business Information Systems, minoring in Computer Science and Media Communications (and trying to combine them into a more useful major for me). I fully understand the concepts of programming, and have made plenty of websites. I've done work with databases and have taken classes on data communication, assembly programming, computer architecture, etc...\n\nI'm basically just looking for something after this for something that is MORE than just online tutorials. I want to advance the field, not just do what somebody else has already done.","timestamp":"2009-09-06T01:39:19+00:00","score":0},{"role":"answerer","user_id":"anon_3db47d29f33903f6","comment_id":"c0ctqbf","kind":"comment","text":"Your best bet is to study Computer Science and specialize in Human-Computer Interaction, if you want a Masters, and do research in web development in relation to design.\n\nAnother budding field of interest might be Data/Information Visualization.","timestamp":"2009-09-06T02:54:13+00:00","score":6},{"role":"OP","user_id":"anon_fe4ba7af69aaef93","comment_id":"c0ctqf0","kind":"comment","text":"Thank you. This has actually been very helpful to me.\n\nI guess I've been looking for the answer to, \"What is the name for what I'm interested in.\" I feel as if I have a very clear vision, I just don't know how to get there from here.","timestamp":"2009-09-06T02:57:48+00:00","score":2},{"role":"answerer","user_id":"anon_3db47d29f33903f6","comment_id":"c0ctqrb","kind":"comment","text":"Not a problem - I'm actually doing my Masters in CS under Information Visualization (actually, Software Visualization, to be more precise) because of my interest in HCI topics, but my University lacked anyone in the HCI field who was decent and the InfoViz prof was a really good and it was, more or less, applied HCI.","timestamp":"2009-09-06T03:09:47+00:00","score":1}],"n_turns":4,"n_turns_after_thanks":1,"op_metadata":{"user_id":"anon_fe4ba7af69aaef93","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_3db47d29f33903f6","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c0ctqbf","thanks_reply_id":"c0ctqf0","post_score":0,"answer_score":6,"preferred_answer_is_top_level":true}}
{"user_id":"anon_06e27aa2b23f9ba4","answerer_user_id":"anon_7dbd808d95b57af7","subreddit":"programming","timestamp":"2009-09-06T04:33:36+00:00","post_id":"9hr7d","question":"What Python IDE's Work With 3.0?\n\nI'm looking for something with more power than IDLE. I have never used another IDE for Python and want something with auto complete and debugging. Any suggestions?","preferred_answer":"Which.\n\nDefinitely check it out.","full_conversation":[{"role":"OP","user_id":"anon_06e27aa2b23f9ba4","comment_id":"9hr7d","kind":"post","text":"What Python IDE's Work With 3.0?\n\nI'm looking for something with more power than IDLE. I have never used another IDE for Python and want something with auto complete and debugging. Any suggestions?","timestamp":"2009-09-06T04:33:36+00:00","score":9},{"role":"answerer","user_id":"anon_7dbd808d95b57af7","comment_id":"c0cttg7","kind":"comment","text":"Which.\n\nDefinitely check it out.","timestamp":"2009-09-06T04:42:25+00:00","score":3},{"role":"OP","user_id":"anon_06e27aa2b23f9ba4","comment_id":"c0ctw12","kind":"comment","text":"Thanks for pointing that out. You lost me on the second sentence though.","timestamp":"2009-09-06T06:22:49+00:00","score":5},{"role":"answerer","user_id":"anon_7dbd808d95b57af7","comment_id":"c0cux4n","kind":"comment","text":"I had hoped you would search for it before realizing I was correcting your grammar.","timestamp":"2009-09-07T05:11:17+00:00","score":1}],"n_turns":4,"n_turns_after_thanks":1,"op_metadata":{"user_id":"anon_06e27aa2b23f9ba4","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_7dbd808d95b57af7","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c0cttg7","thanks_reply_id":"c0ctw12","post_score":9,"answer_score":3,"preferred_answer_is_top_level":true}}
{"user_id":"anon_2a3c5fe927851068","answerer_user_id":"anon_605eec2f499d19a7","subreddit":"programming","timestamp":"2009-09-08T08:01:12+00:00","post_id":"9ickt","question":"Manipulate/modify S-expressions in Emacs Lisp?\n\nHi, I wonder if there are any good documents or tutorials on how to\nmanipulate S-expressions in Emacs Lisp. My immediate goal\nis to modify one line of a function already loaded from a contributed\nlibrary. The function is rather long, so I was hoping for a more\nconcise solution than copy-pasting the whole function (with the slight\nmodification) in my .emacs file simply to redefine it after loading.\n\nFor instance, in the R language, I can do the following -\n\nrebind modified function:\n\n FunctionName <-\n `body<-`(FunctionName,\n value=replace(body(FunctionName),ListElement,\n list(quote(NewExpression))))\n\n\n(or, modifying the function in place):\n\n body(FunctionName)[[ListElement]] <- quote(NewExpression)\n\nEssentially, body() transforms a function into a list whose elements\nare (quoted) expressions comprising the function and body<-() allows assignment to it.\n\nI understand that this is called \"computing on the language\" and\nderived from Lisp. (Emacs) Lisp S-expressions can be parsed as trees\nand so searching and modifying should be even more natural...? I\nhaven't been able to find the appropriate documentation for converting\nEmacs Lisp functions into structures that I can search and modify - do you have any leads? Also... are there more general uses for such operations (there must be, I know, but my application domain is limited)? Thanks!","preferred_answer":"The main issue with your proposed technique is the same as with self-modifying code; hacking on (what is effectively) object code brings it out-of-sync with source code in ways that are not necessarily well-controlled.\n\nYou can very easily get into situations where you introduce hard-to-find bugs, and software configurations that are hard to reproduce.\n\n\"Manipulating S-expressions\" in Lisp is generally limited to macros, which act as a user-programmable front-end for the compiler, not doing invasive surgery after the compiler is done.\n\nThe key thing is that Lisp *source code* is explicitly written in the S-expression format which is easily processed as data. Lisp *object code* might be S-expressions, if you have a naive interpreter or simple compiler, but it also might be machine code.","full_conversation":[{"role":"OP","user_id":"anon_2a3c5fe927851068","comment_id":"9ickt","kind":"post","text":"Manipulate/modify S-expressions in Emacs Lisp?\n\nHi, I wonder if there are any good documents or tutorials on how to\nmanipulate S-expressions in Emacs Lisp. My immediate goal\nis to modify one line of a function already loaded from a contributed\nlibrary. The function is rather long, so I was hoping for a more\nconcise solution than copy-pasting the whole function (with the slight\nmodification) in my .emacs file simply to redefine it after loading.\n\nFor instance, in the R language, I can do the following -\n\nrebind modified function:\n\n FunctionName <-\n `body<-`(FunctionName,\n value=replace(body(FunctionName),ListElement,\n list(quote(NewExpression))))\n\n\n(or, modifying the function in place):\n\n body(FunctionName)[[ListElement]] <- quote(NewExpression)\n\nEssentially, body() transforms a function into a list whose elements\nare (quoted) expressions comprising the function and body<-() allows assignment to it.\n\nI understand that this is called \"computing on the language\" and\nderived from Lisp. (Emacs) Lisp S-expressions can be parsed as trees\nand so searching and modifying should be even more natural...? I\nhaven't been able to find the appropriate documentation for converting\nEmacs Lisp functions into structures that I can search and modify - do you have any leads? Also... are there more general uses for such operations (there must be, I know, but my application domain is limited)? Thanks!","timestamp":"2009-09-08T08:01:12+00:00","score":0},{"role":"answerer","user_id":"anon_605eec2f499d19a7","comment_id":"c0cwi1m","kind":"comment","text":"The main issue with your proposed technique is the same as with self-modifying code; hacking on (what is effectively) object code brings it out-of-sync with source code in ways that are not necessarily well-controlled.\n\nYou can very easily get into situations where you introduce hard-to-find bugs, and software configurations that are hard to reproduce.\n\n\"Manipulating S-expressions\" in Lisp is generally limited to macros, which act as a user-programmable front-end for the compiler, not doing invasive surgery after the compiler is done.\n\nThe key thing is that Lisp *source code* is explicitly written in the S-expression format which is easily processed as data. Lisp *object code* might be S-expressions, if you have a naive interpreter or simple compiler, but it also might be machine code.","timestamp":"2009-09-08T15:37:58+00:00","score":2},{"role":"OP","user_id":"anon_2a3c5fe927851068","comment_id":"c0cxcoy","kind":"comment","text":"Thank you - very helpful. I do think in some instances the edits could be small and contained enough enough that hacking it a posteriori isn't too egregious, but your point is well taken. Thanks for the insight!","timestamp":"2009-09-09T03:11:58+00:00","score":1},{"role":"answerer","user_id":"anon_605eec2f499d19a7","comment_id":"c0cxpdz","kind":"comment","text":"Another thing I didn't explicitly mention is the ability of Lisp environments to replace complete definitions at any time (i.e., late binding).\n\nIf you do want to replace definitions, `defadvice` allows for replacing definitions by wrapping the current definition, and copy-paste into your personal init file allows for replacing definitions with arbitrary altered definitions, but in both cases, source code navigation works. That is, the environment should keep track of those changes and be able to show you the source code that is in effect right now.\n\nIf you modify the object code, the environment is prone to confusion, and will give misleading indications as to the currently active definitions. (Emacs will show you source that is out-of-date or inapplicable, because you have made changes that it is unable to track.)","timestamp":"2009-09-09T12:35:53+00:00","score":2},{"role":"OP","user_id":"anon_2a3c5fe927851068","comment_id":"c0cxvqp","kind":"comment","text":"Much obliged. Sounds like what I want is something like defadvice but most examples I find are indeed wrapping the function and invoking functions before and after (and if 'wrapping' is its main functionality probably not suited for my task...). In that case it's probably best for me to redefine the function (either in my init file or in a separate file in ~/elisp/ or ~/.emacs.d/ which I will load) so that it replaces the original function (late binding or re-binding?).","timestamp":"2009-09-09T15:37:44+00:00","score":1}],"n_turns":5,"n_turns_after_thanks":2,"op_metadata":{"user_id":"anon_2a3c5fe927851068","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_605eec2f499d19a7","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c0cwi1m","thanks_reply_id":"c0cxcoy","post_score":0,"answer_score":2,"preferred_answer_is_top_level":true}}
{"user_id":"anon_6ec4389e336bd3c9","answerer_user_id":"anon_60cdc988fdaa951c","subreddit":"programming","timestamp":"2009-09-12T15:03:55+00:00","post_id":"9jviy","question":"Help! I am due to teach a Ruby college course and need ideas for programming exercises.\n\nHi! I am due to teach OOP with Ruby. All the usual concepts will be covered (encapsulation, inheritance, polymorphism, etc.). I do not want students be be distracted by GUIs, web or other APIs: just simple command-line and file/YAML i/o.\n\nI need inspiring, engaging programming tasks that cover each idea in a simple way, starting with classes and instantiation and going all the way through to mixins and procs.\n\nIf anyone can suggest good ideas, I (and my students) would be very grateful.\n\nThanks :-)","preferred_answer":"Ok then, this is a pen.\n\nA pen is an object.\n\nHave them describe the properties of the object. (length, diameter, color, etc.)\n\nHave them describe the functions of the pen. (write, retract, etc.)\n\nUse real world objects to describe what an OOP is and how different objects interact with each other to accomplish a task within a system.","full_conversation":[{"role":"OP","user_id":"anon_6ec4389e336bd3c9","comment_id":"9jviy","kind":"post","text":"Help! I am due to teach a Ruby college course and need ideas for programming exercises.\n\nHi! I am due to teach OOP with Ruby. All the usual concepts will be covered (encapsulation, inheritance, polymorphism, etc.). I do not want students be be distracted by GUIs, web or other APIs: just simple command-line and file/YAML i/o.\n\nI need inspiring, engaging programming tasks that cover each idea in a simple way, starting with classes and instantiation and going all the way through to mixins and procs.\n\nIf anyone can suggest good ideas, I (and my students) would be very grateful.\n\nThanks :-)","timestamp":"2009-09-12T15:03:55+00:00","score":0},{"role":"answerer","user_id":"anon_60cdc988fdaa951c","comment_id":"c0d28o3","kind":"comment","text":"Ok then, this is a pen.\n\nA pen is an object.\n\nHave them describe the properties of the object. (length, diameter, color, etc.)\n\nHave them describe the functions of the pen. (write, retract, etc.)\n\nUse real world objects to describe what an OOP is and how different objects interact with each other to accomplish a task within a system.","timestamp":"2009-09-12T16:06:00+00:00","score":2},{"role":"OP","user_id":"anon_6ec4389e336bd3c9","comment_id":"c0d295w","kind":"comment","text":"Okay, thanks, The_Mad_Highlander :-)","timestamp":"2009-09-12T16:20:27+00:00","score":0},{"role":"answerer","user_id":"anon_60cdc988fdaa951c","comment_id":"c0d2982","kind":"comment","text":"Your welcome, now kindly step off my lawn.","timestamp":"2009-09-12T16:22:15+00:00","score":2}],"n_turns":4,"n_turns_after_thanks":1,"op_metadata":{"user_id":"anon_6ec4389e336bd3c9","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_60cdc988fdaa951c","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c0d28o3","thanks_reply_id":"c0d295w","post_score":0,"answer_score":2,"preferred_answer_is_top_level":false}}
{"user_id":"anon_3cf65a14071afac0","answerer_user_id":"anon_9a26bf44398af74a","subreddit":"programming","timestamp":"2009-09-14T07:48:31+00:00","post_id":"9kavb","question":"Should I be writing in plain php or should I begin using a framework? (Advantages/Disadvantages)\n\nI've written a few web applications in plain PHP in the past and I've just seen a few frameworks out there, however I'm not sure what the advantages/disadvantages of using one of these are.","preferred_answer":"> Would it be wise to begin using a framework or should I continue with my regular learning.\n\nBoth, but frameworks are easy enough that you might not feel inclined to continue doing everything the long way. Maybe you could use a framework and try to write one at the same time if you want to continue working with OOP, which brings me to...\n\n> is adding a module/function to a framework as simple as writing your own class \n\nIt depends on what framework you use, but I think in general: No. Writing hooks may be, but in general adding a function to a controller or writing a model feels pretty procedural. You only use OO to construct a DB call or whatever, but you'll do more writing functions and calling functions than writing classes and private vars, etc.","full_conversation":[{"role":"OP","user_id":"anon_3cf65a14071afac0","comment_id":"9kavb","kind":"post","text":"Should I be writing in plain php or should I begin using a framework? (Advantages/Disadvantages)\n\nI've written a few web applications in plain PHP in the past and I've just seen a few frameworks out there, however I'm not sure what the advantages/disadvantages of using one of these are.","timestamp":"2009-09-14T07:48:31+00:00","score":0},{"role":"answerer","user_id":"anon_9a26bf44398af74a","comment_id":"c0d4gjv","kind":"comment","text":"> Would it be wise to begin using a framework or should I continue with my regular learning.\n\nBoth, but frameworks are easy enough that you might not feel inclined to continue doing everything the long way. Maybe you could use a framework and try to write one at the same time if you want to continue working with OOP, which brings me to...\n\n> is adding a module/function to a framework as simple as writing your own class \n\nIt depends on what framework you use, but I think in general: No. Writing hooks may be, but in general adding a function to a controller or writing a model feels pretty procedural. You only use OO to construct a DB call or whatever, but you'll do more writing functions and calling functions than writing classes and private vars, etc.","timestamp":"2009-09-14T08:56:03+00:00","score":2},{"role":"OP","user_id":"anon_3cf65a14071afac0","comment_id":"c0d4hrx","kind":"comment","text":"Thanks. I'll think I'll go through a bit more of using OO in php while writing in a framework. Means I would be more employable if I knew both I guess.\n\nthanks","timestamp":"2009-09-14T10:02:26+00:00","score":1},{"role":"answerer","user_id":"anon_9a26bf44398af74a","comment_id":"c0d4j0g","kind":"comment","text":"Not to mention you'll be more employable when you can deploy an application 3x faster because you don't have to write the same tedious set of features that come \"out of the box\" with frameworks. And, if you're working on a large project, it will be much much easier to manage and keep yourself sane. I've tried to stay unaffiliated in these last posts, but in my final one here I'll say that I've used Zend and Codeigniter, and I strongly recommend CI, especially for someone just getting into MVC frameworks.","timestamp":"2009-09-14T11:11:23+00:00","score":1},{"role":"OP","user_id":"anon_3cf65a14071afac0","comment_id":"c0d4jab","kind":"comment","text":"I had downloaded CI just before you posted this. I've been evaluating a whole lot of frameworks and it just sounds like the more appropriate option.\n\nThankyou so much for your help. :)","timestamp":"2009-09-14T11:26:53+00:00","score":2}],"n_turns":5,"n_turns_after_thanks":2,"op_metadata":{"user_id":"anon_3cf65a14071afac0","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_9a26bf44398af74a","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c0d4gjv","thanks_reply_id":"c0d4hrx","post_score":0,"answer_score":2,"preferred_answer_is_top_level":false}}
{"user_id":"anon_58d7deed8f4d7a6e","answerer_user_id":"anon_7c9d6ab1cd8753c8","subreddit":"programming","timestamp":"2009-09-16T10:20:25+00:00","post_id":"9l31t","question":"Why must operating systems freeze?\n\nI don't know too much about operating systems so maybe this is a dumb question, but I don't understand why an OS has to freeze up. \n\nIs it not possible to somehow set a memory limit on the total memory consumption of the system so that when a (non core) process or processes near that limit they can simply be paused, so that the user can still decide what to do without the entire system becoming completely unusable? \n\nCould some erudite soul explicate this for me?","preferred_answer":"You should read up on memory allocation and management. It isn't quite as simple as you suggest. Operation systems most often freeze because of either poor programming or a bug. Also 'pausing' a process does not release the memory it has been allocated and if you free that memory, then the data would either have to be saved somewhere else or it would be lost. \n\nThere are few simple answers to a question that covers such a broad area. I advice you to read up on procedural programming, memory management and operating system developement.","full_conversation":[{"role":"OP","user_id":"anon_58d7deed8f4d7a6e","comment_id":"9l31t","kind":"post","text":"Why must operating systems freeze?\n\nI don't know too much about operating systems so maybe this is a dumb question, but I don't understand why an OS has to freeze up. \n\nIs it not possible to somehow set a memory limit on the total memory consumption of the system so that when a (non core) process or processes near that limit they can simply be paused, so that the user can still decide what to do without the entire system becoming completely unusable? \n\nCould some erudite soul explicate this for me?","timestamp":"2009-09-16T10:20:25+00:00","score":0},{"role":"answerer","user_id":"anon_7c9d6ab1cd8753c8","comment_id":"c0d7ria","kind":"comment","text":"You should read up on memory allocation and management. It isn't quite as simple as you suggest. Operation systems most often freeze because of either poor programming or a bug. Also 'pausing' a process does not release the memory it has been allocated and if you free that memory, then the data would either have to be saved somewhere else or it would be lost. \n\nThere are few simple answers to a question that covers such a broad area. I advice you to read up on procedural programming, memory management and operating system developement.","timestamp":"2009-09-16T10:32:11+00:00","score":2},{"role":"OP","user_id":"anon_58d7deed8f4d7a6e","comment_id":"c0d7rui","kind":"comment","text":"thanks and sorry, i didnt mean to imply that it was simple, but that i didn't understand it.\n\nand if possible can you provide some specific resources? i wouldnt really know how to pick them out.","timestamp":"2009-09-16T10:50:13+00:00","score":2},{"role":"answerer","user_id":"anon_7c9d6ab1cd8753c8","comment_id":"c0d7s06","kind":"comment","text":"No problem. I suggest you read up on wikipedia first. eg. http://en.wikipedia.org/wiki/Operating_system_development\n\nBut if you honestly want to LEARN, I'd say begin with learning C and move on to books and websites concerning operating systems. Google will be your friend","timestamp":"2009-09-16T10:59:00+00:00","score":2}],"n_turns":4,"n_turns_after_thanks":1,"op_metadata":{"user_id":"anon_58d7deed8f4d7a6e","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_7c9d6ab1cd8753c8","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c0d7ria","thanks_reply_id":"c0d7rui","post_score":0,"answer_score":2,"preferred_answer_is_top_level":true}}
{"user_id":"anon_658e397748b36db3","answerer_user_id":"anon_cb7cce7718c84be3","subreddit":"programming","timestamp":"2009-09-18T10:25:17+00:00","post_id":"9lsm1","question":"Where does my inspiration come from? Drawing. (sketches from 2007 moleskine about webapps)","preferred_answer":"I do the same thing, expect I don't buy moleskines. I use sketchbooks, from big (24x36) to small (4x6) and everything in between.\n\nTo be fair tho, yours look more like...you were focusing more on the sketch than the idea.","full_conversation":[{"role":"OP","user_id":"anon_658e397748b36db3","comment_id":"9lsm1","kind":"post","text":"Where does my inspiration come from? Drawing. (sketches from 2007 moleskine about webapps)","timestamp":"2009-09-18T10:25:17+00:00","score":0},{"role":"answerer","user_id":"anon_cb7cce7718c84be3","comment_id":"c0dawyu","kind":"comment","text":"I do the same thing, expect I don't buy moleskines. I use sketchbooks, from big (24x36) to small (4x6) and everything in between.\n\nTo be fair tho, yours look more like...you were focusing more on the sketch than the idea.","timestamp":"2009-09-18T11:27:07+00:00","score":2},{"role":"OP","user_id":"anon_658e397748b36db3","comment_id":"c0daxoy","kind":"comment","text":"Thanks for your comment and your visit.\n\nMoleskines are now too expensive and are not superior to any other sketchbook. It’s a good object but a bit overrated.\n\nI agree that I tend to doodle a bit too much but this process create a visual picture à-la “Mind map” :-) \n\nHowever while drawing UIs this is very valuabe because you end up quickly with a paper prototype.\n\nHave a good day.","timestamp":"2009-09-18T12:01:38+00:00","score":1},{"role":"answerer","user_id":"anon_cb7cce7718c84be3","comment_id":"c0day2v","kind":"comment","text":"I'll agree with the UI statement. I spend a LOT of time shading and tweaking a UI design.\n\nOnce I have a good one, I tend to rip those out and put them in a special folder.","timestamp":"2009-09-18T12:18:05+00:00","score":1}],"n_turns":4,"n_turns_after_thanks":1,"op_metadata":{"user_id":"anon_658e397748b36db3","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_cb7cce7718c84be3","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c0dawyu","thanks_reply_id":"c0daxoy","post_score":0,"answer_score":2,"preferred_answer_is_top_level":true}}
{"user_id":"anon_77c9fc556c751597","answerer_user_id":"anon_9c49beb210733294","subreddit":"programming","timestamp":"2009-09-20T00:55:24+00:00","post_id":"9m98d","question":"how I saved a lot of time in my stats class\n\nI'm taking an AP Statistics class, and our teacher wanted us to collect a (minimum of) 50 data on 2 assigned variables to see if there is any correlation between them.\n\nMy variables were foot size and height...\n\nI'm taking 5 AP classes total - so going around town, begging people to help me, and recording their foot size and height didn't appeal to me. The project is due in a few days, and I was panicking this morning.\n\nThen I decided to write some code to generate data for me! The premise is simple; you feed the program a mean and a standard deviation, it randomly generates as much sample data as you want (which must fit a normal distribution), repeat the previous two steps for the second variable, calculate the correlation coefficient between the 2 generated sets, repeat the entire process if the correlation is less than desired amount.\n\nI sat down an hour ago and wrote this - and it works (whoo!). It's not as easy as I make it sound above; with large sample sizes, it's (almost) impossible to generate a set with anything better than a 30% correlation. There are some hacks in the code that work around this pretty well.\n\nJust thought I'd share the idea and the code with reddit in case anyone else has a crazy stats project, and lacks the time (or patience) to do it. There aren't many comments but using the code is pretty easy.\n\nLink to the code:\nstats.py : http://pastebin.com/f1cfa990d\nstats_project1.py : http://pastebin.com/f84601ec","preferred_answer":"Wow, stats cheating fail. \"It's not as easy as I make it sound above.\" Indeed, it is easier. You should have just sampled from a 2D gaussian. This way you could specify the correlation, means, and variances all at once, and not need to do the whole resampling step. It is certainly NOT \"(almost) impossible to generate a set with anything better than a 30% correlation.\"\n\nTo do this in Matlab or Octave (free) you don't even need to write any code.\n\nDon't fall into the trap of thinking that because you know how to code, you don't need to know math.","full_conversation":[{"role":"OP","user_id":"anon_77c9fc556c751597","comment_id":"9m98d","kind":"post","text":"how I saved a lot of time in my stats class\n\nI'm taking an AP Statistics class, and our teacher wanted us to collect a (minimum of) 50 data on 2 assigned variables to see if there is any correlation between them.\n\nMy variables were foot size and height...\n\nI'm taking 5 AP classes total - so going around town, begging people to help me, and recording their foot size and height didn't appeal to me. The project is due in a few days, and I was panicking this morning.\n\nThen I decided to write some code to generate data for me! The premise is simple; you feed the program a mean and a standard deviation, it randomly generates as much sample data as you want (which must fit a normal distribution), repeat the previous two steps for the second variable, calculate the correlation coefficient between the 2 generated sets, repeat the entire process if the correlation is less than desired amount.\n\nI sat down an hour ago and wrote this - and it works (whoo!). It's not as easy as I make it sound above; with large sample sizes, it's (almost) impossible to generate a set with anything better than a 30% correlation. There are some hacks in the code that work around this pretty well.\n\nJust thought I'd share the idea and the code with reddit in case anyone else has a crazy stats project, and lacks the time (or patience) to do it. There aren't many comments but using the code is pretty easy.\n\nLink to the code:\nstats.py : http://pastebin.com/f1cfa990d\nstats_project1.py : http://pastebin.com/f84601ec","timestamp":"2009-09-20T00:55:24+00:00","score":0},{"role":"answerer","user_id":"anon_9c49beb210733294","comment_id":"c0dczb0","kind":"comment","text":"Wow, stats cheating fail. \"It's not as easy as I make it sound above.\" Indeed, it is easier. You should have just sampled from a 2D gaussian. This way you could specify the correlation, means, and variances all at once, and not need to do the whole resampling step. It is certainly NOT \"(almost) impossible to generate a set with anything better than a 30% correlation.\"\n\nTo do this in Matlab or Octave (free) you don't even need to write any code.\n\nDon't fall into the trap of thinking that because you know how to code, you don't need to know math.","timestamp":"2009-09-20T01:47:11+00:00","score":5},{"role":"OP","user_id":"anon_77c9fc556c751597","comment_id":"c0dczz8","kind":"comment","text":"\"You should have just sampled from a 2D gaussian.\"\n\nLooking into this.. thanks.\n\n\"Don't fall into the trap of thinking that because you know how to code, you don't need to know math.\"\n\nI won't.","timestamp":"2009-09-20T02:09:19+00:00","score":1},{"role":"answerer","user_id":"anon_9c49beb210733294","comment_id":"c0ddjey","kind":"comment","text":"OK. Do you see the problem? You are generating the two variables independently, so of course any correlation between them is just an artifact of small sample size. If you want them to be related somehow, you have to sample from a model that makes them related.","timestamp":"2009-09-20T16:23:46+00:00","score":2}],"n_turns":4,"n_turns_after_thanks":1,"op_metadata":{"user_id":"anon_77c9fc556c751597","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_9c49beb210733294","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c0dczb0","thanks_reply_id":"c0dczz8","post_score":0,"answer_score":5,"preferred_answer_is_top_level":true}}
{"user_id":"anon_eddfc93c7c391367","answerer_user_id":"anon_4d2e932474efe62d","subreddit":"programming","timestamp":"2009-09-22T02:10:07+00:00","post_id":"9msta","question":"/r/programming, I've done a good bit of programming, but never used JavaScript. What are your book suggestions for someone like me? What books have you found most helpful?","preferred_answer":"Those two are your best bets. Get 'good parts' first - 'Definitive' is more of a reference.","full_conversation":[{"role":"OP","user_id":"anon_eddfc93c7c391367","comment_id":"9msta","kind":"post","text":"/r/programming, I've done a good bit of programming, but never used JavaScript. What are your book suggestions for someone like me? What books have you found most helpful?","timestamp":"2009-09-22T02:10:07+00:00","score":0},{"role":"answerer","user_id":"anon_4d2e932474efe62d","comment_id":"c0dfnh4","kind":"comment","text":"Those two are your best bets. Get 'good parts' first - 'Definitive' is more of a reference.","timestamp":"2009-09-22T02:25:15+00:00","score":2},{"role":"OP","user_id":"anon_eddfc93c7c391367","comment_id":"c0dfpmj","kind":"comment","text":"Thanks for the help guys. I wish this wouldn't get downvoted so I could actually get the opinions of some of the experienced programmers around here.","timestamp":"2009-09-22T03:16:14+00:00","score":1},{"role":"answerer","user_id":"anon_4d2e932474efe62d","comment_id":"c0dgzeu","kind":"comment","text":"If it's any consolation I've taught Javascript classes and actually used it before it was named Javascript so I have an idea of what's useful in a book.","timestamp":"2009-09-22T23:52:13+00:00","score":1}],"n_turns":4,"n_turns_after_thanks":1,"op_metadata":{"user_id":"anon_eddfc93c7c391367","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_4d2e932474efe62d","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c0dfnh4","thanks_reply_id":"c0dfpmj","post_score":0,"answer_score":2,"preferred_answer_is_top_level":false}}
{"user_id":"anon_7399080d71e3e68e","answerer_user_id":"anon_309c3cf76a85b278","subreddit":"programming","timestamp":"2009-09-22T17:02:31+00:00","post_id":"9n0f5","question":"Hey Proggit; today I had my first class in databases and we talked about how Google can 'manage' billions of websites and give you search results in a second... Can anyone explain me in understandable English how Google does that?","preferred_answer":"Ok. A database index allows you to find things in binary search time. O(log n) average (which is very very fast). If you have lots and lots of indexes for all the parameters you wish to search by (text content in Google's case), it allows you to find stuff remarkably fast.\n\nThats the general idea. The specifics of how google does it are obviously much more complicated, but the basic idea is the same.","full_conversation":[{"role":"OP","user_id":"anon_7399080d71e3e68e","comment_id":"9n0f5","kind":"post","text":"Hey Proggit; today I had my first class in databases and we talked about how Google can 'manage' billions of websites and give you search results in a second... Can anyone explain me in understandable English how Google does that?","timestamp":"2009-09-22T17:02:31+00:00","score":0},{"role":"answerer","user_id":"anon_309c3cf76a85b278","comment_id":"c0dghtr","kind":"comment","text":"Ok. A database index allows you to find things in binary search time. O(log n) average (which is very very fast). If you have lots and lots of indexes for all the parameters you wish to search by (text content in Google's case), it allows you to find stuff remarkably fast.\n\nThats the general idea. The specifics of how google does it are obviously much more complicated, but the basic idea is the same.","timestamp":"2009-09-22T18:05:27+00:00","score":3},{"role":"OP","user_id":"anon_7399080d71e3e68e","comment_id":"c0dgirm","kind":"comment","text":"Thanks. So how should I picture this? When I enter a single word, for instance 'mother', in Google, it doesn't have to \"read\" every single bit of data, but instead they keep metadata on every word so they have instant access to the collection of data that contains \"mother\"? (that's the meaning of an index, right?)","timestamp":"2009-09-22T18:23:07+00:00","score":2},{"role":"answerer","user_id":"anon_309c3cf76a85b278","comment_id":"c0dgjao","kind":"comment","text":"In essence yes. \n\nI would suspect they actually keep indices on every substring as well, \"other\", \"ther\", \"her\", \"er\" and combine some of the abilities of grep. The fundamental algorithm is likely very elegant yet sophisticated. Not only do they find all the matches, but they also apply additional layers to rank and \"make appropriate\" to the query.","timestamp":"2009-09-22T18:33:08+00:00","score":2},{"role":"OP","user_id":"anon_7399080d71e3e68e","comment_id":"c0dgjka","kind":"comment","text":"Yes I did read (and understand :o) about PageRanking, which is indeed a very intelligent way to rate websites. I guess, apart from the smart indexing, their biggest advantage is the load of computer networks they installed all over the world. In any case, thanks for your answers, it helped. Upvotes for all your posts :)\n\nThanks for the others for replying too, the phone book helped me visualize it. I hope my stupidity wasn't frustrating :p Thanks again for helping a rookie :)","timestamp":"2009-09-22T18:38:05+00:00","score":1}],"n_turns":5,"n_turns_after_thanks":2,"op_metadata":{"user_id":"anon_7399080d71e3e68e","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_309c3cf76a85b278","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c0dghtr","thanks_reply_id":"c0dgirm","post_score":0,"answer_score":3,"preferred_answer_is_top_level":false}}
{"user_id":"anon_2a3c5fe927851068","answerer_user_id":"anon_1021583b74443e43","subreddit":"programming","timestamp":"2009-09-23T09:19:44+00:00","post_id":"9n8yb","question":"What kind of lisp macros might be useful for scientific applications?\n\nMany physical scientists I know are quite happy with the language constructs provided by Fortran - even if they also program in C or Python, they often settle with abstractions provided at the Fortran-level (my background also). If lisp macros can be used to create DSLs, what might pieces of it look like, if only conceptually? I don't mean to inquire specifically about high-performance computing applications, but also for interactive and exploratory analysis of (static) data (as opposed to dynamic data, which would carry us into the currently hot domain of the data scientist - but would love to hear your thoughts on any of the above...).","preferred_answer":"Hmmm. Generally, you can use macros to recreate convenience functions in high level data processing languages. Stuff I do:\n\n* Anything to simplify array processing. You can rebuild much of the functionality of, say, IDL, in Lisp.\n\n (for-all-2d-array-indices (array ix iy) ...)\n\n (for-array-elements-where (array ix iy condition)\n ;; stuff do do at ix, iy when condition is T\n )\n\n* Stuff to read stuff from files\n\n ;; bind x to col 0 of \"foo.dat\", and y to col 3\n (read-vectors-from-file \"foo.dat\" \n (*x* 0 :single-float) (*y* 3 :double-float))\n\n* Numerical integration (without boxing)\n\n (numerical-integrate-1d x (* x x (sin x)) :x0 0d0 :x1 10d0 :dx 0.01)","full_conversation":[{"role":"OP","user_id":"anon_2a3c5fe927851068","comment_id":"9n8yb","kind":"post","text":"What kind of lisp macros might be useful for scientific applications?\n\nMany physical scientists I know are quite happy with the language constructs provided by Fortran - even if they also program in C or Python, they often settle with abstractions provided at the Fortran-level (my background also). If lisp macros can be used to create DSLs, what might pieces of it look like, if only conceptually? I don't mean to inquire specifically about high-performance computing applications, but also for interactive and exploratory analysis of (static) data (as opposed to dynamic data, which would carry us into the currently hot domain of the data scientist - but would love to hear your thoughts on any of the above...).","timestamp":"2009-09-23T09:19:44+00:00","score":0},{"role":"answerer","user_id":"anon_1021583b74443e43","comment_id":"c0dhk3i","kind":"comment","text":"Hmmm. Generally, you can use macros to recreate convenience functions in high level data processing languages. Stuff I do:\n\n* Anything to simplify array processing. You can rebuild much of the functionality of, say, IDL, in Lisp.\n\n (for-all-2d-array-indices (array ix iy) ...)\n\n (for-array-elements-where (array ix iy condition)\n ;; stuff do do at ix, iy when condition is T\n )\n\n* Stuff to read stuff from files\n\n ;; bind x to col 0 of \"foo.dat\", and y to col 3\n (read-vectors-from-file \"foo.dat\" \n (*x* 0 :single-float) (*y* 3 :double-float))\n\n* Numerical integration (without boxing)\n\n (numerical-integrate-1d x (* x x (sin x)) :x0 0d0 :x1 10d0 :dx 0.01)","timestamp":"2009-09-23T09:36:53+00:00","score":2},{"role":"OP","user_id":"anon_2a3c5fe927851068","comment_id":"c0dhlky","kind":"comment","text":"Thanks for the tip! There is the subtle distinction between macros and functions that I need to study up on since you can implement arrays as a collection of functions, for instance a slicing operation as (mapcar car list-of-pairs) and so on...","timestamp":"2009-09-23T11:02:57+00:00","score":1},{"role":"answerer","user_id":"anon_1021583b74443e43","comment_id":"c0di3bi","kind":"comment","text":"I'd say that the distinction between arrays and functions isn't all that subtle, once you get past the syntax similarity. \n\nFunctions are just functions, and macros are code-rewriters. If you don't know macroexpand already, try it out on something like the loop macro:\n\n (macropexpand '(loop for i from 1 to 10 do (print i)))\n\nBut I agree that macros and functions can both be used to do similar stuff, often:\n\n (integrate-macro-1d x (* x x (sin x)) \n :x0 0d0 :x1 10d0 :dx 0.01)\n\nvs\n\n (integrate-function-1d (lambda (x) (* x x (sin x)))\n :x0 0d0 :x1 10d0 :dx 0.01)\n\nmight do the same thing, but the function form might be less efficient because it would box its float result (except mayber single floats on a 64 bit architecture), whereas the macro from would generate a block of integration code in-place. When I use the function form, I usually pack all the numbers into a structure to avoid boxing.\n\nOften a good alternative to macros is inline functions.","timestamp":"2009-09-23T18:25:08+00:00","score":2},{"role":"OP","user_id":"anon_2a3c5fe927851068","comment_id":"c0dj22h","kind":"comment","text":"Hmm... I've played around with macroexpand but was trying to find a practical use for it in my area of application. I was thinking it could lead to more elegant programming constructs that might save 'programmer/user time' but have not considered much about efficiency issues for the machine (between functions and macros)... I've read about inline functions, have to go see about them again. Thanks much!","timestamp":"2009-09-24T08:30:38+00:00","score":1}],"n_turns":5,"n_turns_after_thanks":2,"op_metadata":{"user_id":"anon_2a3c5fe927851068","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_1021583b74443e43","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c0dhk3i","thanks_reply_id":"c0dhlky","post_score":0,"answer_score":2,"preferred_answer_is_top_level":true}}
{"user_id":"anon_7f21d0c12f6d3df5","answerer_user_id":"anon_df724b216ad242c1","subreddit":"programming","timestamp":"2009-09-23T13:35:02+00:00","post_id":"9nb09","question":"Dear reddit, do you have any real-world stories of where mixins worked better than (multiple) inheritance?\n\nI'm writing a tutorial about mixins. Mixins pay off for larger, more complicated architectures. This makes toy examples unconvincing. I'm looking for an example from a domain that is easy to understand. Any testimonials (python, perl, C++, whatever)? I don't need source code, just a story (or a link).","preferred_answer":"You should look into [traits](http://scg.unibe.ch/research/traits) which were originally developed for Smalltalk, but have made their way into Scala and are called \"Roles\" in Perl. They as basically mixins but instead of (ab)using inheritance they are composed following a strict set of rules. In the perl community at least they have caught on pretty heavily and are proving to be a really useful too.","full_conversation":[{"role":"OP","user_id":"anon_7f21d0c12f6d3df5","comment_id":"9nb09","kind":"post","text":"Dear reddit, do you have any real-world stories of where mixins worked better than (multiple) inheritance?\n\nI'm writing a tutorial about mixins. Mixins pay off for larger, more complicated architectures. This makes toy examples unconvincing. I'm looking for an example from a domain that is easy to understand. Any testimonials (python, perl, C++, whatever)? I don't need source code, just a story (or a link).","timestamp":"2009-09-23T13:35:02+00:00","score":0},{"role":"answerer","user_id":"anon_df724b216ad242c1","comment_id":"c0dht51","kind":"comment","text":"You should look into [traits](http://scg.unibe.ch/research/traits) which were originally developed for Smalltalk, but have made their way into Scala and are called \"Roles\" in Perl. They as basically mixins but instead of (ab)using inheritance they are composed following a strict set of rules. In the perl community at least they have caught on pretty heavily and are proving to be a really useful too.","timestamp":"2009-09-23T14:59:59+00:00","score":2},{"role":"OP","user_id":"anon_7f21d0c12f6d3df5","comment_id":"c0dhvyv","kind":"comment","text":"Thanks for the hint, but what I need is not an explanation of mixins or related topics; I need a real-world application of mixins for illustrating their usefulness. Toy examples are too simple and totally unconvincing. Thanks all the same...","timestamp":"2009-09-23T16:01:34+00:00","score":2},{"role":"answerer","user_id":"anon_df724b216ad242c1","comment_id":"c0diw61","kind":"comment","text":"I guess I am more suggesting you not hype mixins as they are rarely any better then multiple inheritance (depending on the implementation). Roles/Traits are a better way to solve the same problem with a higher degree of safety. If you are looking for good non-toy use cases, then Perl/Moose is where you want to look.","timestamp":"2009-09-24T04:49:36+00:00","score":1}],"n_turns":4,"n_turns_after_thanks":1,"op_metadata":{"user_id":"anon_7f21d0c12f6d3df5","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_df724b216ad242c1","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c0dht51","thanks_reply_id":"c0dhvyv","post_score":0,"answer_score":2,"preferred_answer_is_top_level":true}}
{"user_id":"anon_4df323dad84e2539","answerer_user_id":"anon_a6c708cf0c180ee9","subreddit":"programming","timestamp":"2009-09-23T23:36:08+00:00","post_id":"9nhc2","question":"Ask Proggit: Good incoming SMS gateways?\n\nSuppose I want to receive incoming SMS text messages (at low volume, let's say in the range of a dozen to maybe a few hundred per month) and process them automatically using software that will run on my server. Do any of you know of a service that will let me do this over the Internet cost-effectively? Or am I better off just getting a physical cellular modem with a prepaid plan and talking AT commands to it?\n\nI know shortcodes are expensive; a regular USA phone number is fine.","preferred_answer":"kannel http://www.kannel.org/ has a list of phones that work well with their software. \r\n \r\nnot sure if click-a-tell does incoming sms somehow. Looks like they do: \r\nhttp://www.clickatell.com/pricing/twoway.php","full_conversation":[{"role":"OP","user_id":"anon_4df323dad84e2539","comment_id":"9nhc2","kind":"post","text":"Ask Proggit: Good incoming SMS gateways?\n\nSuppose I want to receive incoming SMS text messages (at low volume, let's say in the range of a dozen to maybe a few hundred per month) and process them automatically using software that will run on my server. Do any of you know of a service that will let me do this over the Internet cost-effectively? Or am I better off just getting a physical cellular modem with a prepaid plan and talking AT commands to it?\n\nI know shortcodes are expensive; a regular USA phone number is fine.","timestamp":"2009-09-23T23:36:08+00:00","score":0},{"role":"answerer","user_id":"anon_a6c708cf0c180ee9","comment_id":"c0dikip","kind":"comment","text":"kannel http://www.kannel.org/ has a list of phones that work well with their software. \r\n \r\nnot sure if click-a-tell does incoming sms somehow. Looks like they do: \r\nhttp://www.clickatell.com/pricing/twoway.php","timestamp":"2009-09-24T00:06:08+00:00","score":2},{"role":"OP","user_id":"anon_4df323dad84e2539","comment_id":"c0dikvc","kind":"comment","text":"kannel looks useful, thanks.","timestamp":"2009-09-24T00:15:12+00:00","score":2},{"role":"answerer","user_id":"anon_a6c708cf0c180ee9","comment_id":"c0diqy2","kind":"comment","text":"click-a-tell is cheap (for the volume you are talking about) and has easy to use APIs - I use the smtp to sms interface to send sms from email, works great.","timestamp":"2009-09-24T02:39:11+00:00","score":1},{"role":"OP","user_id":"anon_4df323dad84e2539","comment_id":"c0dirsu","kind":"comment","text":"It doesn't look to me like you can get a USA virtual number from clickatell, only a European one (which means extra cost for people messaging from the USA where I am) or a $1700/month shortcode.","timestamp":"2009-09-24T02:58:39+00:00","score":1},{"role":"answerer","user_id":"anon_a6c708cf0c180ee9","comment_id":"c0diryp","kind":"comment","text":"ah, so kannel might be a better option in that case.","timestamp":"2009-09-24T03:02:53+00:00","score":1}],"n_turns":6,"n_turns_after_thanks":3,"op_metadata":{"user_id":"anon_4df323dad84e2539","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_a6c708cf0c180ee9","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c0dikip","thanks_reply_id":"c0dikvc","post_score":0,"answer_score":2,"preferred_answer_is_top_level":true}}
{"user_id":"anon_aa70390a6650208f","answerer_user_id":"anon_6cc8e8160820ea87","subreddit":"programming","timestamp":"2009-09-25T20:19:21+00:00","post_id":"9o4xu","question":"Help me with a quick bit of SQL? Thanks much!\n\nI have two tables. I need to get all members of table 1 and create a new column in my results that indicates whether or not their ID exists in table 2.\n\n Select ID, other stuff, *something magic involving table2* as IDExistsInTable2 FROM table1","preferred_answer":"select *, idexists = \r\n\r\n case\r\n\r\n when id in (select distinct id from table2 t2) then 1\r\n\r\n else 0\r\n\r\n end \r\n from table1 t1\r\n\r\n\r\n\r\n\r\n\r\n\r\nShould be something like that. I'll modify it if this doesn't work.\r\n\r\n*Edited for formatting.","full_conversation":[{"role":"OP","user_id":"anon_aa70390a6650208f","comment_id":"9o4xu","kind":"post","text":"Help me with a quick bit of SQL? Thanks much!\n\nI have two tables. I need to get all members of table 1 and create a new column in my results that indicates whether or not their ID exists in table 2.\n\n Select ID, other stuff, *something magic involving table2* as IDExistsInTable2 FROM table1","timestamp":"2009-09-25T20:19:21+00:00","score":0},{"role":"answerer","user_id":"anon_6cc8e8160820ea87","comment_id":"c0dlff5","kind":"comment","text":"select *, idexists = \r\n\r\n case\r\n\r\n when id in (select distinct id from table2 t2) then 1\r\n\r\n else 0\r\n\r\n end \r\n from table1 t1\r\n\r\n\r\n\r\n\r\n\r\n\r\nShould be something like that. I'll modify it if this doesn't work.\r\n\r\n*Edited for formatting.","timestamp":"2009-09-25T20:30:24+00:00","score":2},{"role":"OP","user_id":"anon_aa70390a6650208f","comment_id":"c0dlipw","kind":"comment","text":"I ended up using this option, works great. Thanks again!","timestamp":"2009-09-25T21:32:06+00:00","score":0},{"role":"answerer","user_id":"anon_6cc8e8160820ea87","comment_id":"c0dlj0h","kind":"comment","text":"No prob, glad to have helped.","timestamp":"2009-09-25T21:38:00+00:00","score":1}],"n_turns":4,"n_turns_after_thanks":1,"op_metadata":{"user_id":"anon_aa70390a6650208f","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_6cc8e8160820ea87","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c0dlff5","thanks_reply_id":"c0dlipw","post_score":0,"answer_score":2,"preferred_answer_is_top_level":true}}
{"user_id":"anon_55e600915472bcb4","answerer_user_id":"anon_84eee7dad58a78de","subreddit":"programming","timestamp":"2009-09-29T19:12:30+00:00","post_id":"9p8yu","question":"Ask Proggit: is UML really something used in real-world IT jobs?\n\nI'm learning UML as part of my Software Technology class in university, but I don't see so much life around it, for example the software used to make diagrams are years old. My question is: will I actually use this knowledge or is it just to broaden our view on approaching programming?","preferred_answer":"If you're developing software focusing on both quality and maintainability, then you might. If you're hacking things out rapidly with no cares about \"the right way\" then probably not.\n\nUML/Design is actually a very large area... most people don't understand most design techniques and can't tell you the actual differences between a sequence diagram and an activity diagram. Beyond that, they are pretty unlikely to be able to create both on their own. Well done UML/design components explain the problem at hand, guide the development of software, manage the distribution of work and time, and they can even be used to simplify the final code and product.\n\nCursory knowledge won't hurt, but I'd actually recommend a deeper course. CS isn't worth much if all you do in it barely touches the surface.","full_conversation":[{"role":"OP","user_id":"anon_55e600915472bcb4","comment_id":"9p8yu","kind":"post","text":"Ask Proggit: is UML really something used in real-world IT jobs?\n\nI'm learning UML as part of my Software Technology class in university, but I don't see so much life around it, for example the software used to make diagrams are years old. My question is: will I actually use this knowledge or is it just to broaden our view on approaching programming?","timestamp":"2009-09-29T19:12:30+00:00","score":31},{"role":"answerer","user_id":"anon_84eee7dad58a78de","comment_id":"c0dsd3y","kind":"comment","text":"If you're developing software focusing on both quality and maintainability, then you might. If you're hacking things out rapidly with no cares about \"the right way\" then probably not.\n\nUML/Design is actually a very large area... most people don't understand most design techniques and can't tell you the actual differences between a sequence diagram and an activity diagram. Beyond that, they are pretty unlikely to be able to create both on their own. Well done UML/design components explain the problem at hand, guide the development of software, manage the distribution of work and time, and they can even be used to simplify the final code and product.\n\nCursory knowledge won't hurt, but I'd actually recommend a deeper course. CS isn't worth much if all you do in it barely touches the surface.","timestamp":"2009-09-29T19:25:09+00:00","score":-6},{"role":"OP","user_id":"anon_55e600915472bcb4","comment_id":"c0dsebl","kind":"comment","text":"Thank you. I will remember that last sentence (I'm a rookie).","timestamp":"2009-09-29T19:46:21+00:00","score":1},{"role":"answerer","user_id":"anon_84eee7dad58a78de","comment_id":"c0dtuag","kind":"comment","text":"I'm glad that at least one sentence was taken as positive by someone. If you look through the post karma, the ones that say \"UML is bad\" get many upvotes and the others, no so much. It's a lot of work, most of the time, and has a bit of a stigma as a paperwork generator. It's not the tool, it's the designer. Knowing when these-other-five-to-ten diagrams will truly help is an art, and like most arts, appreciation can be both by clarity of its world-view and arbitrary, divined declarations (i.e. fanboyism).\n\nThere are many parts to UML, and they can all serve very particular circumstances well and others subtly. If you all you take away from UML is the whiteboard-favorites, you'll be fine, but knowing how to construct and understand finer relationships can really clarify problems and solutions.","timestamp":"2009-09-30T16:54:41+00:00","score":1}],"n_turns":4,"n_turns_after_thanks":1,"op_metadata":{"user_id":"anon_55e600915472bcb4","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_84eee7dad58a78de","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c0dsd3y","thanks_reply_id":"c0dsebl","post_score":31,"answer_score":-6,"preferred_answer_is_top_level":true}}
{"user_id":"anon_e3874bae09a3fb68","answerer_user_id":"anon_ddcfab38a3dfecb0","subreddit":"programming","timestamp":"2009-09-30T06:02:26+00:00","post_id":"9pehv","question":"Dear Proggit, I am a novice programmer interested in diving into the world of programming, advice?","preferred_answer":"I taught myself. Although I learned a lot, I made lots of mistakes and developed bad habits. \n\n[This is a great free online source for starting out.](http://see.stanford.edu/see/courseInfo.aspx?coll=824a47e1-135f-4508-a5aa-866adcae1111)","full_conversation":[{"role":"OP","user_id":"anon_e3874bae09a3fb68","comment_id":"9pehv","kind":"post","text":"Dear Proggit, I am a novice programmer interested in diving into the world of programming, advice?","timestamp":"2009-09-30T06:02:26+00:00","score":0},{"role":"answerer","user_id":"anon_ddcfab38a3dfecb0","comment_id":"c0dt9a7","kind":"comment","text":"I taught myself. Although I learned a lot, I made lots of mistakes and developed bad habits. \n\n[This is a great free online source for starting out.](http://see.stanford.edu/see/courseInfo.aspx?coll=824a47e1-135f-4508-a5aa-866adcae1111)","timestamp":"2009-09-30T06:08:49+00:00","score":1},{"role":"OP","user_id":"anon_e3874bae09a3fb68","comment_id":"c0dt9xg","kind":"comment","text":"Thank you for the source, however the information I am looking for dwells into the area not covered by colleges. What can I expect out of employment with a CIS degree? Will a typical college curriculum cover the topics and languages I should know for general employment? Should I specialize in a particular subsection of programming (automation vs server vs web development?). Is it reasonable to think that I can support myself and my family living an enjoyable lifestyle with just a bachelors degree? Subjects like tat.","timestamp":"2009-09-30T06:28:39+00:00","score":1},{"role":"answerer","user_id":"anon_ddcfab38a3dfecb0","comment_id":"c0dta0s","kind":"comment","text":"Here's what you can expect. \nhttp://realjobdescriptions.com/computer_programmer.html\n\nI've started a website that covers that information. Sadly, I haven't had time to devote to marketing or filling out the information myself.\n\nhttp://rjdwiki.com/\n\nIf you know anyone that wouldn't mind filling out a job description, point them [here](http://rjdwiki.com/new_description).","timestamp":"2009-09-30T06:31:36+00:00","score":1}],"n_turns":4,"n_turns_after_thanks":1,"op_metadata":{"user_id":"anon_e3874bae09a3fb68","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_ddcfab38a3dfecb0","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c0dt9a7","thanks_reply_id":"c0dt9xg","post_score":0,"answer_score":1,"preferred_answer_is_top_level":true}}
{"user_id":"anon_077078cde22529d0","answerer_user_id":"anon_d78384ab32bffd3a","subreddit":"programming","timestamp":"2009-09-30T22:14:12+00:00","post_id":"9pnu2","question":"Should I use COMMON LISP or Scheme?\n\nI have an assignment due tomorrow and because I am so busy I am just now looking at it. My assignment requires that I write a single function to return the square root of 1 + x^2. I know nothing of COMMON LISP or Scheme except that they are both derived from \"pure LISP\" so I need advice on which to use. What I am looking for is which one will be easier to learn just enough to write this single function as quickly as possible tonight. I am fluent in C++, Java, and C# so if one has a syntax more similar to one of these than the other that may help. Thanks.\n\nEdit: Damn. I meant to put this in my original post but I accidentally put it in a comment below. Oh well.\n\nThanks for the suggestions. I used Scheme in PLT and wrote this. I highly doubt that any of my classmates will be trolling Reddit for the answer to this problem when it is due in 11 hours.\n\n((lambda (x) (sqrt (+ 1 (* x x)))) 2) \n\nOr\n\n(define (f x) (sqrt (+ 1 (* x x)))) \n(f 2) \n2.23606797749979","preferred_answer":"Oh, incidentally, sorry but lisp style syntax is _not_ C-like. It's a bit different than what you're used to, but it does have its benefits.\n\nEither way, may as well here give you a hand with the basic syntax for function/procedure/whatever you want to call it application:\n\n (proc arg1 arg2 arg3 etc...)\n\n(yes, in parens) is the basic syntax for applying a function.\n\nFor instance,\n\n (+ 3 5)\n\nwill return 8.\n\nIn Scheme, functions themselves are first class values. Functions can be passed as arguments, created anonymously (via lambda), etc...\n\nFor instance,\n\n ((lambda (x) (+ x 3)) 5)\n\nwill return 8.\n\nOne can define variables (in scheme) (changing their values (which you ought usually avoid) is generally done a bit differently) like this:\n\n (define blah 5)\n\nThat gives, well, blah the value of 5.\n\none can define functions via that syntax, with the business end of the define expression having a lambda expression, but there is a syntactic shortcut that basically translates to that:\n\n (define (myproc x 5)\n (+ x 5))\n\nNow you have a procedure myproc\n\n (myproc 3)\n\nwill return 8.\n\nThat ought be enough to get you started at least on understanding the basics of the syntax.\n\nThere're some slight differences in CL as far as defining stuff, and namespaces and so on.","full_conversation":[{"role":"OP","user_id":"anon_077078cde22529d0","comment_id":"9pnu2","kind":"post","text":"Should I use COMMON LISP or Scheme?\n\nI have an assignment due tomorrow and because I am so busy I am just now looking at it. My assignment requires that I write a single function to return the square root of 1 + x^2. I know nothing of COMMON LISP or Scheme except that they are both derived from \"pure LISP\" so I need advice on which to use. What I am looking for is which one will be easier to learn just enough to write this single function as quickly as possible tonight. I am fluent in C++, Java, and C# so if one has a syntax more similar to one of these than the other that may help. Thanks.\n\nEdit: Damn. I meant to put this in my original post but I accidentally put it in a comment below. Oh well.\n\nThanks for the suggestions. I used Scheme in PLT and wrote this. I highly doubt that any of my classmates will be trolling Reddit for the answer to this problem when it is due in 11 hours.\n\n((lambda (x) (sqrt (+ 1 (* x x)))) 2) \n\nOr\n\n(define (f x) (sqrt (+ 1 (* x x)))) \n(f 2) \n2.23606797749979","timestamp":"2009-09-30T22:14:12+00:00","score":6},{"role":"answerer","user_id":"anon_d78384ab32bffd3a","comment_id":"c0duebr","kind":"comment","text":"Oh, incidentally, sorry but lisp style syntax is _not_ C-like. It's a bit different than what you're used to, but it does have its benefits.\n\nEither way, may as well here give you a hand with the basic syntax for function/procedure/whatever you want to call it application:\n\n (proc arg1 arg2 arg3 etc...)\n\n(yes, in parens) is the basic syntax for applying a function.\n\nFor instance,\n\n (+ 3 5)\n\nwill return 8.\n\nIn Scheme, functions themselves are first class values. Functions can be passed as arguments, created anonymously (via lambda), etc...\n\nFor instance,\n\n ((lambda (x) (+ x 3)) 5)\n\nwill return 8.\n\nOne can define variables (in scheme) (changing their values (which you ought usually avoid) is generally done a bit differently) like this:\n\n (define blah 5)\n\nThat gives, well, blah the value of 5.\n\none can define functions via that syntax, with the business end of the define expression having a lambda expression, but there is a syntactic shortcut that basically translates to that:\n\n (define (myproc x 5)\n (+ x 5))\n\nNow you have a procedure myproc\n\n (myproc 3)\n\nwill return 8.\n\nThat ought be enough to get you started at least on understanding the basics of the syntax.\n\nThere're some slight differences in CL as far as defining stuff, and namespaces and so on.","timestamp":"2009-09-30T22:43:11+00:00","score":5},{"role":"OP","user_id":"anon_077078cde22529d0","comment_id":"c0dukob","kind":"comment","text":"Thanks man. This was very helpful.","timestamp":"2009-10-01T00:54:07+00:00","score":1},{"role":"answerer","user_id":"anon_d78384ab32bffd3a","comment_id":"c0dul0s","kind":"comment","text":"No prob.","timestamp":"2009-10-01T01:01:58+00:00","score":1}],"n_turns":4,"n_turns_after_thanks":1,"op_metadata":{"user_id":"anon_077078cde22529d0","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_d78384ab32bffd3a","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c0duebr","thanks_reply_id":"c0dukob","post_score":6,"answer_score":5,"preferred_answer_is_top_level":true}}
{"user_id":"anon_05b3659279315ff4","answerer_user_id":"anon_1c642060aa5b9b48","subreddit":"programming","timestamp":"2009-10-01T15:23:45+00:00","post_id":"9pw2j","question":"Ask Reddit: I'm about to graduate. Could you give me some advice on how to get a good start in the IT world?\n\nHi Reddit,\n\nHere's the gist. I'm graduating soon, moving to San Fransisco, and would like to start a career in programming. I'm a bit lost as to how to get off to a good start in the industry. So I was hoping I could get a bit of advice from you guys.\n\n**My Background**\n\nI'm 25, and will be graduating with a BS in Applied Math. My language of choice is C, although I'm just as proficient with C++ and Python. At the moment, I'm living in Colorado, but plan to move to San Francisco at the end of this semester upon graduation. From what I've heard and seen, the stretch of land between San Francisco and San Jose is the mecca of technology. I'm super excited.\n\nThe problem is that I don't really know where to start. When I look at most of the job ads on DICE, I see requests for very specific skills. While I have some experience in these areas (say, posix threads), I'm an expert in none. I started programming over 10 years ago, but I don't have any solid completed projects to show for it.\n\nIs it possible for a guy like me to get hired without any previous working experience in the industry? I have a very strong math background, and am well versed in Algorithms and proper software design. But like I said, I don't really have anything to show for it.\n\nMy main concern is making sure that I work somewhere interesting. I want to tackle interesting problems that actually mean something. I don't want to be a digital plumber that fixes bugs in an enterprise CRM system. Obviously though, I'll take what I can get just starting out.\n\nWhat advice would you guys have for someone just starting out in the software development world?\n\nThanks for the help.","preferred_answer":"Try and find a small company/start up. \n\nThe money won't be great, but in my experiance employers are more interested in passion and genuine ability to do the job. If you are enthusiastic and willing to learn you should be ok. \n\nI got my first job by being honest with my now boss. I got recomended to him by the boss of another company I was working for at the time (during my work placement year of a degree course) He was after a part time programmer to write some Windows applications and embedded PIC code. At the time I had never programmed Windows (was an Acorn programmer specialising in 6502 and ARM assembler) I told him \"I would like to help but I don't have the skills you need\"...His response, \"You can learn cant you?\" I was shocked, he was going to pay me to learn. \n\nI have never looked back, carried on working for him during my final year at Uni then went straight back. Been there ever since. Real nice the company has grown from him and I, to an employer of 12 engineers and others. \n\nI later found out he had interviewed a lot of programmers who made lots of claims, but when it came down to it couldn't do what he wanted. \n\nAnother piece of advice, when you do get your first programming job..if their are other engineers, ask them questions, pick there brains, experiance is a massive part of software development and there is no substitute for actually doing things yourself, but you can short circuit some of crap you go through. Also generally programmers like to pass on their knowledge and techniques.\n\nI think the main thing you need to decide is - Why are you going into the software industry? If it's money, look to the finacial, banking sector. \nIf it's technical challenges, you can't beat small companys. You will have to fulfill more than the role of a software developer. You gain experiance in working with customers and running a business. In bigger companies you are insulated from all that, you report to your manager.\n\nWe have just taken on a graduate in Systems Engineering. He doesn't know shit about programming (Uni's don't seem to teach *real world programming* anymore), but he has the right attitude and I am teaching him.\n\nHope this helps. Good luck.\n\nEdit: Can't understand why people are down voting you...\n\nEdit Edit: WTF? Every upvote you get, someone else downvotes you. What you playing at Reddit? This guy asks a sincere question and gets caned? Sort it out.","full_conversation":[{"role":"OP","user_id":"anon_05b3659279315ff4","comment_id":"9pw2j","kind":"post","text":"Ask Reddit: I'm about to graduate. Could you give me some advice on how to get a good start in the IT world?\n\nHi Reddit,\n\nHere's the gist. I'm graduating soon, moving to San Fransisco, and would like to start a career in programming. I'm a bit lost as to how to get off to a good start in the industry. So I was hoping I could get a bit of advice from you guys.\n\n**My Background**\n\nI'm 25, and will be graduating with a BS in Applied Math. My language of choice is C, although I'm just as proficient with C++ and Python. At the moment, I'm living in Colorado, but plan to move to San Francisco at the end of this semester upon graduation. From what I've heard and seen, the stretch of land between San Francisco and San Jose is the mecca of technology. I'm super excited.\n\nThe problem is that I don't really know where to start. When I look at most of the job ads on DICE, I see requests for very specific skills. While I have some experience in these areas (say, posix threads), I'm an expert in none. I started programming over 10 years ago, but I don't have any solid completed projects to show for it.\n\nIs it possible for a guy like me to get hired without any previous working experience in the industry? I have a very strong math background, and am well versed in Algorithms and proper software design. But like I said, I don't really have anything to show for it.\n\nMy main concern is making sure that I work somewhere interesting. I want to tackle interesting problems that actually mean something. I don't want to be a digital plumber that fixes bugs in an enterprise CRM system. Obviously though, I'll take what I can get just starting out.\n\nWhat advice would you guys have for someone just starting out in the software development world?\n\nThanks for the help.","timestamp":"2009-10-01T15:23:45+00:00","score":13},{"role":"answerer","user_id":"anon_1c642060aa5b9b48","comment_id":"c0dvkiy","kind":"comment","text":"Try and find a small company/start up. \n\nThe money won't be great, but in my experiance employers are more interested in passion and genuine ability to do the job. If you are enthusiastic and willing to learn you should be ok. \n\nI got my first job by being honest with my now boss. I got recomended to him by the boss of another company I was working for at the time (during my work placement year of a degree course) He was after a part time programmer to write some Windows applications and embedded PIC code. At the time I had never programmed Windows (was an Acorn programmer specialising in 6502 and ARM assembler) I told him \"I would like to help but I don't have the skills you need\"...His response, \"You can learn cant you?\" I was shocked, he was going to pay me to learn. \n\nI have never looked back, carried on working for him during my final year at Uni then went straight back. Been there ever since. Real nice the company has grown from him and I, to an employer of 12 engineers and others. \n\nI later found out he had interviewed a lot of programmers who made lots of claims, but when it came down to it couldn't do what he wanted. \n\nAnother piece of advice, when you do get your first programming job..if their are other engineers, ask them questions, pick there brains, experiance is a massive part of software development and there is no substitute for actually doing things yourself, but you can short circuit some of crap you go through. Also generally programmers like to pass on their knowledge and techniques.\n\nI think the main thing you need to decide is - Why are you going into the software industry? If it's money, look to the finacial, banking sector. \nIf it's technical challenges, you can't beat small companys. You will have to fulfill more than the role of a software developer. You gain experiance in working with customers and running a business. In bigger companies you are insulated from all that, you report to your manager.\n\nWe have just taken on a graduate in Systems Engineering. He doesn't know shit about programming (Uni's don't seem to teach *real world programming* anymore), but he has the right attitude and I am teaching him.\n\nHope this helps. Good luck.\n\nEdit: Can't understand why people are down voting you...\n\nEdit Edit: WTF? Every upvote you get, someone else downvotes you. What you playing at Reddit? This guy asks a sincere question and gets caned? Sort it out.","timestamp":"2009-10-01T17:53:23+00:00","score":12},{"role":"OP","user_id":"anon_05b3659279315ff4","comment_id":"c0dvv69","kind":"comment","text":"Thank you very much for your reply. I also posted this question to Hacker News and they suggested that I try networking at various conferences which also sounds like a good idea.","timestamp":"2009-10-01T20:48:52+00:00","score":1},{"role":"answerer","user_id":"anon_1c642060aa5b9b48","comment_id":"c0dvwq9","kind":"comment","text":"If you conduct yourself in the real world as you do on Reddit you will go a long way. \n\nAs you obviously have a tendancy towards math, maybe look into game physics programming, climate modelling or maybe parallel processing etc..There is another avenue...which is the Defence industry. I do have some experiance in this field and personally could not cope with the working practices. However they do have technology about 10 years in advance of what engineers in the public sector generally have access to. Of course you can't talk about it down the pub though ;-)","timestamp":"2009-10-01T21:12:38+00:00","score":1},{"role":"OP","user_id":"anon_05b3659279315ff4","comment_id":"c0dw88r","kind":"comment","text":"The defense industry sounds interesting, but I'm not sure that I would be able to get clearance since I hold dual citizenship (with an EU country through ancestry).","timestamp":"2009-10-02T00:49:33+00:00","score":1}],"n_turns":5,"n_turns_after_thanks":2,"op_metadata":{"user_id":"anon_05b3659279315ff4","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_1c642060aa5b9b48","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c0dvkiy","thanks_reply_id":"c0dvv69","post_score":13,"answer_score":12,"preferred_answer_is_top_level":true}}
{"user_id":"anon_a29206637752427d","answerer_user_id":"anon_7b06333c65fd9818","subreddit":"programming","timestamp":"2009-10-02T04:02:24+00:00","post_id":"9q2q5","question":"Looking for tips in generating aesthetic color palettes, for things like graphs and heat maps.\n\nParticularly, if I'm using something like: color(red, green, blue), and rgb are 0-255 values. Any tips on making algorithms to flow smoothly from like... orange into dark orange, to red, to purple? I've had some success with nesting for() loops, incrementing the Green value in small increments on the inner loop, and incrementing the Red value in medium increments on the outer loop.\n\nThe results are decent, but are there any tips for doing this properly?","preferred_answer":"Simple linear interpolation usually gives decent results for gradients. Something like:\n\n for (int step = from; step <= to; ++step) {\n red[step] = (from_red*(to-step) + to_red*(step-from)) / (from-to);\n grn[step] = (from_grn*(to-step) + to_grn*(step-from)) / (from-to);\n blu[step] = (from_blu*(to-step) + to_blu*(step-from)) / (from-to);\n } \n\nshould fill part the an array between from and to (inclusive) with a smooth gradient from the color (from\\_red,from\\_grn,from\\_blu) to the color (to\\_red,to\\_grn,to\\_blu). Turn it into a function and call multiple times to lay gradients end-to-end in order to go smoothly through a series of colors.\n\nFor classic rainbow colormaps, I like to use sine waves that are 120-degrees apart in phase and shifted and scaled in amplitude to go between 0 and 255.\n\nAn old favorite of mine gives a nice flame coloring (assuming a palette of 256 colors):\n\n for (int step = 0; step < 256; ++step)\n {\n red[step] = min(step * 4, 255);\n grn[step] = min(step * 2, 255);\n blu[step] = min(step * 1, 255);\n }","full_conversation":[{"role":"OP","user_id":"anon_a29206637752427d","comment_id":"9q2q5","kind":"post","text":"Looking for tips in generating aesthetic color palettes, for things like graphs and heat maps.\n\nParticularly, if I'm using something like: color(red, green, blue), and rgb are 0-255 values. Any tips on making algorithms to flow smoothly from like... orange into dark orange, to red, to purple? I've had some success with nesting for() loops, incrementing the Green value in small increments on the inner loop, and incrementing the Red value in medium increments on the outer loop.\n\nThe results are decent, but are there any tips for doing this properly?","timestamp":"2009-10-02T04:02:24+00:00","score":0},{"role":"answerer","user_id":"anon_7b06333c65fd9818","comment_id":"c0dwpxv","kind":"comment","text":"Simple linear interpolation usually gives decent results for gradients. Something like:\n\n for (int step = from; step <= to; ++step) {\n red[step] = (from_red*(to-step) + to_red*(step-from)) / (from-to);\n grn[step] = (from_grn*(to-step) + to_grn*(step-from)) / (from-to);\n blu[step] = (from_blu*(to-step) + to_blu*(step-from)) / (from-to);\n } \n\nshould fill part the an array between from and to (inclusive) with a smooth gradient from the color (from\\_red,from\\_grn,from\\_blu) to the color (to\\_red,to\\_grn,to\\_blu). Turn it into a function and call multiple times to lay gradients end-to-end in order to go smoothly through a series of colors.\n\nFor classic rainbow colormaps, I like to use sine waves that are 120-degrees apart in phase and shifted and scaled in amplitude to go between 0 and 255.\n\nAn old favorite of mine gives a nice flame coloring (assuming a palette of 256 colors):\n\n for (int step = 0; step < 256; ++step)\n {\n red[step] = min(step * 4, 255);\n grn[step] = min(step * 2, 255);\n blu[step] = min(step * 1, 255);\n }","timestamp":"2009-10-02T08:57:56+00:00","score":2},{"role":"OP","user_id":"anon_a29206637752427d","comment_id":"c0dwv64","kind":"comment","text":"Thank you very much. I'll be trying these later on. Can you confirm that the min() function returns values no higher than 255, after step * 4 goes over?","timestamp":"2009-10-02T13:14:07+00:00","score":1},{"role":"answerer","user_id":"anon_7b06333c65fd9818","comment_id":"c0dxe2n","kind":"comment","text":"Depending on your environment, you might need to define the min function yourself. You can always dodge the issue by hard coding it:\n\n red[step] = step < 64 ? step * 4 : 255;\n grn[step] = step < 128 ? step * 2 : 255;\n blu[step] = step < 256 ? step * 1 : 255;","timestamp":"2009-10-02T19:22:04+00:00","score":1}],"n_turns":4,"n_turns_after_thanks":1,"op_metadata":{"user_id":"anon_a29206637752427d","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_7b06333c65fd9818","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c0dwpxv","thanks_reply_id":"c0dwv64","post_score":0,"answer_score":2,"preferred_answer_is_top_level":true}}
{"user_id":"anon_2bb82cae722b36e9","answerer_user_id":"anon_1291da9c1149ea0c","subreddit":"programming","timestamp":"2009-10-03T09:17:18+00:00","post_id":"9qfum","question":"Ask Reddit: How does one write their own language? In binary? In another language?\n\nI am just starting out learning object oriented programming. VB if you want to know as it would be the most helpful where I work. I am blown away by the idea that an entire language itself is actually written. How is it done? \n\nEdit: I better clarify that I am a bona fide newbie at programming. In all areas.","preferred_answer":"> VB\n\nOuch. Do [SICP](http://en.wikipedia.org/wiki/Structure_and_Interpretation_of_Computer_Programs). It talks about topics that are exactly 100% the answer you're looking for in the later chapters. Also try some assembly on an embedded chip or at least try to get a reasonable idea on how assembly works.","full_conversation":[{"role":"OP","user_id":"anon_2bb82cae722b36e9","comment_id":"9qfum","kind":"post","text":"Ask Reddit: How does one write their own language? In binary? In another language?\n\nI am just starting out learning object oriented programming. VB if you want to know as it would be the most helpful where I work. I am blown away by the idea that an entire language itself is actually written. How is it done? \n\nEdit: I better clarify that I am a bona fide newbie at programming. In all areas.","timestamp":"2009-10-03T09:17:18+00:00","score":0},{"role":"answerer","user_id":"anon_1291da9c1149ea0c","comment_id":"c0dyarl","kind":"comment","text":"> VB\n\nOuch. Do [SICP](http://en.wikipedia.org/wiki/Structure_and_Interpretation_of_Computer_Programs). It talks about topics that are exactly 100% the answer you're looking for in the later chapters. Also try some assembly on an embedded chip or at least try to get a reasonable idea on how assembly works.","timestamp":"2009-10-03T09:23:28+00:00","score":2},{"role":"OP","user_id":"anon_2bb82cae722b36e9","comment_id":"c0dyb1g","kind":"comment","text":"Thanks, I'll look in to it. SICP looks old - it must be a seminal text to still be relevant. As far as writing assembly code, especially on an embedded chip, I think it may be above my station at the moment. I'm sure that starting on a high level language such as VB may not be best for the long run, but I am in my comfort zone so I'll stay there for a bit.","timestamp":"2009-10-03T09:39:09+00:00","score":2},{"role":"answerer","user_id":"anon_1291da9c1149ea0c","comment_id":"c0dybca","kind":"comment","text":"> especially on an embedded chip, I think it may be above my station at the moment\n\nIf you're in high school of beyond and as it seems you have more than a passing interest in this, you're more than ready. Pick the [6502](http://www.google.com.au/#hl=en&source=hp&q=6502&btnG=Google+Search&meta=&aq=f&oq=6502&fp=ef4dae79243053b3) or something like it.","timestamp":"2009-10-03T09:56:21+00:00","score":2}],"n_turns":4,"n_turns_after_thanks":1,"op_metadata":{"user_id":"anon_2bb82cae722b36e9","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_1291da9c1149ea0c","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c0dyarl","thanks_reply_id":"c0dyb1g","post_score":0,"answer_score":2,"preferred_answer_is_top_level":true}}
{"user_id":"anon_a58b04ce5b2045f3","answerer_user_id":"anon_02c94f6f5ad37878","subreddit":"programming","timestamp":"2009-10-11T02:07:08+00:00","post_id":"9suw4","question":"Hey proggit, could you guide my non-profit in setting up this free e-mail tutoring program?\n\nHere's the scenario: I live in one of the poorest cities in the U.S. and I recently formed a non-profit with a few people in the city. Our goal is to fight the short term effects and the long term causes for poverty in the city. One of the projects the organization is coordinating involves providing free e-mail help when inner city middle school and high school students have questions on their homework assignments. I have already enlisted the help of about 100 volunteers who are local area college students and young professionals and all that's needed now is for me to setup the system that coordinates everything.\n\nHere's how I have envisioned the system so far:\n\n* Tutor provides information to the organization on what he/she is good at and how many students he/she can take.\n\n* Organization advertises the program to the community and provides one e-mail address that students can e-mail when they have a question.\n\n* Someone (or an automated system) receives the student's initial e-mail and then forwards it to a tutor who is qualified and available.\n\n* Tutor responds personally to the student and cc's a different e-mail address belonging to the organization. This way the organization can make sure that the student's question is answered and can also track how busy the tutor is.\n\n* Future e-mails from the student are sent directly to the assigned tutor but the tutor must cc the org in all responses.\n\nThe problem right now is that the system requires someone to manually monitor the e-mails being received in order to assign the tutor, make sure the tutor responds, and to keep track of how busy a tutor is. This is completely unacceptable from both a scalability and a cost-effectiveness perspective. This is where you come in, proggit. **Do any of you know how I can automate this process? Or can you think of a better way to do this?** Would you be willing to guide me? I'm not a hardcore programmer but I do know how to tinker with code.\n\nP.S. I'm using a throwaway account for this mainly because I don't like others having a history of my comments and profiling me. I've been on reddit almost since day 1.\n\nEdit: Readability","preferred_answer":"Your needs seem to align pretty well with a \"helpdesk\" scenario. As an example of what I mean by \"helpdesk\", take a look at [cerberus](http://www.cerberusweb.com/home). Some of their features:\n\n> Remember anything about anybody, deftly reply to an e-mail flood, quarantine spam, capture organic feedback, track time, flag opportunities, share tasks, and otherwise collaborate efficiently.\n\nThe support staff at the company I work for uses cerberus, it seems to work quite well for us. It's also open source, so you can extend it to meet your needs in the future (if necessary). I do realize that cerberus is not free, but perhaps you can contact them and ask about a complimentary license for a non-profit. It could be a tax write off for them... there's certainly no harm in asking.\n\nThere are some recommendations for FOSS in this [ask slashdot article](http://ask.slashdot.org/article.pl?sid=09/02/26/236248).","full_conversation":[{"role":"OP","user_id":"anon_a58b04ce5b2045f3","comment_id":"9suw4","kind":"post","text":"Hey proggit, could you guide my non-profit in setting up this free e-mail tutoring program?\n\nHere's the scenario: I live in one of the poorest cities in the U.S. and I recently formed a non-profit with a few people in the city. Our goal is to fight the short term effects and the long term causes for poverty in the city. One of the projects the organization is coordinating involves providing free e-mail help when inner city middle school and high school students have questions on their homework assignments. I have already enlisted the help of about 100 volunteers who are local area college students and young professionals and all that's needed now is for me to setup the system that coordinates everything.\n\nHere's how I have envisioned the system so far:\n\n* Tutor provides information to the organization on what he/she is good at and how many students he/she can take.\n\n* Organization advertises the program to the community and provides one e-mail address that students can e-mail when they have a question.\n\n* Someone (or an automated system) receives the student's initial e-mail and then forwards it to a tutor who is qualified and available.\n\n* Tutor responds personally to the student and cc's a different e-mail address belonging to the organization. This way the organization can make sure that the student's question is answered and can also track how busy the tutor is.\n\n* Future e-mails from the student are sent directly to the assigned tutor but the tutor must cc the org in all responses.\n\nThe problem right now is that the system requires someone to manually monitor the e-mails being received in order to assign the tutor, make sure the tutor responds, and to keep track of how busy a tutor is. This is completely unacceptable from both a scalability and a cost-effectiveness perspective. This is where you come in, proggit. **Do any of you know how I can automate this process? Or can you think of a better way to do this?** Would you be willing to guide me? I'm not a hardcore programmer but I do know how to tinker with code.\n\nP.S. I'm using a throwaway account for this mainly because I don't like others having a history of my comments and profiling me. I've been on reddit almost since day 1.\n\nEdit: Readability","timestamp":"2009-10-11T02:07:08+00:00","score":0},{"role":"answerer","user_id":"anon_02c94f6f5ad37878","comment_id":"c0ea0t8","kind":"comment","text":"Your needs seem to align pretty well with a \"helpdesk\" scenario. As an example of what I mean by \"helpdesk\", take a look at [cerberus](http://www.cerberusweb.com/home). Some of their features:\n\n> Remember anything about anybody, deftly reply to an e-mail flood, quarantine spam, capture organic feedback, track time, flag opportunities, share tasks, and otherwise collaborate efficiently.\n\nThe support staff at the company I work for uses cerberus, it seems to work quite well for us. It's also open source, so you can extend it to meet your needs in the future (if necessary). I do realize that cerberus is not free, but perhaps you can contact them and ask about a complimentary license for a non-profit. It could be a tax write off for them... there's certainly no harm in asking.\n\nThere are some recommendations for FOSS in this [ask slashdot article](http://ask.slashdot.org/article.pl?sid=09/02/26/236248).","timestamp":"2009-10-11T03:33:47+00:00","score":2},{"role":"OP","user_id":"anon_a58b04ce5b2045f3","comment_id":"c0ea35y","kind":"comment","text":"Thank you for the reply. I'm still looking through the software that you mentioned but my initial area of concern is that all of these require for the tutor to sign in to the website on a fairly regular basis (or so it seems). Working with a group of volunteers, I don't think this can be expected. Since you've worked with Cereberus, do you know if there's any way to configure it so it e-mails the staff about tickets that they have been assigned?","timestamp":"2009-10-11T04:37:16+00:00","score":1},{"role":"answerer","user_id":"anon_02c94f6f5ad37878","comment_id":"c0eazjd","kind":"comment","text":"I'm actually not that familiar with Cerberus, as I don't use it personally. I just know that the employees that do use it seem to think it works quite well. A quick google search found [this link](http://forum.cerb4.com/showthread.php?t=132) for email notifications. It looks like setting \"watchers\" will work great. That's how the people distributing the tickets can assign them to individuals. That post was in 2007, so it's likely that the email notification plugin has improved since then.","timestamp":"2009-10-11T22:48:53+00:00","score":2}],"n_turns":4,"n_turns_after_thanks":1,"op_metadata":{"user_id":"anon_a58b04ce5b2045f3","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_02c94f6f5ad37878","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c0ea0t8","thanks_reply_id":"c0ea35y","post_score":0,"answer_score":2,"preferred_answer_is_top_level":true}}
{"user_id":"anon_63b8289d312454b8","answerer_user_id":"anon_803c12f2b474b74f","subreddit":"programming","timestamp":"2009-10-13T13:26:06+00:00","post_id":"9tkgq","question":"Can anyone point me to resources to learn to program for windows?\n\nI have basic experience in programming C, C++ and Intel assembly code. By basic I mean I understand the methodology of these language but I have never programmed anything that didnt run in a console. I study computer engineering in collage but this is geared mostly toward embedded systems. Im interested in learning to program for operating systems (especially windows) and creating GUI's but am having trouble finding resources online to learn how to do this. Ive googled but never found anywhere that explains windows architecture or methods. Can anyone help?","preferred_answer":"Well, I suggest you haven't googled hard enough. A search for \"Windows Programming\" brought in Charles Petzold's book which is one of the better all-round-great books about Windows. Microsoft.Net has changed things since the original publishing of that book, however I recommend learning something you can use on different platforms.\n\nBased on your stated experience, if that's what you want to continue using I recommend you look at QT or wxWindows as a platform independent way of developing applications. I personally prefer QT now that the library is LGPLed: http://qt.nokia.com/. QT is also used in embedded spaces.\n\nFinally, there are literally tons of free documentation available on MSDN online at Microsoft.","full_conversation":[{"role":"OP","user_id":"anon_63b8289d312454b8","comment_id":"9tkgq","kind":"post","text":"Can anyone point me to resources to learn to program for windows?\n\nI have basic experience in programming C, C++ and Intel assembly code. By basic I mean I understand the methodology of these language but I have never programmed anything that didnt run in a console. I study computer engineering in collage but this is geared mostly toward embedded systems. Im interested in learning to program for operating systems (especially windows) and creating GUI's but am having trouble finding resources online to learn how to do this. Ive googled but never found anywhere that explains windows architecture or methods. Can anyone help?","timestamp":"2009-10-13T13:26:06+00:00","score":0},{"role":"answerer","user_id":"anon_803c12f2b474b74f","comment_id":"c0edfj2","kind":"comment","text":"Well, I suggest you haven't googled hard enough. A search for \"Windows Programming\" brought in Charles Petzold's book which is one of the better all-round-great books about Windows. Microsoft.Net has changed things since the original publishing of that book, however I recommend learning something you can use on different platforms.\n\nBased on your stated experience, if that's what you want to continue using I recommend you look at QT or wxWindows as a platform independent way of developing applications. I personally prefer QT now that the library is LGPLed: http://qt.nokia.com/. QT is also used in embedded spaces.\n\nFinally, there are literally tons of free documentation available on MSDN online at Microsoft.","timestamp":"2009-10-13T13:35:09+00:00","score":2},{"role":"OP","user_id":"anon_63b8289d312454b8","comment_id":"c0edfwz","kind":"comment","text":"Thanks, but mostly my problem is that there's too much information on MSDN. I have no knowledge of how windows works and what I need is a tutorial, rather then the mass of information that is MSDN. Books are not an option considering the current state of my finances. Also my nearest library is 30 miles away and I dont own a car...","timestamp":"2009-10-13T13:45:31+00:00","score":2},{"role":"answerer","user_id":"anon_803c12f2b474b74f","comment_id":"c0edv7v","kind":"comment","text":"Then I suggest Google books then. There are a whole bunch of books available (not always in their entirety mindyou) that you can peruse.\n\nAlternatively, the book I mentionned might be available for free electronically somewhere.\n\nThe problem is that Windows as a whole is extremely complexe. Honestly, the best place to start would be with a framework that encapsulates the underlying windows subsystem. It sounds like QT might in fact be a good place for you, the tools are incidentally also free.","timestamp":"2009-10-13T18:41:10+00:00","score":1}],"n_turns":4,"n_turns_after_thanks":1,"op_metadata":{"user_id":"anon_63b8289d312454b8","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_803c12f2b474b74f","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c0edfj2","thanks_reply_id":"c0edfwz","post_score":0,"answer_score":2,"preferred_answer_is_top_level":true}}
{"user_id":"anon_a32dd6f8fbb42788","answerer_user_id":"anon_5732359882154894","subreddit":"programming","timestamp":"2009-10-14T06:02:19+00:00","post_id":"9tu5z","question":"Anybody know if this book is any good? \"Working Effectively with Legacy Code\" I do old code conversions and wondered about it's expertise level.","preferred_answer":"One thing I observed about these books (like shown in related items by Amazon) is extra emphasis on OOP. So they are less helpful in pure C kinda environments (which might be the old code you want to understand).","full_conversation":[{"role":"OP","user_id":"anon_a32dd6f8fbb42788","comment_id":"9tu5z","kind":"post","text":"Anybody know if this book is any good? \"Working Effectively with Legacy Code\" I do old code conversions and wondered about it's expertise level.","timestamp":"2009-10-14T06:02:19+00:00","score":8},{"role":"answerer","user_id":"anon_5732359882154894","comment_id":"c0eevg4","kind":"comment","text":"One thing I observed about these books (like shown in related items by Amazon) is extra emphasis on OOP. So they are less helpful in pure C kinda environments (which might be the old code you want to understand).","timestamp":"2009-10-14T06:36:44+00:00","score":6},{"role":"OP","user_id":"anon_a32dd6f8fbb42788","comment_id":"c0ei31l","kind":"comment","text":"\"(which might be the old code you want to understand).\"\nIt is thanks.","timestamp":"2009-10-16T01:07:26+00:00","score":1},{"role":"answerer","user_id":"anon_5732359882154894","comment_id":"c0eime3","kind":"comment","text":"same here, the only solution I found so far is to spend some time with the code.","timestamp":"2009-10-16T08:59:36+00:00","score":1}],"n_turns":4,"n_turns_after_thanks":1,"op_metadata":{"user_id":"anon_a32dd6f8fbb42788","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_5732359882154894","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c0eevg4","thanks_reply_id":"c0ei31l","post_score":8,"answer_score":6,"preferred_answer_is_top_level":true}}
{"user_id":"anon_1a716b7e10d6df81","answerer_user_id":"anon_e4ec2edfa9d47d3e","subreddit":"programming","timestamp":"2009-10-15T03:53:53+00:00","post_id":"9u701","question":"Is it possible to serve a non-watermarked image to those viewing the image on your site and a watermarked image for those hotlinking?","preferred_answer":"Yes","full_conversation":[{"role":"OP","user_id":"anon_1a716b7e10d6df81","comment_id":"9u701","kind":"post","text":"Is it possible to serve a non-watermarked image to those viewing the image on your site and a watermarked image for those hotlinking?","timestamp":"2009-10-15T03:53:53+00:00","score":47},{"role":"answerer","user_id":"anon_e4ec2edfa9d47d3e","comment_id":"c0egipx","kind":"comment","text":"Yes","timestamp":"2009-10-15T04:15:10+00:00","score":135},{"role":"OP","user_id":"anon_1a716b7e10d6df81","comment_id":"c0egiyb","kind":"comment","text":"Thanks","timestamp":"2009-10-15T04:20:05+00:00","score":79},{"role":"answerer","user_id":"anon_e4ec2edfa9d47d3e","comment_id":"c0egjg3","kind":"comment","text":"You're welcome.","timestamp":"2009-10-15T04:31:14+00:00","score":73}],"n_turns":4,"n_turns_after_thanks":1,"op_metadata":{"user_id":"anon_1a716b7e10d6df81","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_e4ec2edfa9d47d3e","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c0egipx","thanks_reply_id":"c0egiyb","post_score":47,"answer_score":135,"preferred_answer_is_top_level":true}}
{"user_id":"anon_9176c265300d6f99","answerer_user_id":"anon_dc4f4776a0722a12","subreddit":"programming","timestamp":"2009-10-17T10:27:10+00:00","post_id":"9uywd","question":"Can you beat my tic-tac-toe bot? This project was inspired by the /r/carlhprogramming sub-reddit. Code critiques welcome.","preferred_answer":"You must not be seeing the redundancies that are there in the code. Going back to my [earlier comment](http://www.reddit.com/r/programming/comments/9uywd/can_you_beat_my_tictactoe_bot_this_project_was/c0ekm52), look at my `Take()` function. The logic performed by this function appears at least 18 times in the original code: 14 times in the `TaccyBlockCorner()` function and 4 other times elsewhere. Similarly, the `OneCorner()` logic appears four times in the original code.\n\nAs another example, look at the `checkForWinner()` function in the original code. Do you see the block of code repeated three times?\n\nThis is the kind of redundancy you want to train yourself to find and refactor out. As [SnacksOnAPlane mentioned](http://www.reddit.com/r/programming/comments/9uywd/can_you_beat_my_tictactoe_bot_this_project_was/c0ekyah), it's probably the single most important thing you can take home from this exercise.","full_conversation":[{"role":"OP","user_id":"anon_9176c265300d6f99","comment_id":"9uywd","kind":"post","text":"Can you beat my tic-tac-toe bot? This project was inspired by the /r/carlhprogramming sub-reddit. Code critiques welcome.","timestamp":"2009-10-17T10:27:10+00:00","score":8},{"role":"answerer","user_id":"anon_dc4f4776a0722a12","comment_id":"c0elhng","kind":"comment","text":"You must not be seeing the redundancies that are there in the code. Going back to my [earlier comment](http://www.reddit.com/r/programming/comments/9uywd/can_you_beat_my_tictactoe_bot_this_project_was/c0ekm52), look at my `Take()` function. The logic performed by this function appears at least 18 times in the original code: 14 times in the `TaccyBlockCorner()` function and 4 other times elsewhere. Similarly, the `OneCorner()` logic appears four times in the original code.\n\nAs another example, look at the `checkForWinner()` function in the original code. Do you see the block of code repeated three times?\n\nThis is the kind of redundancy you want to train yourself to find and refactor out. As [SnacksOnAPlane mentioned](http://www.reddit.com/r/programming/comments/9uywd/can_you_beat_my_tictactoe_bot_this_project_was/c0ekyah), it's probably the single most important thing you can take home from this exercise.","timestamp":"2009-10-18T08:44:58+00:00","score":3},{"role":"OP","user_id":"anon_9176c265300d6f99","comment_id":"c0elnif","kind":"comment","text":"Duly noted. I'm going to work on this tonight and refactor these. Thank you to everybody in this thread. I think that I did know these were pretty poor ways to do it, or at least, very expanded forms of what they should be, but was too excited and focused about getting it functioning. I should have taken the time to condense the code before posting it.","timestamp":"2009-10-18T14:05:12+00:00","score":2},{"role":"answerer","user_id":"anon_dc4f4776a0722a12","comment_id":"c0emp4f","kind":"comment","text":"No need to apologize! You were brave enough to post unpolished code and ask for feedback. That earns you a lot of respect.","timestamp":"2009-10-19T04:35:37+00:00","score":4}],"n_turns":4,"n_turns_after_thanks":1,"op_metadata":{"user_id":"anon_9176c265300d6f99","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_dc4f4776a0722a12","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c0elhng","thanks_reply_id":"c0elnif","post_score":8,"answer_score":3,"preferred_answer_is_top_level":false}}
{"user_id":"anon_5f3aeec842b44b27","answerer_user_id":"anon_6a5b5fb61b59d0d5","subreddit":"programming","timestamp":"2009-10-19T10:13:00+00:00","post_id":"9vglo","question":"DAE find programmers difficult to work with?","preferred_answer":"I'm a programmer, so I'm not neutral on this topic. I have found very few programmers who are guilty of the failings you describe. Most programmers I know are inquisitive, reasonably open-minded, and genuinely interested in improving their knowledge and skills. However, I don't know many young programmers, and most of the programmers I know are pretty confident. The traits you describe probably correspond pretty closely to poor self confidence.\n\nThere is another point that may explain your experiences and mine at the same time. Consider the following parable:\n\nA old man sat at a roadside on the outskirts of his hometown. A traveler approached and asked the man, \"What are people like in this town?\"\n\n\"What were the people like in the town you just left?\" asked the man.\n\n\"Oh, they were terrible,\" replied the traveler. \"They were rude, greedy, stupid and unhappy people\"\n\n\"You'll probably find people are basically the same here,\" responded the old man.\n\nLater in the day, another traveler approached the old man and asked the same question about the townspeople. The old man replied with the same question he asked the earlier traveler.\n\n\"Oh, they were great,\" said the second traveler. \"They were very nice and welcoming people. They worked hard and they all seemed pretty happy.\"\n\nAgain the old man replied, \"You'll probably find people are basically the same here.\"","full_conversation":[{"role":"OP","user_id":"anon_5f3aeec842b44b27","comment_id":"9vglo","kind":"post","text":"DAE find programmers difficult to work with?","timestamp":"2009-10-19T10:13:00+00:00","score":121},{"role":"answerer","user_id":"anon_6a5b5fb61b59d0d5","comment_id":"c0en6ad","kind":"comment","text":"I'm a programmer, so I'm not neutral on this topic. I have found very few programmers who are guilty of the failings you describe. Most programmers I know are inquisitive, reasonably open-minded, and genuinely interested in improving their knowledge and skills. However, I don't know many young programmers, and most of the programmers I know are pretty confident. The traits you describe probably correspond pretty closely to poor self confidence.\n\nThere is another point that may explain your experiences and mine at the same time. Consider the following parable:\n\nA old man sat at a roadside on the outskirts of his hometown. A traveler approached and asked the man, \"What are people like in this town?\"\n\n\"What were the people like in the town you just left?\" asked the man.\n\n\"Oh, they were terrible,\" replied the traveler. \"They were rude, greedy, stupid and unhappy people\"\n\n\"You'll probably find people are basically the same here,\" responded the old man.\n\nLater in the day, another traveler approached the old man and asked the same question about the townspeople. The old man replied with the same question he asked the earlier traveler.\n\n\"Oh, they were great,\" said the second traveler. \"They were very nice and welcoming people. They worked hard and they all seemed pretty happy.\"\n\nAgain the old man replied, \"You'll probably find people are basically the same here.\"","timestamp":"2009-10-19T14:19:31+00:00","score":8},{"role":"OP","user_id":"anon_5f3aeec842b44b27","comment_id":"c0en6g7","kind":"comment","text":"Thank you for illuminating my point with a timely example. You probably think you were being clever, but I found your post to be smug and arrogant. No offense.","timestamp":"2009-10-19T14:23:00+00:00","score":-2},{"role":"answerer","user_id":"anon_6a5b5fb61b59d0d5","comment_id":"c0en6jy","kind":"comment","text":"So we're both right!","timestamp":"2009-10-19T14:25:02+00:00","score":3},{"role":"OP","user_id":"anon_5f3aeec842b44b27","comment_id":"c0en79m","kind":"comment","text":"I will cautiously agree to buy that for now, hoping but not expecting that after I work through the logic I won't find myself on the short end of the argument. :-)","timestamp":"2009-10-19T14:39:42+00:00","score":3}],"n_turns":5,"n_turns_after_thanks":2,"op_metadata":{"user_id":"anon_5f3aeec842b44b27","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_6a5b5fb61b59d0d5","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c0en6ad","thanks_reply_id":"c0en6g7","post_score":121,"answer_score":8,"preferred_answer_is_top_level":true}}
{"user_id":"anon_b477753e11ef235b","answerer_user_id":"anon_9c12fcfd87d642e1","subreddit":"programming","timestamp":"2009-10-22T18:56:36+00:00","post_id":"9wram","question":"What would you like to see in a generic ToString function?\n\nLets say you have a generic function called \"SafeToString\". The purpose is to be able to pass anything in and always get back a sane response without any exceptions. How would you want it to respond to these inputs?\r\n\r\n* Null -> Null or String.Empty\r\n* DBNull.Value -> Null, String.Empty, or some text like \"\"\r\n* Nullable containing a null -> Null, String.Empty, or some text like \"\"\r\n* FSharpOption containing None -> Null, String.Empty, or \"None\"\r\n* FSharpOption containing Some(5)-> \"5\" or \"Some(5)\"","preferred_answer":"I am trying to make you understand that you cannot treat 'null' as an object. Null is not an object. It is not a value. It has no constant associated with it (unlike DBNull.Value). Null has no memory address associated with it. Null is null. It means something should be there but isn't. It is important to understand the difference.","full_conversation":[{"role":"OP","user_id":"anon_b477753e11ef235b","comment_id":"9wram","kind":"post","text":"What would you like to see in a generic ToString function?\n\nLets say you have a generic function called \"SafeToString\". The purpose is to be able to pass anything in and always get back a sane response without any exceptions. How would you want it to respond to these inputs?\r\n\r\n* Null -> Null or String.Empty\r\n* DBNull.Value -> Null, String.Empty, or some text like \"\"\r\n* Nullable containing a null -> Null, String.Empty, or some text like \"\"\r\n* FSharpOption containing None -> Null, String.Empty, or \"None\"\r\n* FSharpOption containing Some(5)-> \"5\" or \"Some(5)\"","timestamp":"2009-10-22T18:56:36+00:00","score":0},{"role":"answerer","user_id":"anon_9c12fcfd87d642e1","comment_id":"c0eu3cs","kind":"comment","text":"I am trying to make you understand that you cannot treat 'null' as an object. Null is not an object. It is not a value. It has no constant associated with it (unlike DBNull.Value). Null has no memory address associated with it. Null is null. It means something should be there but isn't. It is important to understand the difference.","timestamp":"2009-10-23T13:07:37+00:00","score":0},{"role":"OP","user_id":"anon_b477753e11ef235b","comment_id":"c0eu8xc","kind":"comment","text":"Wow, you are really stupid. Everything you said is textbook perfect, but you still have no idea what we are talking about. You are stuck in \"My First Programming Class, day 1\". To understand how write a function can convert a null to an empty string, you really need to attend \"My First Programming Class, day 2\".","timestamp":"2009-10-23T15:13:58+00:00","score":1},{"role":"answerer","user_id":"anon_9c12fcfd87d642e1","comment_id":"c0eub6w","kind":"comment","text":"So I am stupid because everything I said is correct but you do not agree with it?\n\nIt is really easy to write a function that can convert a null to an empty string. It is pretty hard to do that with a method that belongs to an object. I strongly wish to see you doing that to enlighten me.","timestamp":"2009-10-23T15:53:36+00:00","score":1},{"role":"OP","user_id":"anon_b477753e11ef235b","comment_id":"c0eurj7","kind":"comment","text":"Again, this isn't about how to build it, it is about what string it should return.","timestamp":"2009-10-23T19:51:17+00:00","score":1},{"role":"answerer","user_id":"anon_9c12fcfd87d642e1","comment_id":"c0eutdo","kind":"comment","text":"I clearly stated that you cannot make a null.ToString function because there is no object in which such ToString function would belong to be called. You answered to that by saying that I should attend \"My First Programming Class, day 2\" to learn to code a function to convert null to a string. And you claimed I had no idea of what I was talking about.\n\nSo, after completely misquoting and failing to understand what I said, you insulted me. Twice. Then, when I called you on your mistake, it is no longer about how to build it? So, I was right? Again, I wanna see HOW you would make a code that allowed you to make a .ToString() since it is a very simple thing that you learned on your second day of programming.","timestamp":"2009-10-23T20:20:19+00:00","score":1},{"role":"OP","user_id":"anon_b477753e11ef235b","comment_id":"c0euvvj","kind":"comment","text":"I had always intented for the function to be used like this:\r\n\r\n StringHelpers.ToStringSafe( myObject );\r\n \r\nYou only imagined that I wanted to write it as a member function on null.","timestamp":"2009-10-23T21:01:04+00:00","score":1},{"role":"answerer","user_id":"anon_9c12fcfd87d642e1","comment_id":"c0evlte","kind":"comment","text":"I eddited my original post and addressed your point there as well.","timestamp":"2009-10-24T11:53:22+00:00","score":1}],"n_turns":8,"n_turns_after_thanks":5,"op_metadata":{"user_id":"anon_b477753e11ef235b","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_9c12fcfd87d642e1","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c0eu3cs","thanks_reply_id":"c0eu8xc","post_score":0,"answer_score":0,"preferred_answer_is_top_level":false}}
{"user_id":"anon_3a0b34d41ba851b4","answerer_user_id":"anon_7714e166518e5a8d","subreddit":"programming","timestamp":"2009-10-23T18:59:47+00:00","post_id":"9x4mr","question":"I'm looking for a low-priced full-featured hosting provider with Subversion support, and came across this one. Anyone have any experience with it?","preferred_answer":"I recently signed up with these guys. I would say they're optimized for developer types in terms of web hosting, which is exactly what I want but may not be for everyone. For example, they have a 1-click install of Trac and Rails and Django but not say, phpBB. They also have some pretty rare features like PostgreSQL databases, and static sites that will be served through nginx. You can even run things that sit there listening on an unprivileged port.\n\nHowever, their panel is relatively minimal outside of the fancy framework installer--basically email config, some dns stuff, account stuff... compared to your typical CPanel based host it has less, probably because they give you a shell and expect you to be able to do stuff yourself.\n\nThey also don't ridiculously oversell disk and bandwidth, so if you are looking for a place to park large collections of media you probably want something like dreamhost instead.\n\nOnly downsides so far for me is they don't host domains, so I have to keep my domains with godaddy(only because you can't transfer a .us to dreamhost) and dreamhost.","full_conversation":[{"role":"OP","user_id":"anon_3a0b34d41ba851b4","comment_id":"9x4mr","kind":"post","text":"I'm looking for a low-priced full-featured hosting provider with Subversion support, and came across this one. Anyone have any experience with it?","timestamp":"2009-10-23T18:59:47+00:00","score":0},{"role":"answerer","user_id":"anon_7714e166518e5a8d","comment_id":"c0eut2b","kind":"comment","text":"I recently signed up with these guys. I would say they're optimized for developer types in terms of web hosting, which is exactly what I want but may not be for everyone. For example, they have a 1-click install of Trac and Rails and Django but not say, phpBB. They also have some pretty rare features like PostgreSQL databases, and static sites that will be served through nginx. You can even run things that sit there listening on an unprivileged port.\n\nHowever, their panel is relatively minimal outside of the fancy framework installer--basically email config, some dns stuff, account stuff... compared to your typical CPanel based host it has less, probably because they give you a shell and expect you to be able to do stuff yourself.\n\nThey also don't ridiculously oversell disk and bandwidth, so if you are looking for a place to park large collections of media you probably want something like dreamhost instead.\n\nOnly downsides so far for me is they don't host domains, so I have to keep my domains with godaddy(only because you can't transfer a .us to dreamhost) and dreamhost.","timestamp":"2009-10-23T20:15:14+00:00","score":2},{"role":"OP","user_id":"anon_3a0b34d41ba851b4","comment_id":"c0evipu","kind":"comment","text":"Thanks for the info, every insightful.\nI had a hunch this was a no-frills, DIY kinda host. I do like that, but I'm also fond of a CPanel GUI :)\n\nWhat do you mean by they don't host domains? You cannot register a domain there, or they don't even have nameservers to point your domains to?","timestamp":"2009-10-24T08:16:06+00:00","score":1},{"role":"answerer","user_id":"anon_7714e166518e5a8d","comment_id":"c0ew2fg","kind":"comment","text":"I mean you can't transfer your domains to them for them to renew and maintain your whois records and so forth, because they aren't a registrar, most smaller webhosts are not(although you can basically just be a tucows reseller and write something into your control panel to facilitate that...but they don't to that either). \n\nThey do have nameservers that you can point your domains to, and you can edit the records within your control panel.","timestamp":"2009-10-24T21:10:13+00:00","score":1}],"n_turns":4,"n_turns_after_thanks":1,"op_metadata":{"user_id":"anon_3a0b34d41ba851b4","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_7714e166518e5a8d","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c0eut2b","thanks_reply_id":"c0evipu","post_score":0,"answer_score":2,"preferred_answer_is_top_level":true}}
{"user_id":"anon_3fbeb915161620cf","answerer_user_id":"anon_93dfd3ab946e6bab","subreddit":"programming","timestamp":"2009-10-27T01:39:44+00:00","post_id":"9y27t","question":"Java Certification: SCJA or the SCJP?\n\nI welcome any comments on some of the other Java certifications, such as the SCMAD. Thanks.\nhttp://uk.sun.com/training/certification/java/index.xml","preferred_answer":"SCJP. I'm not sure what the point of anything else would be. SCJP will serve as a good \"foot in the door\" at any place using Java. I would be interested in getting more, if I actually saw \"Minimum SCJD required\", which I haven't.","full_conversation":[{"role":"OP","user_id":"anon_3fbeb915161620cf","comment_id":"9y27t","kind":"post","text":"Java Certification: SCJA or the SCJP?\n\nI welcome any comments on some of the other Java certifications, such as the SCMAD. Thanks.\nhttp://uk.sun.com/training/certification/java/index.xml","timestamp":"2009-10-27T01:39:44+00:00","score":0},{"role":"answerer","user_id":"anon_93dfd3ab946e6bab","comment_id":"c0ezhnf","kind":"comment","text":"SCJP. I'm not sure what the point of anything else would be. SCJP will serve as a good \"foot in the door\" at any place using Java. I would be interested in getting more, if I actually saw \"Minimum SCJD required\", which I haven't.","timestamp":"2009-10-27T06:08:08+00:00","score":2},{"role":"OP","user_id":"anon_3fbeb915161620cf","comment_id":"c0ezy8r","kind":"comment","text":"Thanks so much for your response, I do appreciate it. I am going to take the exam, but I am going to be studying for it on my own. I have the exam preparation guide which I am going to work through. Do you have any other suggestions (I'm assuming that you have sat the SCJP)?","timestamp":"2009-10-27T15:56:09+00:00","score":1},{"role":"answerer","user_id":"anon_93dfd3ab946e6bab","comment_id":"c0f08xq","kind":"comment","text":"Unlike some other certification courses (Zend PHP is a glaring example), I thought the SCJP was fair and a good gauge of your java knowledge and experience. The SCJP prep guide WILL help you.","timestamp":"2009-10-27T19:07:00+00:00","score":1}],"n_turns":4,"n_turns_after_thanks":1,"op_metadata":{"user_id":"anon_3fbeb915161620cf","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_93dfd3ab946e6bab","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c0ezhnf","thanks_reply_id":"c0ezy8r","post_score":0,"answer_score":2,"preferred_answer_is_top_level":true}}
{"user_id":"anon_6146b190788b28b6","answerer_user_id":"anon_692600a27d2ad062","subreddit":"programming","timestamp":"2009-10-27T06:51:51+00:00","post_id":"9y509","question":"What an unrealistic job po--oh, dude, great satire","preferred_answer":"Wow, I want to read your resume like I want a root canal. You need to doll that thing up, bro.","full_conversation":[{"role":"OP","user_id":"anon_6146b190788b28b6","comment_id":"9y509","kind":"post","text":"What an unrealistic job po--oh, dude, great satire","timestamp":"2009-10-27T06:51:51+00:00","score":88},{"role":"answerer","user_id":"anon_692600a27d2ad062","comment_id":"c0ezxjp","kind":"comment","text":"Wow, I want to read your resume like I want a root canal. You need to doll that thing up, bro.","timestamp":"2009-10-27T15:43:48+00:00","score":11},{"role":"OP","user_id":"anon_6146b190788b28b6","comment_id":"c0f045y","kind":"comment","text":"I'll see what I can do. Thanks for the feedback.","timestamp":"2009-10-27T17:42:37+00:00","score":3},{"role":"answerer","user_id":"anon_692600a27d2ad062","comment_id":"c0f053x","kind":"comment","text":"Sorry, I should've been more constructive. Here we go:\n\nIt's good that you have a cover letter in mind when you're looking to apply for a job, but it's even better to personalize your cover letter to the tone of the job description and make specific points in response to what they're looking for. It's that level of personalization that will separate you from everyone else. Grab them with a short snappy sentence, and shorten the letter itself so it doesn't look so daunting. Remember: you only need to go into topics that aren't covered by your job experience descriptions and skill set description.\n\nYour past work experience, in general, has quite a bit in it, and it varies widely in terms of what you've done in each company. These are good things, but it's almost daunting to read through, mostly because it's written in bulleted form. Perhaps it's different for CS types, but I've found that using a more conversational tone (not too informal, mind you), at least makes the reading much more approachable. One-line blurbs tend to just look like an endless stream of half-connected thoughts that end up feeling incoherent.\n\nIn your second description, you mention at the top of the description that you were laid off. I realize what kind of time it is now, but, nevertheless, this information shouldn't sit directly next to your position or time employed. It belongs toward the bottom of the list of items (if at all).\n\nI have to head to a meeting, but I can update this later. Hope it helps.\n\nEdit: [My resume](http://www.ddrewdesign.com/images/resume2009.pdf) is by no means a hallmark of fantastic resume-ing, but I think it well articulates the kind of information dissemination you should go for.","timestamp":"2009-10-27T18:00:23+00:00","score":11},{"role":"OP","user_id":"anon_6146b190788b28b6","comment_id":"c0f06l6","kind":"comment","text":"Thanks! Those are great tips.","timestamp":"2009-10-27T18:25:40+00:00","score":1}],"n_turns":5,"n_turns_after_thanks":2,"op_metadata":{"user_id":"anon_6146b190788b28b6","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_692600a27d2ad062","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c0ezxjp","thanks_reply_id":"c0f045y","post_score":88,"answer_score":11,"preferred_answer_is_top_level":false}}
{"user_id":"anon_d6abda80239d39fa","answerer_user_id":"anon_437c9dfc6840e5bb","subreddit":"programming","timestamp":"2009-11-01T01:52:54+00:00","post_id":"9zsfo","question":"Capitalizing the first letter of every word in string in Java...\n\n**edit** Solved!! Thank you guys I can't believe I was so close to the answer... It was a matter of perspective. Thank you all for the helpful hints.\n\n\nThis is a bit embarrassing, but I am stumped on my intro to java assignment. I am to write a program that would capitalize the first letter of each word in a string... So far I have\n\t\n public class Homework5b\n\t{\n\t\tpublic static char toUpperCase(char ch)\n\t\t{\n\n\t\t\tif(ch >='a'&& ch <='z')\n\t\t\t{\n\t\t\t\treturn (char)(ch-32);\n\t\t\t}\n\t\t\treturn ch;\n\t\t}\n\t\tpublic static void main (String[] asd)\n\t\t{\n\t\t\tString s = \"My country tis of thee, Sweet land of liberty, Of thee I sing\";\n\t\t\tint len = s.length();\n\t\t\tfor(int j=0; j0 && ch==' ')\n\t\t\t\t\tSystem.out.print(\" \"+toUpperCase(s.charAt(j+1)));\n\t\t\t\telse\n\t\t\t\t\tSystem.out.print(ch);\n\t\t\t}\n\t\t\tSystem.out.println();\n\t\t}\n\t}\n\nI am not to use arrays... just simple loops.\nCould anybody help?","preferred_answer":"Oh, let me amend my statement. I apologize, I was not too clear.\n\n1. The loop processes one character at a time, over each character of the string.\n2. But the j'th character is a space, you also process the (j+1)'th character.\n3. Think of a way so that you don't process the j+1 character again.\n\nThere are multiple ways of solving this. One way involves changing only two characters in your code. One way involves a boolean flag like thefightforgood suggested.\n\n(I'm deliberately trying not to give you the answer. =P)","full_conversation":[{"role":"OP","user_id":"anon_d6abda80239d39fa","comment_id":"9zsfo","kind":"post","text":"Capitalizing the first letter of every word in string in Java...\n\n**edit** Solved!! Thank you guys I can't believe I was so close to the answer... It was a matter of perspective. Thank you all for the helpful hints.\n\n\nThis is a bit embarrassing, but I am stumped on my intro to java assignment. I am to write a program that would capitalize the first letter of each word in a string... So far I have\n\t\n public class Homework5b\n\t{\n\t\tpublic static char toUpperCase(char ch)\n\t\t{\n\n\t\t\tif(ch >='a'&& ch <='z')\n\t\t\t{\n\t\t\t\treturn (char)(ch-32);\n\t\t\t}\n\t\t\treturn ch;\n\t\t}\n\t\tpublic static void main (String[] asd)\n\t\t{\n\t\t\tString s = \"My country tis of thee, Sweet land of liberty, Of thee I sing\";\n\t\t\tint len = s.length();\n\t\t\tfor(int j=0; j0 && ch==' ')\n\t\t\t\t\tSystem.out.print(\" \"+toUpperCase(s.charAt(j+1)));\n\t\t\t\telse\n\t\t\t\t\tSystem.out.print(ch);\n\t\t\t}\n\t\t\tSystem.out.println();\n\t\t}\n\t}\n\nI am not to use arrays... just simple loops.\nCould anybody help?","timestamp":"2009-11-01T01:52:54+00:00","score":0},{"role":"answerer","user_id":"anon_437c9dfc6840e5bb","comment_id":"c0f6sdc","kind":"comment","text":"Oh, let me amend my statement. I apologize, I was not too clear.\n\n1. The loop processes one character at a time, over each character of the string.\n2. But the j'th character is a space, you also process the (j+1)'th character.\n3. Think of a way so that you don't process the j+1 character again.\n\nThere are multiple ways of solving this. One way involves changing only two characters in your code. One way involves a boolean flag like thefightforgood suggested.\n\n(I'm deliberately trying not to give you the answer. =P)","timestamp":"2009-11-01T02:19:09+00:00","score":1},{"role":"OP","user_id":"anon_d6abda80239d39fa","comment_id":"c0f6skm","kind":"comment","text":"I appreciate that you aren't giving me the answer. I will submit the program with the boolean flag if I cannot figure it out on my own. =)","timestamp":"2009-11-01T02:26:35+00:00","score":1},{"role":"answerer","user_id":"anon_437c9dfc6840e5bb","comment_id":"c0f6wq4","kind":"comment","text":"Well since you solved it, here's what I did. Turns out I needed two changes because of an unrelated bug in your program. Assuming public class Homework5b is line 1.\n\nchange line 21: else if (ch == ' ')\n\nchange line 22: System.out.print(\" \" + toUpperCase(s.charAt(++j)));\n\nThe change on line 21 is needed because otherwise the first character of the string gets printed twice. Because this else-if clause is now part of the if clause, we can remove the j>0 test since j is always greater than 0 if we reach this point.\n\nThe change on line 22 increments j and then passes the value to toUpperCase. Then when this statement finishes, and the rest of the for loop runs, j is incremented again, and it essentially skips over the uppercased character.","timestamp":"2009-11-01T04:53:54+00:00","score":1}],"n_turns":4,"n_turns_after_thanks":1,"op_metadata":{"user_id":"anon_d6abda80239d39fa","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_437c9dfc6840e5bb","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c0f6sdc","thanks_reply_id":"c0f6skm","post_score":0,"answer_score":1,"preferred_answer_is_top_level":false}}
{"user_id":"anon_2cf0320cd22322f6","answerer_user_id":"anon_db81191e4aa30dca","subreddit":"programming","timestamp":"2009-11-03T22:47:51+00:00","post_id":"a0nm8","question":"Ask proggit: What's a good tool that essentially generates and operates on a call-graph for C?\n\nBonus points if it works in cygwin, extra bonus points if it integrates with vim somehow (kind of like ctags on steroids). I used Java in Eclipse for a while in grad school and got pretty addicted to knowing instantly where a given method was being called. Now I'm working with a fucking massive C codebase and miss that ability horribly.","preferred_answer":"Cscope to the rescue ..","full_conversation":[{"role":"OP","user_id":"anon_2cf0320cd22322f6","comment_id":"a0nm8","kind":"post","text":"Ask proggit: What's a good tool that essentially generates and operates on a call-graph for C?\n\nBonus points if it works in cygwin, extra bonus points if it integrates with vim somehow (kind of like ctags on steroids). I used Java in Eclipse for a while in grad school and got pretty addicted to knowing instantly where a given method was being called. Now I'm working with a fucking massive C codebase and miss that ability horribly.","timestamp":"2009-11-03T22:47:51+00:00","score":0},{"role":"answerer","user_id":"anon_db81191e4aa30dca","comment_id":"c0favwb","kind":"comment","text":"Cscope to the rescue ..","timestamp":"2009-11-03T23:04:51+00:00","score":2},{"role":"OP","user_id":"anon_2cf0320cd22322f6","comment_id":"c0fawrb","kind":"comment","text":"Thanks! I'd heard of cscope before, but it seemed like a tremendous pain in the ass to get it working under cygwin. Turns out it's actually a cygwin package, but under \"mlcscope.\" Just in case anyone else has the same question.\n\nThanks again!","timestamp":"2009-11-03T23:18:59+00:00","score":2},{"role":"answerer","user_id":"anon_db81191e4aa30dca","comment_id":"c0fbmlh","kind":"comment","text":"Get it integrated into vim and get into the habit of generating cscope.out for all your projects, and set it up properly to include sources from everywhere your build system will be retrieving them, and you will never look back at the dark days without cscope again .. cscope is, basically, a C programmers best friend. \n\nvim+cscope+MakeRuleToBuild_cscope.out_Properly == FunFunFun!","timestamp":"2009-11-04T09:31:24+00:00","score":1}],"n_turns":4,"n_turns_after_thanks":1,"op_metadata":{"user_id":"anon_2cf0320cd22322f6","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_db81191e4aa30dca","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c0favwb","thanks_reply_id":"c0fawrb","post_score":0,"answer_score":2,"preferred_answer_is_top_level":true}}
{"user_id":"anon_2c829491681d05ed","answerer_user_id":"anon_2a577191de7b397d","subreddit":"programming","timestamp":"2009-11-04T23:43:35+00:00","post_id":"a11x0","question":"Dear Proggit: Does this software exist?\n\nI was wondering if you could help me out on a personal project. I'm not sure if this software actually exists or if I'm going to have to write this myself; I am looking for a piece of software that visually plot the relationships of one entity in a network against another. An example of what I'm looking for would be to use a network of friends for instance; I know John via Erinn, and Erinn introduced me to Alex etc etc - once I have plotted these relationships I would very quickly be able to see that in my network of friends, Erinn is the key connector and as such the Erinn name would be either 'bigger' or 'redder' or more bold depending on the number of links it has sprouting out of it.\n\nAnother implementation of this would be to plot the elements in the periodic table against the most commonly used chemicals - this would visually display the most useful or most commonly used elements.\n\nDoes anybody know of anything out there before I go out and reinvent the wheel?","preferred_answer":"Try the statnet package here: http://erzuli.ss.uci.edu/R.stuff/\n\nThis is really a quite simple question. If you have the dataset, just count the # of connections each member has. If you want to visualize it, try the R package I mentioned, or any of these: \nhttp://en.wikipedia.org/wiki/Social_network_analysis_software\n\nEDIT: if you know Matlab, then I'm sure it has many many similar packages.","full_conversation":[{"role":"OP","user_id":"anon_2c829491681d05ed","comment_id":"a11x0","kind":"post","text":"Dear Proggit: Does this software exist?\n\nI was wondering if you could help me out on a personal project. I'm not sure if this software actually exists or if I'm going to have to write this myself; I am looking for a piece of software that visually plot the relationships of one entity in a network against another. An example of what I'm looking for would be to use a network of friends for instance; I know John via Erinn, and Erinn introduced me to Alex etc etc - once I have plotted these relationships I would very quickly be able to see that in my network of friends, Erinn is the key connector and as such the Erinn name would be either 'bigger' or 'redder' or more bold depending on the number of links it has sprouting out of it.\n\nAnother implementation of this would be to plot the elements in the periodic table against the most commonly used chemicals - this would visually display the most useful or most commonly used elements.\n\nDoes anybody know of anything out there before I go out and reinvent the wheel?","timestamp":"2009-11-04T23:43:35+00:00","score":3},{"role":"answerer","user_id":"anon_2a577191de7b397d","comment_id":"c0fcqy3","kind":"comment","text":"Try the statnet package here: http://erzuli.ss.uci.edu/R.stuff/\n\nThis is really a quite simple question. If you have the dataset, just count the # of connections each member has. If you want to visualize it, try the R package I mentioned, or any of these: \nhttp://en.wikipedia.org/wiki/Social_network_analysis_software\n\nEDIT: if you know Matlab, then I'm sure it has many many similar packages.","timestamp":"2009-11-05T00:20:23+00:00","score":2},{"role":"OP","user_id":"anon_2c829491681d05ed","comment_id":"c0fcr8r","kind":"comment","text":"Thanks for the links. Ideally I would like to visually represent the # of connections each member had - and as such that member would be more prominent.","timestamp":"2009-11-05T00:26:45+00:00","score":1},{"role":"answerer","user_id":"anon_2a577191de7b397d","comment_id":"c0fcrba","kind":"comment","text":"Right, so any graph graphing package is going to let you do that.","timestamp":"2009-11-05T00:28:18+00:00","score":2},{"role":"OP","user_id":"anon_2c829491681d05ed","comment_id":"c0fcrsy","kind":"comment","text":"Just checked out Statnet - thats seriously way more hardcore than I envisaged! But thanks for the links - I think JIT might be the way forward for me.","timestamp":"2009-11-05T00:38:22+00:00","score":1}],"n_turns":5,"n_turns_after_thanks":2,"op_metadata":{"user_id":"anon_2c829491681d05ed","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_2a577191de7b397d","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c0fcqy3","thanks_reply_id":"c0fcr8r","post_score":3,"answer_score":2,"preferred_answer_is_top_level":false}}
{"user_id":"anon_cf5142061068d3fb","answerer_user_id":"anon_f94121218658d15f","subreddit":"programming","timestamp":"2009-11-05T02:13:11+00:00","post_id":"a133q","question":"What is a good, overall measure of benchmark time scores?\n\nI'm writing a little benchmark program that measures execution times of a few things in matlab and octave (e.g. matrix manipulations, image processing operations, plot generation, equation solving etc). At the end, apart from the times for each test, I would like to have one measure, calculated based on the individual time scores ,that shows the overall performance of the matlab/octave. \n\nThe mean value of individual time scores is the most obvious, but I think it is not very good. Maybe Root mean square (RMS) would be better, or maybe there are other measures more appropriate. \n\nThanks","preferred_answer":"> one measure\n\n\"For every complex problem there is an answer that is clear, simple, and wrong.\" :-)\n\nCheck out the [Boxplot Summary](http://shootout.alioth.debian.org/u32/benchmark.php?test=all&lang=all&box=1#about) and check out the pdf article.\n\nCheck out the [Ranking](http://shootout.alioth.debian.org/u32/benchmark.php?test=all&lang=all&d=data#about) and check out the pdf article.","full_conversation":[{"role":"OP","user_id":"anon_cf5142061068d3fb","comment_id":"a133q","kind":"post","text":"What is a good, overall measure of benchmark time scores?\n\nI'm writing a little benchmark program that measures execution times of a few things in matlab and octave (e.g. matrix manipulations, image processing operations, plot generation, equation solving etc). At the end, apart from the times for each test, I would like to have one measure, calculated based on the individual time scores ,that shows the overall performance of the matlab/octave. \n\nThe mean value of individual time scores is the most obvious, but I think it is not very good. Maybe Root mean square (RMS) would be better, or maybe there are other measures more appropriate. \n\nThanks","timestamp":"2009-11-05T02:13:11+00:00","score":0},{"role":"answerer","user_id":"anon_f94121218658d15f","comment_id":"c0fcyok","kind":"comment","text":"> one measure\n\n\"For every complex problem there is an answer that is clear, simple, and wrong.\" :-)\n\nCheck out the [Boxplot Summary](http://shootout.alioth.debian.org/u32/benchmark.php?test=all&lang=all&box=1#about) and check out the pdf article.\n\nCheck out the [Ranking](http://shootout.alioth.debian.org/u32/benchmark.php?test=all&lang=all&d=data#about) and check out the pdf article.","timestamp":"2009-11-05T03:01:54+00:00","score":1},{"role":"OP","user_id":"anon_cf5142061068d3fb","comment_id":"c0fczga","kind":"comment","text":"Thanks. \"How not to lie with statistics: the correct way to summarize benchmark results\" is interesting.","timestamp":"2009-11-05T03:17:38+00:00","score":1},{"role":"answerer","user_id":"anon_f94121218658d15f","comment_id":"c0fd1py","kind":"comment","text":"More interesting to use more than one number in your descriptive statistics! ;-)","timestamp":"2009-11-05T03:59:59+00:00","score":1}],"n_turns":4,"n_turns_after_thanks":1,"op_metadata":{"user_id":"anon_cf5142061068d3fb","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_f94121218658d15f","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c0fcyok","thanks_reply_id":"c0fczga","post_score":0,"answer_score":1,"preferred_answer_is_top_level":true}}
{"user_id":"anon_6eb14bf04f02fde8","answerer_user_id":"anon_651c37c968913e9d","subreddit":"programming","timestamp":"2009-11-05T23:30:49+00:00","post_id":"a1fhi","question":"help! running a psychology study and am having java problems (repost from askreddit)\n\nedit: Phire fixed it. Thanks everyone.\n\n\nI posted this story in /r/askreddit initially, though it seems now that it may be better suited for /r/programming. Essentially, I'm running a psychology study that involves a Yahoo maze Java game, but the maze is obsolete or otherwise missing. Are there any programmers out there who would be able to reproduce this for me? I know it's a lot to ask but I'm desperate here; I can't find another one like it on the web.\n\nlink to original post explaining more what I'm doing:\n\nhttp://www.reddit.com/r/AskReddit/comments/a121o/help_running_a_psychology_study_and_am_having/\n\nDescription of what I need, taken from my post in the old topic:\n\n\"It needs to be a simple maze generator with a \"path verify\" button that players can use to check if they are going in the right direction. (The player navigates the maze with the arrow keys.) It should be moderately difficult, enough so as to drive some people to use the \"path verify\" cheat button. (Though it shouldn't say explicitly that the button is a cheat.) After the player completes one maze (by cheating or otherwise) it should randomly generate another maze. There are some screenshots of the Yahoo maze still up and a brief description of it here:\n\nhttp://uk.games.yahoo.com/online-games/puzzle/games_maze.html\n\nI don't think I want to have an \"auto solve\" button, though. Also, if there's a way to count how many times/how long the person used the \"path verify\" button that would be great. Maybe the count could be hidden until I come after the experiment and hit a certain button combination?\"\n\n\nI would really appreciate it if someone could help me here. I'm in dire need!","preferred_answer":"Well, I found the original jar file. But I can't work out how to launch it.\n\nhttp://games.yahoo.com/litsoft/general/mz.jar\n\nThe mime types are incorrect, you will need so save page as to download it.","full_conversation":[{"role":"OP","user_id":"anon_6eb14bf04f02fde8","comment_id":"a1fhi","kind":"post","text":"help! running a psychology study and am having java problems (repost from askreddit)\n\nedit: Phire fixed it. Thanks everyone.\n\n\nI posted this story in /r/askreddit initially, though it seems now that it may be better suited for /r/programming. Essentially, I'm running a psychology study that involves a Yahoo maze Java game, but the maze is obsolete or otherwise missing. Are there any programmers out there who would be able to reproduce this for me? I know it's a lot to ask but I'm desperate here; I can't find another one like it on the web.\n\nlink to original post explaining more what I'm doing:\n\nhttp://www.reddit.com/r/AskReddit/comments/a121o/help_running_a_psychology_study_and_am_having/\n\nDescription of what I need, taken from my post in the old topic:\n\n\"It needs to be a simple maze generator with a \"path verify\" button that players can use to check if they are going in the right direction. (The player navigates the maze with the arrow keys.) It should be moderately difficult, enough so as to drive some people to use the \"path verify\" cheat button. (Though it shouldn't say explicitly that the button is a cheat.) After the player completes one maze (by cheating or otherwise) it should randomly generate another maze. There are some screenshots of the Yahoo maze still up and a brief description of it here:\n\nhttp://uk.games.yahoo.com/online-games/puzzle/games_maze.html\n\nI don't think I want to have an \"auto solve\" button, though. Also, if there's a way to count how many times/how long the person used the \"path verify\" button that would be great. Maybe the count could be hidden until I come after the experiment and hit a certain button combination?\"\n\n\nI would really appreciate it if someone could help me here. I'm in dire need!","timestamp":"2009-11-05T23:30:49+00:00","score":3},{"role":"answerer","user_id":"anon_651c37c968913e9d","comment_id":"c0felv9","kind":"comment","text":"Well, I found the original jar file. But I can't work out how to launch it.\n\nhttp://games.yahoo.com/litsoft/general/mz.jar\n\nThe mime types are incorrect, you will need so save page as to download it.","timestamp":"2009-11-06T00:48:45+00:00","score":3},{"role":"OP","user_id":"anon_6eb14bf04f02fde8","comment_id":"c0fem7r","kind":"comment","text":"Thanks phire. Does anyone know how I would open a .jar file? It's a type of compression, isn't it?","timestamp":"2009-11-06T00:56:14+00:00","score":1},{"role":"answerer","user_id":"anon_651c37c968913e9d","comment_id":"c0fempe","kind":"comment","text":"Just rename it to .zip and it will open. However, thats not very useful.\n\nI created a file called maze.html in the same folder, put this inside it:\n\n \n \n \n\nAnd then opened that in my browser. It runs, but it brings up a message saying: \"Game not available on this page. Please report the problem to the webmaster.\" \nI'm guessing the developer added some anti-hotlinking protection, so it will only run on the original page.","timestamp":"2009-11-06T01:05:28+00:00","score":18}],"n_turns":4,"n_turns_after_thanks":1,"op_metadata":{"user_id":"anon_6eb14bf04f02fde8","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_651c37c968913e9d","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c0felv9","thanks_reply_id":"c0fem7r","post_score":3,"answer_score":3,"preferred_answer_is_top_level":true}}
{"user_id":"anon_44acfbc4dc899e6b","answerer_user_id":"anon_9c12fcfd87d642e1","subreddit":"programming","timestamp":"2009-11-06T18:37:39+00:00","post_id":"a1pye","question":"Proggit: I want to build a project, but am overwhelmed by the plethora of decisions I need to make up front\n\nI learned to program with PHP: gross. I ditched this quick, and have been working mostly in Python for the last 6 months. I want to build a project on a sturdy foundation, but am stuck in a state of ambivalence on what to use. If I were to use Python:\n\n- What OS/Distro do a I use? FreeBSD? Linux/CentOS? Linux/Debian?\n- What Filesystem should I use? Should I look into something like HadoopFS? ZFS?\n- What web server do I use? Or do I use more than one?\n- What Framework do I use?\n- Do I use SQL or a Hash Table? If SQL, do I use an ORM? Which one? I've always worked with MySQL as a default, is this the right choice?\n- I hear setuptools is the devil? How should modules be managed?\n- Threading? GIL?\n- What do I use for source control management?\n- What do I use for documentation?\n- What do I use for unit testing?\n- What do I use for monitoring?\n- Security?\n- Should I run this on the JVM? If so, should I get thoroughly intimate with it, as well as Jython? Or should I even be using Python in the first place?\n- JavaScript frameworks? Dear god\n- Should I host on something like Amazon Elastic servers?\n\nSeriously, these are only the things I can think of off the top of my head. I've been so confounded for the past year I haven't actually built anything. I've just been jumping from one technology to another technology, without actually getting intimate with any.\n\nShould I stick with Python? I understand it's a solid language, but is it a good language to use for a project that I may be maintaining 10 years from now? Does it have the capability to utilize the slew of new hardware features? Or should I start looking at something like Scala?\n\n *** Edit\n\nThe project I want to start is to become my full time business. It will be the crux of what I hope will become a decent sized corporation. \n\nA question that frames my thinking is:\n\nIf you were to rewrite Facebook from scratch, what technologies would you choose?","preferred_answer":"Most advice here is good but I will add one that no one said before. You are starting your project, and you seem to be inexperienced and to be working alone. You will fail. Do not let this make you give up your project.\n\nYour first version will be a spaghetti code filled with band-aid corrections and anti-patterns. Do not worry. Just hack away until it is impossible to keep going and then just restart it from scratch. Your first version will be your proof-of-concept. You will make it so you will know you can make it.\n\nWhen you are done with it, you will probably know enough about the project to know the answers to all your questions and then some. Restart it from scratch, do it right, come back and tell us the results. We are looking forward to it.","full_conversation":[{"role":"OP","user_id":"anon_44acfbc4dc899e6b","comment_id":"a1pye","kind":"post","text":"Proggit: I want to build a project, but am overwhelmed by the plethora of decisions I need to make up front\n\nI learned to program with PHP: gross. I ditched this quick, and have been working mostly in Python for the last 6 months. I want to build a project on a sturdy foundation, but am stuck in a state of ambivalence on what to use. If I were to use Python:\n\n- What OS/Distro do a I use? FreeBSD? Linux/CentOS? Linux/Debian?\n- What Filesystem should I use? Should I look into something like HadoopFS? ZFS?\n- What web server do I use? Or do I use more than one?\n- What Framework do I use?\n- Do I use SQL or a Hash Table? If SQL, do I use an ORM? Which one? I've always worked with MySQL as a default, is this the right choice?\n- I hear setuptools is the devil? How should modules be managed?\n- Threading? GIL?\n- What do I use for source control management?\n- What do I use for documentation?\n- What do I use for unit testing?\n- What do I use for monitoring?\n- Security?\n- Should I run this on the JVM? If so, should I get thoroughly intimate with it, as well as Jython? Or should I even be using Python in the first place?\n- JavaScript frameworks? Dear god\n- Should I host on something like Amazon Elastic servers?\n\nSeriously, these are only the things I can think of off the top of my head. I've been so confounded for the past year I haven't actually built anything. I've just been jumping from one technology to another technology, without actually getting intimate with any.\n\nShould I stick with Python? I understand it's a solid language, but is it a good language to use for a project that I may be maintaining 10 years from now? Does it have the capability to utilize the slew of new hardware features? Or should I start looking at something like Scala?\n\n *** Edit\n\nThe project I want to start is to become my full time business. It will be the crux of what I hope will become a decent sized corporation. \n\nA question that frames my thinking is:\n\nIf you were to rewrite Facebook from scratch, what technologies would you choose?","timestamp":"2009-11-06T18:37:39+00:00","score":0},{"role":"answerer","user_id":"anon_9c12fcfd87d642e1","comment_id":"c0ffpme","kind":"comment","text":"Most advice here is good but I will add one that no one said before. You are starting your project, and you seem to be inexperienced and to be working alone. You will fail. Do not let this make you give up your project.\n\nYour first version will be a spaghetti code filled with band-aid corrections and anti-patterns. Do not worry. Just hack away until it is impossible to keep going and then just restart it from scratch. Your first version will be your proof-of-concept. You will make it so you will know you can make it.\n\nWhen you are done with it, you will probably know enough about the project to know the answers to all your questions and then some. Restart it from scratch, do it right, come back and tell us the results. We are looking forward to it.","timestamp":"2009-11-06T19:10:32+00:00","score":1},{"role":"OP","user_id":"anon_44acfbc4dc899e6b","comment_id":"c0ffqdq","kind":"comment","text":"I appreciate the sentiment. I've actually already taken a run at this project once before. It was a total disaster. Not only was vision unclear, my programming abilities were poor. I've spent the last year and a half solidifying (relatively) my technical capacity. Now I want to take the next (first) step.","timestamp":"2009-11-06T19:24:34+00:00","score":1},{"role":"answerer","user_id":"anon_9c12fcfd87d642e1","comment_id":"c0ffr2r","kind":"comment","text":"> If you were to rewrite Facebook from scratch, what technologies would you choose?\n\nLearn from the past and do not try to reinvent the wheel. What did they use?","timestamp":"2009-11-06T19:35:37+00:00","score":1},{"role":"OP","user_id":"anon_44acfbc4dc899e6b","comment_id":"c0ffrs8","kind":"comment","text":"I watched a video about one of their head engineers lamenting about PHP. I'm not trying to rewrite Facebook, I'm just using it as example of a project that wasn't forward thinking enough and got locked in with technologies that leave much to be desired. If I had to work on a PHP project of that size I would shoot myself.","timestamp":"2009-11-06T19:47:19+00:00","score":1},{"role":"answerer","user_id":"anon_9c12fcfd87d642e1","comment_id":"c0ffs23","kind":"comment","text":"Let me rephrase myself, then. Find something similar to what you want to do that was done in the past. Find ALL similar projects you can think of and learn about what they did. Find out what the ones that failed did, and what the ones that succeeded did.","timestamp":"2009-11-06T19:51:38+00:00","score":1}],"n_turns":6,"n_turns_after_thanks":3,"op_metadata":{"user_id":"anon_44acfbc4dc899e6b","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_9c12fcfd87d642e1","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c0ffpme","thanks_reply_id":"c0ffqdq","post_score":0,"answer_score":1,"preferred_answer_is_top_level":true}}
{"user_id":"anon_a0b6cfebe84af3de","answerer_user_id":"anon_28a28c450df5cfd3","subreddit":"programming","timestamp":"2009-11-09T19:03:14+00:00","post_id":"a2kp2","question":"Advice: C, C++, or C# for someone learning from scratch? Where to start?\n\nI am a network administrator type, and I am really looking into moving into some programming for side projects. I have narrowed my candidates to the three derivatives of C, but I would like your advice on which would best suite someone starting from scratch. I am decent with HTML, PHP, and SQL. I understand basic programming concepts such as variables, functions, OOP, etc. I have done minor work in VB.net and it was.. well.. VB.\n\nI would also note that I would like to create win32 apps with UIs, not just console/command line based applications.\n\nThoughts on what to go with and where to start, oh great minds of reddit?\n\nThanks!","preferred_answer":"For just learning the basics of programming, I would recommend starting with C console applications because it forces you to look behind the scenes as to how a computer actually works. It isn't easy, but once you can code well in C, you can code well in most other languages.\n\nHowever, if you *really* want to do GUI apps, C++ and/or C# are the best choice, but I would go with the the former.","full_conversation":[{"role":"OP","user_id":"anon_a0b6cfebe84af3de","comment_id":"a2kp2","kind":"post","text":"Advice: C, C++, or C# for someone learning from scratch? Where to start?\n\nI am a network administrator type, and I am really looking into moving into some programming for side projects. I have narrowed my candidates to the three derivatives of C, but I would like your advice on which would best suite someone starting from scratch. I am decent with HTML, PHP, and SQL. I understand basic programming concepts such as variables, functions, OOP, etc. I have done minor work in VB.net and it was.. well.. VB.\n\nI would also note that I would like to create win32 apps with UIs, not just console/command line based applications.\n\nThoughts on what to go with and where to start, oh great minds of reddit?\n\nThanks!","timestamp":"2009-11-09T19:03:14+00:00","score":0},{"role":"answerer","user_id":"anon_28a28c450df5cfd3","comment_id":"c0fk1yh","kind":"comment","text":"For just learning the basics of programming, I would recommend starting with C console applications because it forces you to look behind the scenes as to how a computer actually works. It isn't easy, but once you can code well in C, you can code well in most other languages.\n\nHowever, if you *really* want to do GUI apps, C++ and/or C# are the best choice, but I would go with the the former.","timestamp":"2009-11-09T20:37:53+00:00","score":1},{"role":"OP","user_id":"anon_a0b6cfebe84af3de","comment_id":"c0fk3x6","kind":"comment","text":"Thanks for the info as well. It seems you and petelyons are in-line with the fact I should work on C before moving on to either C++ or C#.\n\nDo you happen to have any good starter resources for C? Thanks again.","timestamp":"2009-11-09T21:08:44+00:00","score":1},{"role":"answerer","user_id":"anon_28a28c450df5cfd3","comment_id":"c0fk668","kind":"comment","text":"Actually, the [wikibooks](http://en.wikibooks.org/wiki/C_Programming) on C is pretty helpful when you know the basics of most programming languages. It is a good reference for the discrepancies between C and other languages.","timestamp":"2009-11-09T21:43:47+00:00","score":2},{"role":"OP","user_id":"anon_a0b6cfebe84af3de","comment_id":"c0fkrnq","kind":"comment","text":"I have no idea why I was unaware of such a site existing. Thank you good sir.","timestamp":"2009-11-10T04:30:58+00:00","score":1}],"n_turns":5,"n_turns_after_thanks":2,"op_metadata":{"user_id":"anon_a0b6cfebe84af3de","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_28a28c450df5cfd3","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c0fk1yh","thanks_reply_id":"c0fk3x6","post_score":0,"answer_score":1,"preferred_answer_is_top_level":true}}
{"user_id":"anon_57b2e0863017d3a8","answerer_user_id":"anon_58344bb025bffbe2","subreddit":"programming","timestamp":"2009-11-11T05:11:10+00:00","post_id":"a34dr","question":"Dear Proggit: Nerd rage + new career path?\n\nAllow me to get this off my chest.\n\nI have a huge amount of nerd rage at my current job. The code base is a design-patterned-out-\"N-tier enterprise\"-spaghetti-cluster. The 3rd world slaves with no coding experience who have replaced the original development team to cut costs have no clue what they are doing. Progress has come to a complete standstill, and management have run out of artificial things to claim as progress. The pressure to perform miracles is absurd. While I am not a developer by title, I made the mistake of patching up some things outside of the core system, and now this is expected. I am now also being thrown in front of an obnoxious client so that my bosses can work from home for weeks at a time. In other words, the situation is *really* bad, I have become *really* cynical, and need to get out ASAP.\n\nGetting a new job is the biggest pain in the ass for me. No, I don't have a network (FUCK people, I have mild Aspergers and have a hard time connecting). No, I don't have 10 years .NET experience. No, I don't have pre-packaged answers to your stupid questions about my \"biggest challenges\" or \"greatest weakness\" (I have never *been* challenged, only assaulted with tedium). No, I don't want to work in your shitty corporate environment on your busted ass Windows machine reporting to your technology brain dead management.\n\nI am an incredibly talented programmer who has never been able to get a development job (I am currently an \"analyst\", which seems to be the dumping ground for people who thought they were cut out to be developers). The idea of finding a great job, or finding a not so great job (at a great company) and working my way up, is fading fast.\n\nI have never worked with anyone who impressed me. I surpassed the skill of my industry veteran coworkers within two months with no previous experience. I enjoy spending my *entire* weekend hacking on some code or learning complicated shit at all levels of abstraction. It's what I do. I love it. I will never stop, irrespective of whether someone is going to pay me to do it. If I won the lottery, I wouldn't find anything better to do with my time (after figuring out how to redistribute the money to good causes when I die).\n\nI am seriously considering looking for a mindless job like part time warehouse loading so that I can come home with a fresh mind to work on something meaningful to me. I have practically given up on pursuing a career in this field as my experience thus far has been terrible and my intuition is telling me that decent jobs are exceedingly rare. I would prefer low stress/salary to high stress/salary. What are your thoughts? \n\nedit +7hrs: thanks for the replies, just got up and need to head off to work in a moment.\n\nedit +19hrs: just got back from my wonderful job, wow that's a lot of responses.\n\nedit +20hrs: Thanks again. There are a plethora of good replies from different angles. I probably should have clarified a little better that I am really frustrated at the moment, but I don't think the world is out to get me. I am leaning towards quitting within the next week or so and picking up a mindless job while I figure out what I want to do long-term.","preferred_answer":"I have a low stress job in programming and it's the most amazing thing ever. I also work from home. \n\nThey're definitely out there. Suck it up and work on being a good interviewee. Yeah you have aspergers, just go in with confidence and try to sell yourself. Instead of being stubborn as most programmers are, admit you have a weakness and try to have someone help you with this because it's a valuable skill.\n\nAlso, don't feel the need to commit to a job for anyone's sake. I got a job that I hated once and just didn't show up on the 4th day. If you don't like what you're doing just stop asap. The worst that will happen probably isn't that bad.","full_conversation":[{"role":"OP","user_id":"anon_57b2e0863017d3a8","comment_id":"a34dr","kind":"post","text":"Dear Proggit: Nerd rage + new career path?\n\nAllow me to get this off my chest.\n\nI have a huge amount of nerd rage at my current job. The code base is a design-patterned-out-\"N-tier enterprise\"-spaghetti-cluster. The 3rd world slaves with no coding experience who have replaced the original development team to cut costs have no clue what they are doing. Progress has come to a complete standstill, and management have run out of artificial things to claim as progress. The pressure to perform miracles is absurd. While I am not a developer by title, I made the mistake of patching up some things outside of the core system, and now this is expected. I am now also being thrown in front of an obnoxious client so that my bosses can work from home for weeks at a time. In other words, the situation is *really* bad, I have become *really* cynical, and need to get out ASAP.\n\nGetting a new job is the biggest pain in the ass for me. No, I don't have a network (FUCK people, I have mild Aspergers and have a hard time connecting). No, I don't have 10 years .NET experience. No, I don't have pre-packaged answers to your stupid questions about my \"biggest challenges\" or \"greatest weakness\" (I have never *been* challenged, only assaulted with tedium). No, I don't want to work in your shitty corporate environment on your busted ass Windows machine reporting to your technology brain dead management.\n\nI am an incredibly talented programmer who has never been able to get a development job (I am currently an \"analyst\", which seems to be the dumping ground for people who thought they were cut out to be developers). The idea of finding a great job, or finding a not so great job (at a great company) and working my way up, is fading fast.\n\nI have never worked with anyone who impressed me. I surpassed the skill of my industry veteran coworkers within two months with no previous experience. I enjoy spending my *entire* weekend hacking on some code or learning complicated shit at all levels of abstraction. It's what I do. I love it. I will never stop, irrespective of whether someone is going to pay me to do it. If I won the lottery, I wouldn't find anything better to do with my time (after figuring out how to redistribute the money to good causes when I die).\n\nI am seriously considering looking for a mindless job like part time warehouse loading so that I can come home with a fresh mind to work on something meaningful to me. I have practically given up on pursuing a career in this field as my experience thus far has been terrible and my intuition is telling me that decent jobs are exceedingly rare. I would prefer low stress/salary to high stress/salary. What are your thoughts? \n\nedit +7hrs: thanks for the replies, just got up and need to head off to work in a moment.\n\nedit +19hrs: just got back from my wonderful job, wow that's a lot of responses.\n\nedit +20hrs: Thanks again. There are a plethora of good replies from different angles. I probably should have clarified a little better that I am really frustrated at the moment, but I don't think the world is out to get me. I am leaning towards quitting within the next week or so and picking up a mindless job while I figure out what I want to do long-term.","timestamp":"2009-11-11T05:11:10+00:00","score":12},{"role":"answerer","user_id":"anon_58344bb025bffbe2","comment_id":"c0fmm02","kind":"comment","text":"I have a low stress job in programming and it's the most amazing thing ever. I also work from home. \n\nThey're definitely out there. Suck it up and work on being a good interviewee. Yeah you have aspergers, just go in with confidence and try to sell yourself. Instead of being stubborn as most programmers are, admit you have a weakness and try to have someone help you with this because it's a valuable skill.\n\nAlso, don't feel the need to commit to a job for anyone's sake. I got a job that I hated once and just didn't show up on the 4th day. If you don't like what you're doing just stop asap. The worst that will happen probably isn't that bad.","timestamp":"2009-11-11T06:16:55+00:00","score":8},{"role":"OP","user_id":"anon_57b2e0863017d3a8","comment_id":"c0fo3nb","kind":"comment","text":"Thanks for the encouragement. I am at that edge where I am trying to figure out whether or not to put in my two week notice tomorrow and jump in to the unknown. It is scary, because finding a decent paying technology job is pretty hard for me, and I am not certain how I would adjust to a completely different type of job.","timestamp":"2009-11-12T01:16:47+00:00","score":1},{"role":"answerer","user_id":"anon_58344bb025bffbe2","comment_id":"c0folvy","kind":"comment","text":"If you live with your parents still and have at least 5,000$ I would definitely do it. \n\nI don't know what jobs are like in your area, but in mine employers are licking their chops to hire developers from 4 year schools with good social skills and motivation. \n\nAlso, many employers are glad to go home-grown these days. American employers will like this about you whether you know it or not. Some almost like it **too** much. You can really knock them out if they've been meeting with people who have indecipherable accents all day. It's just another asset to remember you have. Good luck.","timestamp":"2009-11-12T07:46:13+00:00","score":1}],"n_turns":4,"n_turns_after_thanks":1,"op_metadata":{"user_id":"anon_57b2e0863017d3a8","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_58344bb025bffbe2","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c0fmm02","thanks_reply_id":"c0fo3nb","post_score":12,"answer_score":8,"preferred_answer_is_top_level":true}}
{"user_id":"anon_3a59e3813127e7e5","answerer_user_id":"anon_1d24b1047f16a635","subreddit":"programming","timestamp":"2009-11-13T19:09:06+00:00","post_id":"a44gi","question":"We are required to use DOJO at this job and it has \r\nbeen ruining all my designs. It has been inserting \r\ninline styles like '...top:0; right:auto;...'. The dev \r\nclaims that these are not editable values. Is there \r\nan alternative toolkit that is better for design, and/\r\nor is this dev lying to me?","preferred_answer":"The 'inline styles' being added are likely part of the BorderContainer widget. It uses position/top/left styles (by modifying node.style.left/etc) to accomplish the complex layouts supported. If you wish to recreate BorderContainers style in pure CSS, simply don't use the BorderContainer. Problem solved. (You will need to do something similar if you were to be using jQuery anyway, so the amount of work would be the same)\n\nAlso, Dojo is not the same as Dijit, which is likely what you are using. \"Dojo\" doesn't put any styles inline for any reason. (nor does Dijit really, if they are appearing in your inspection it must be something firebug is doing to indicate the styles are set via JavaScript?) \n\nThe \"not editable\" comment probably stems from JavaScript styles overriding CSS values. Though the BorderContainer only handles top/left/position styles for it's immediate children. Your styling should be just fine if done properly (eg: if something sets a node to position:absolute (js) the cascaded styles for children that are position:relative will be changed.) It is fairly simple to do with good CSS.","full_conversation":[{"role":"OP","user_id":"anon_3a59e3813127e7e5","comment_id":"a44gi","kind":"post","text":"We are required to use DOJO at this job and it has \r\nbeen ruining all my designs. It has been inserting \r\ninline styles like '...top:0; right:auto;...'. The dev \r\nclaims that these are not editable values. Is there \r\nan alternative toolkit that is better for design, and/\r\nor is this dev lying to me?","timestamp":"2009-11-13T19:09:06+00:00","score":1},{"role":"answerer","user_id":"anon_1d24b1047f16a635","comment_id":"c0frc6e","kind":"comment","text":"The 'inline styles' being added are likely part of the BorderContainer widget. It uses position/top/left styles (by modifying node.style.left/etc) to accomplish the complex layouts supported. If you wish to recreate BorderContainers style in pure CSS, simply don't use the BorderContainer. Problem solved. (You will need to do something similar if you were to be using jQuery anyway, so the amount of work would be the same)\n\nAlso, Dojo is not the same as Dijit, which is likely what you are using. \"Dojo\" doesn't put any styles inline for any reason. (nor does Dijit really, if they are appearing in your inspection it must be something firebug is doing to indicate the styles are set via JavaScript?) \n\nThe \"not editable\" comment probably stems from JavaScript styles overriding CSS values. Though the BorderContainer only handles top/left/position styles for it's immediate children. Your styling should be just fine if done properly (eg: if something sets a node to position:absolute (js) the cascaded styles for children that are position:relative will be changed.) It is fairly simple to do with good CSS.","timestamp":"2009-11-13T21:44:28+00:00","score":11},{"role":"OP","user_id":"anon_3a59e3813127e7e5","comment_id":"c0frdlt","kind":"comment","text":"thank you.","timestamp":"2009-11-13T22:11:03+00:00","score":2},{"role":"answerer","user_id":"anon_1d24b1047f16a635","comment_id":"c0frhwd","kind":"comment","text":"np. Also worth pointing out reddit isn't necessarily the best place to get good support for Dojo. Hugely friendly and active community on #dojo (freenode) or dojo-interest mailing list. Questions there get noticed, and typically not trolled.","timestamp":"2009-11-13T23:36:58+00:00","score":3},{"role":"OP","user_id":"anon_3a59e3813127e7e5","comment_id":"c0frlrz","kind":"comment","text":"wasn't really looking for support per se, more to find out if the dev was a liar.","timestamp":"2009-11-14T01:02:30+00:00","score":1}],"n_turns":5,"n_turns_after_thanks":2,"op_metadata":{"user_id":"anon_3a59e3813127e7e5","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_1d24b1047f16a635","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c0frc6e","thanks_reply_id":"c0frdlt","post_score":1,"answer_score":11,"preferred_answer_is_top_level":true}}
{"user_id":"anon_a88cfd76ba9e54fd","answerer_user_id":"anon_8501526616911723","subreddit":"programming","timestamp":"2009-11-18T10:46:01+00:00","post_id":"a5lf7","question":"Ask Proggit: Has a masters degree in CS helped you in web development? How has it changed your career?\n\nI am considering to go for 2 year full time masters in CS and was wondering how it helps a person develop his skills. Are there any better courses that has CS subjects?","preferred_answer":"My undergrad is in Computer Information Systems and now I am pursuing a masters in Cognitive Engineering, I've had a few graduate classes in CS and have found them to be very theoretical.\n\nWhile it is fun to learn how machines learn and such knowledge can be useful for cutting edge applications, it not going to help you much with marketing your web design skills.\n\nI'd recommend you look into HCI, Human Factors, and Industrial Design. You probably know plenty about coding to make web pages but how much do you know about designing a usable interface?\n\nThe interface skills will make you stand out more in web design than coding will...","full_conversation":[{"role":"OP","user_id":"anon_a88cfd76ba9e54fd","comment_id":"a5lf7","kind":"post","text":"Ask Proggit: Has a masters degree in CS helped you in web development? How has it changed your career?\n\nI am considering to go for 2 year full time masters in CS and was wondering how it helps a person develop his skills. Are there any better courses that has CS subjects?","timestamp":"2009-11-18T10:46:01+00:00","score":0},{"role":"answerer","user_id":"anon_8501526616911723","comment_id":"c0fy983","kind":"comment","text":"My undergrad is in Computer Information Systems and now I am pursuing a masters in Cognitive Engineering, I've had a few graduate classes in CS and have found them to be very theoretical.\n\nWhile it is fun to learn how machines learn and such knowledge can be useful for cutting edge applications, it not going to help you much with marketing your web design skills.\n\nI'd recommend you look into HCI, Human Factors, and Industrial Design. You probably know plenty about coding to make web pages but how much do you know about designing a usable interface?\n\nThe interface skills will make you stand out more in web design than coding will...","timestamp":"2009-11-18T11:05:39+00:00","score":2},{"role":"OP","user_id":"anon_a88cfd76ba9e54fd","comment_id":"c0fy9iy","kind":"comment","text":"Thanks for your input! While usability and design is an integral part, I am more interested in the backend. Working on problems such as distributed computing, scaling, etc. While web development has its moments, I feel beyond a point it become just CRUD development.\n\nThe main reasoning behind me considering MS is that it can reboot my career and I could work on more interesting problems on a larger setup. \n\nThe point of view that is holding me back is all that is taught in best of colleges such as MIT is now online. One can learn from the same teachers at ones own pace.","timestamp":"2009-11-18T11:24:30+00:00","score":0},{"role":"answerer","user_id":"anon_8501526616911723","comment_id":"c0fypie","kind":"comment","text":"the online experience is no where near as enjoyable and effective as a graduate seminar - regardless good luck","timestamp":"2009-11-18T17:46:59+00:00","score":2}],"n_turns":4,"n_turns_after_thanks":1,"op_metadata":{"user_id":"anon_a88cfd76ba9e54fd","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_8501526616911723","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c0fy983","thanks_reply_id":"c0fy9iy","post_score":0,"answer_score":2,"preferred_answer_is_top_level":true}}
{"user_id":"anon_ff2985cc92fb0f10","answerer_user_id":"anon_9c12fcfd87d642e1","subreddit":"programming","timestamp":"2009-11-18T19:32:54+00:00","post_id":"a5rek","question":"Programming for dummies\n\nHey reddit. I'm bascially new to programming. I saw my computer teacher use it in class today and i'm very eager to learn it. Unfortunately, my teacher refuses to teach it to me. Any programmers can tell me what programming basically is and what do i do in order to get start?","preferred_answer":"Go to carlhprogramming subreddit. Do all lessons. Ask all doubts.","full_conversation":[{"role":"OP","user_id":"anon_ff2985cc92fb0f10","comment_id":"a5rek","kind":"post","text":"Programming for dummies\n\nHey reddit. I'm bascially new to programming. I saw my computer teacher use it in class today and i'm very eager to learn it. Unfortunately, my teacher refuses to teach it to me. Any programmers can tell me what programming basically is and what do i do in order to get start?","timestamp":"2009-11-18T19:32:54+00:00","score":0},{"role":"answerer","user_id":"anon_9c12fcfd87d642e1","comment_id":"c0fyx4y","kind":"comment","text":"Go to carlhprogramming subreddit. Do all lessons. Ask all doubts.","timestamp":"2009-11-18T19:37:55+00:00","score":2},{"role":"OP","user_id":"anon_ff2985cc92fb0f10","comment_id":"c0fyxbh","kind":"comment","text":"I see.\r\nThanks.","timestamp":"2009-11-18T19:40:55+00:00","score":-1},{"role":"answerer","user_id":"anon_9c12fcfd87d642e1","comment_id":"c0fyxmu","kind":"comment","text":"And I meant **ALL** doubts.","timestamp":"2009-11-18T19:45:31+00:00","score":1}],"n_turns":4,"n_turns_after_thanks":1,"op_metadata":{"user_id":"anon_ff2985cc92fb0f10","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_9c12fcfd87d642e1","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c0fyx4y","thanks_reply_id":"c0fyxbh","post_score":0,"answer_score":2,"preferred_answer_is_top_level":true}}
{"user_id":"anon_509eb835511b98b1","answerer_user_id":"anon_a58e58ae76a7d493","subreddit":"programming","timestamp":"2009-11-19T01:07:14+00:00","post_id":"a5usi","question":"Ask Proggit: Online Masters degrees (CS, IT, Management). Are they any good?\n\nI'm currently considering doing a Masters degree in CS or IT, but the local colleges that offer night classes in my area pretty much suck. I was wondering if any of you had any experience with online degrees. \n\nAre they any good (provided you dedicate them the appropriate time)?\n\nAny suggestions for good schools?\n\nWill a potential employer value a \"real\" (as in sitting in a classroom) degree more?\n\nI've looked on google, but all I seem to come up with are what look like referral sites, rather than any useful info.","preferred_answer":"I completed by MS in CS via distance ed back in 2008. No, I was not at a diploma mill, but a university. I went strictly for furthering my knowledge. \n\nWith that there are a lot of pros and cons in distance ed.\n\nThe biggest pro for me was having a flexible schedule. I work full time and travel a lot for work and play. I didn't have time to get down to a university and sit in a classroom.\n\nThe biggest con was asynchronous communication. Having to schedule a phone call during a prof's office hours or wait for an email response was painful especially when I would watch other students interact with the prof before and after each lecture. \n\nYou have to be HIGHLY self-motivated and disciplined to get your work completed and research on your own. Be prepared to struggle and concisely word your questions on web forms or emails. It's going to be tough. \n\nReputable distance education programs:\n\n* [Carnegie Mellon](http://www.cmu.edu/academics/distance-learning.shtml)\n* [DePaul University](http://www.cdm.depaul.edu/onlinelearning/Pages/OnlineLearning.aspx)\n* [Drexel University](http://www.drexel.com/)\n* [University of Maryland](http://www.umuc.edu/online_ed.shtml)\n* [Complete listing of online colleges](http://www.distance-education.org/Schools/)\n\nEdit: I want to add that the quality of the education (for me at least) was the EXACT same as physically sitting in the classroom. I had a multicast of the video/audio of the lecture, prof's computer screen, and white board. The downside is that you don't get to interact and ask questions, and you miss the group collaboration. If you are looking for this or don't do well working alone I would strongly discourage you from pursing an online degree. \n\nThat said, I did do some group projects. IM, video conferencing, version control, and email are your life lines.","full_conversation":[{"role":"OP","user_id":"anon_509eb835511b98b1","comment_id":"a5usi","kind":"post","text":"Ask Proggit: Online Masters degrees (CS, IT, Management). Are they any good?\n\nI'm currently considering doing a Masters degree in CS or IT, but the local colleges that offer night classes in my area pretty much suck. I was wondering if any of you had any experience with online degrees. \n\nAre they any good (provided you dedicate them the appropriate time)?\n\nAny suggestions for good schools?\n\nWill a potential employer value a \"real\" (as in sitting in a classroom) degree more?\n\nI've looked on google, but all I seem to come up with are what look like referral sites, rather than any useful info.","timestamp":"2009-11-19T01:07:14+00:00","score":7},{"role":"answerer","user_id":"anon_a58e58ae76a7d493","comment_id":"c0g0epl","kind":"comment","text":"I completed by MS in CS via distance ed back in 2008. No, I was not at a diploma mill, but a university. I went strictly for furthering my knowledge. \n\nWith that there are a lot of pros and cons in distance ed.\n\nThe biggest pro for me was having a flexible schedule. I work full time and travel a lot for work and play. I didn't have time to get down to a university and sit in a classroom.\n\nThe biggest con was asynchronous communication. Having to schedule a phone call during a prof's office hours or wait for an email response was painful especially when I would watch other students interact with the prof before and after each lecture. \n\nYou have to be HIGHLY self-motivated and disciplined to get your work completed and research on your own. Be prepared to struggle and concisely word your questions on web forms or emails. It's going to be tough. \n\nReputable distance education programs:\n\n* [Carnegie Mellon](http://www.cmu.edu/academics/distance-learning.shtml)\n* [DePaul University](http://www.cdm.depaul.edu/onlinelearning/Pages/OnlineLearning.aspx)\n* [Drexel University](http://www.drexel.com/)\n* [University of Maryland](http://www.umuc.edu/online_ed.shtml)\n* [Complete listing of online colleges](http://www.distance-education.org/Schools/)\n\nEdit: I want to add that the quality of the education (for me at least) was the EXACT same as physically sitting in the classroom. I had a multicast of the video/audio of the lecture, prof's computer screen, and white board. The downside is that you don't get to interact and ask questions, and you miss the group collaboration. If you are looking for this or don't do well working alone I would strongly discourage you from pursing an online degree. \n\nThat said, I did do some group projects. IM, video conferencing, version control, and email are your life lines.","timestamp":"2009-11-19T16:41:22+00:00","score":9},{"role":"OP","user_id":"anon_509eb835511b98b1","comment_id":"c0g1jzk","kind":"comment","text":"Hi,\n\nThanks for your answer! \n\nSome follow-up questions, if you dont mind: \n\nDo you feel the fact that it was online has put you at a disadvantage when looking for employment? \n\nDo employers, in your opinion, think less of an online degree? \n\nDo you tell them that it's online or do you simply have it on your resume as a normal masters?","timestamp":"2009-11-20T04:58:30+00:00","score":2},{"role":"answerer","user_id":"anon_a58e58ae76a7d493","comment_id":"c0g23wk","kind":"comment","text":"Online or not, it's the same educational requirements of those students that were physically located on-site at the university. As a result, I listed it as an MS in CS on my resume. Honestly, employers don't care whether or not its online - they DO care whether or not it came from a reputable institution. \n\nThere have been a few occasions when it's actually played to my advantage during job interviews. Specifically, when someone ask about project and time management. \n\nNot many folks can say they worked full-time and went to graduate school remotely while holding down a 3.5 gpa and progressing in their career (promotions). It says a lot about ones commitment, discipline, and dedication to setting goals and accomplishing them.\n\nGood luck with whatever decision you make.","timestamp":"2009-11-20T16:01:27+00:00","score":2}],"n_turns":4,"n_turns_after_thanks":1,"op_metadata":{"user_id":"anon_509eb835511b98b1","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_a58e58ae76a7d493","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c0g0epl","thanks_reply_id":"c0g1jzk","post_score":7,"answer_score":9,"preferred_answer_is_top_level":true}}
{"user_id":"anon_ffca269a691d75ea","answerer_user_id":"anon_0d6f520a27945b8d","subreddit":"programming","timestamp":"2009-11-19T06:17:47+00:00","post_id":"a5xjl","question":"Dear Programmers: How do you even begin making your own Linux System?\n\nI've always been into programming. I am an undergraduate double major in physics and astronomy. My father owns a web programming company and I know plenty of languages. I work part-time programming in IDL, MATLAB, JAVA, and C for NASA. However, the majority of my work up to this point has been on windows or mac. I am just starting to get into Linux in my classes and I fucking LOVE it. I'm really interested in making my own Linux, but I feel like I'm not fluent enough with Linux to be able to create my own. Does anyone have a good book in which I can learn to make my own Linux? I am completely in the dark on this subject so any help is greatly appreciated. I feel like a dick not knowing Linux this point in my life. Thanks in advance.\n\ntl;dr - I need to learn how to write my own Linux system.","preferred_answer":"So are you asking how to write your own POSIX-compliant Operating system, or just how to put together your own Linux distribution?","full_conversation":[{"role":"OP","user_id":"anon_ffca269a691d75ea","comment_id":"a5xjl","kind":"post","text":"Dear Programmers: How do you even begin making your own Linux System?\n\nI've always been into programming. I am an undergraduate double major in physics and astronomy. My father owns a web programming company and I know plenty of languages. I work part-time programming in IDL, MATLAB, JAVA, and C for NASA. However, the majority of my work up to this point has been on windows or mac. I am just starting to get into Linux in my classes and I fucking LOVE it. I'm really interested in making my own Linux, but I feel like I'm not fluent enough with Linux to be able to create my own. Does anyone have a good book in which I can learn to make my own Linux? I am completely in the dark on this subject so any help is greatly appreciated. I feel like a dick not knowing Linux this point in my life. Thanks in advance.\n\ntl;dr - I need to learn how to write my own Linux system.","timestamp":"2009-11-19T06:17:47+00:00","score":0},{"role":"answerer","user_id":"anon_0d6f520a27945b8d","comment_id":"c0fzv5u","kind":"comment","text":"So are you asking how to write your own POSIX-compliant Operating system, or just how to put together your own Linux distribution?","timestamp":"2009-11-19T06:22:17+00:00","score":2},{"role":"OP","user_id":"anon_ffca269a691d75ea","comment_id":"c0fzvhj","kind":"comment","text":"I would say put together my own Linux distribution system. Thanks for the reply.","timestamp":"2009-11-19T06:33:06+00:00","score":1},{"role":"answerer","user_id":"anon_0d6f520a27945b8d","comment_id":"c0fzvq2","kind":"comment","text":"http://www.linuxfromscratch.org/\n\nor maybe some of these results may be of assistance: http://www.google.com.au/search?q=build+your+own+linux+distribution","timestamp":"2009-11-19T06:40:29+00:00","score":2},{"role":"OP","user_id":"anon_ffca269a691d75ea","comment_id":"c0fzvxt","kind":"comment","text":"Maybe I'm just being ignorant, but I feel like most of the \"build you own linux\" sites are tailored for really experienced Linux users. After working with it for a year I know my way fairly well around Linux, but I don't have Linux on my computer so it is hard to gauge how much I *really* understand.","timestamp":"2009-11-19T06:47:21+00:00","score":1}],"n_turns":5,"n_turns_after_thanks":2,"op_metadata":{"user_id":"anon_ffca269a691d75ea","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_0d6f520a27945b8d","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c0fzv5u","thanks_reply_id":"c0fzvhj","post_score":0,"answer_score":2,"preferred_answer_is_top_level":true}}
{"user_id":"anon_0ec7379c800689c2","answerer_user_id":"anon_98222e27afcb151d","subreddit":"programming","timestamp":"2009-11-21T19:47:46+00:00","post_id":"a6t9b","question":"New to Prolog\n\nI'm trying to evaluate a few problems using Prolog, and I've impressed myself with how far I've gotten in a day (^_^), but I am having trouble deleting an element from a list. I have googled the problem and found a lot of broken code which has given me some ideas, but no solutions.\n\nDoes anyone know how to delete an element from a list, preferably without going into an endless loop?","preferred_answer":"remove(A,[],[]).\n\nremove(A,[A|B],B).\n\nremove(A,[C|B],[C|D]) :-\n remove( A, B, D ).\n\nIf you want to remove all instances of an element, replace second line with:\n\nremove(A,[A|B],D) :-\n remove( A, B, D ).\n\nIf you want to remove a numbered element, do (counting elements from zero):\n\nremove(N,[],[]).\n\nremove(0,[A|B],B).\n\nremove(N,[A|B],[A|D]) :-\n M is N-1,\n remove( M, B, D ).\n\nYou really should do your own homework.","full_conversation":[{"role":"OP","user_id":"anon_0ec7379c800689c2","comment_id":"a6t9b","kind":"post","text":"New to Prolog\n\nI'm trying to evaluate a few problems using Prolog, and I've impressed myself with how far I've gotten in a day (^_^), but I am having trouble deleting an element from a list. I have googled the problem and found a lot of broken code which has given me some ideas, but no solutions.\n\nDoes anyone know how to delete an element from a list, preferably without going into an endless loop?","timestamp":"2009-11-21T19:47:46+00:00","score":1},{"role":"answerer","user_id":"anon_98222e27afcb151d","comment_id":"c0g3wt8","kind":"comment","text":"remove(A,[],[]).\n\nremove(A,[A|B],B).\n\nremove(A,[C|B],[C|D]) :-\n remove( A, B, D ).\n\nIf you want to remove all instances of an element, replace second line with:\n\nremove(A,[A|B],D) :-\n remove( A, B, D ).\n\nIf you want to remove a numbered element, do (counting elements from zero):\n\nremove(N,[],[]).\n\nremove(0,[A|B],B).\n\nremove(N,[A|B],[A|D]) :-\n M is N-1,\n remove( M, B, D ).\n\nYou really should do your own homework.","timestamp":"2009-11-21T20:12:17+00:00","score":11},{"role":"OP","user_id":"anon_0ec7379c800689c2","comment_id":"c0g3wzb","kind":"comment","text":"Thanks. I appreciate the help, not really the criticism. I'm sure you needed a little help with something at least once in your lifetime.","timestamp":"2009-11-21T20:16:43+00:00","score":0},{"role":"answerer","user_id":"anon_98222e27afcb151d","comment_id":"c0g3xfo","kind":"comment","text":"yeah, we all need help from time to time, which is why I gave it to you. I also know that help should not be too easy, or too painless, since then people don't try for themselves.\n\nHonestly, it would have been better if you had asked your TA, since he could have walked you through the thought process and helped you understand the answer in a way that you would remember. Prolog is not like any other programming language that I have encountered, and while you can argue its usefulness, learning it is really about grokking it. Just getting the answer will not help you much.\n\nThere is a great saying that goes something like: \"I hear, I forget; I see, I understand; I do, I remember.\"","timestamp":"2009-11-21T20:29:16+00:00","score":9},{"role":"OP","user_id":"anon_0ec7379c800689c2","comment_id":"c0g3ysv","kind":"comment","text":"Well in that case I do appreciate it :) Thank you and I'm sorry. But I'm teaching myself the majority of this as my lecturer hasn't covered that much or even gone over most of the basics, and I've never done any programming like this language before.\n\nI'm getting there, and have a rule of never implementing anything I can't explain :)\n\nAlso, that quote is amazing. Thanks","timestamp":"2009-11-21T21:07:06+00:00","score":6}],"n_turns":5,"n_turns_after_thanks":2,"op_metadata":{"user_id":"anon_0ec7379c800689c2","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_98222e27afcb151d","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c0g3wt8","thanks_reply_id":"c0g3wzb","post_score":1,"answer_score":11,"preferred_answer_is_top_level":true}}
{"user_id":"anon_94bc9654f732df52","answerer_user_id":"anon_ffce1e0d86a41671","subreddit":"programming","timestamp":"2009-11-22T05:39:08+00:00","post_id":"a6wri","question":"Can you help me out, Proggit?\n\nHey all!\n\nI'm here to ask a question, and I think that you fine people here in proggit could help me. Basically, I want to begin programming games, and I have no idea where to start. I have experience with Java, but I hate it. Extremely bad. I know it's a good language to learn OOP, etc., but I can't stand it. I was wanting to know what languages/books/websites you all can recommend and point me at. I was looking at XNA, it seemed good, but again I'd like to know you're opinion.\n\nThanks a bundle everyone, I hope that I get a response or two.","preferred_answer":"XNA is pretty good, I've personally never read any physical books on game design but I have messed around with a fair share of engines. Unless you're planning to write the engine from scratch, learn one of the popular ones. The language itself...will usually be something like C++. You'll also want to check out some open-source games and what they do. You'll need to know a **lot** of math and a good share of physics as well.","full_conversation":[{"role":"OP","user_id":"anon_94bc9654f732df52","comment_id":"a6wri","kind":"post","text":"Can you help me out, Proggit?\n\nHey all!\n\nI'm here to ask a question, and I think that you fine people here in proggit could help me. Basically, I want to begin programming games, and I have no idea where to start. I have experience with Java, but I hate it. Extremely bad. I know it's a good language to learn OOP, etc., but I can't stand it. I was wanting to know what languages/books/websites you all can recommend and point me at. I was looking at XNA, it seemed good, but again I'd like to know you're opinion.\n\nThanks a bundle everyone, I hope that I get a response or two.","timestamp":"2009-11-22T05:39:08+00:00","score":0},{"role":"answerer","user_id":"anon_ffce1e0d86a41671","comment_id":"c0g4kqf","kind":"comment","text":"XNA is pretty good, I've personally never read any physical books on game design but I have messed around with a fair share of engines. Unless you're planning to write the engine from scratch, learn one of the popular ones. The language itself...will usually be something like C++. You'll also want to check out some open-source games and what they do. You'll need to know a **lot** of math and a good share of physics as well.","timestamp":"2009-11-22T06:16:33+00:00","score":2},{"role":"OP","user_id":"anon_94bc9654f732df52","comment_id":"c0g4kwi","kind":"comment","text":"Awesome, thanks for the response. I want to build off of the source engine, Havok, or another big engine. However, when I'm creating my game, will I have to import it, and just build *from* it, or edit it as I go?","timestamp":"2009-11-22T06:21:35+00:00","score":1},{"role":"answerer","user_id":"anon_ffce1e0d86a41671","comment_id":"c0g4lz7","kind":"comment","text":"You can choose to do it the way you want. But most commercial engines will make you build from their work. Take my word, do NOT use Source if you're still new to coding.","timestamp":"2009-11-22T06:51:45+00:00","score":1}],"n_turns":4,"n_turns_after_thanks":1,"op_metadata":{"user_id":"anon_94bc9654f732df52","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_ffce1e0d86a41671","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c0g4kqf","thanks_reply_id":"c0g4kwi","post_score":0,"answer_score":2,"preferred_answer_is_top_level":true}}
{"user_id":"anon_1b099fc40ba6f0ab","answerer_user_id":"anon_f5e74715352bd971","subreddit":"programming","timestamp":"2009-11-26T11:51:20+00:00","post_id":"a8dg5","question":"Ask Reddit: Would you go back to a low level C/C++ role after years in .NET/C# and Java?","preferred_answer":"This would actually be forward for me! I'm working in .Net at the moment but I do hope to end up writing c/c++","full_conversation":[{"role":"OP","user_id":"anon_1b099fc40ba6f0ab","comment_id":"a8dg5","kind":"post","text":"Ask Reddit: Would you go back to a low level C/C++ role after years in .NET/C# and Java?","timestamp":"2009-11-26T11:51:20+00:00","score":72},{"role":"answerer","user_id":"anon_f5e74715352bd971","comment_id":"c0gbicx","kind":"comment","text":"This would actually be forward for me! I'm working in .Net at the moment but I do hope to end up writing c/c++","timestamp":"2009-11-26T12:49:13+00:00","score":2},{"role":"OP","user_id":"anon_1b099fc40ba6f0ab","comment_id":"c0gbiud","kind":"comment","text":"that's an interesting point of view - thanks for pitching in","timestamp":"2009-11-26T13:12:09+00:00","score":1},{"role":"answerer","user_id":"anon_f5e74715352bd971","comment_id":"c0gbj0n","kind":"comment","text":"Ever since I decided I wanted to start programming (some 10 years ago or so) I wanted to learn C++, but one day at school I got the opportunity to get a couple of Microsoft .Net certificates (MCTS) and I grabbed it, because then atleast I'd know more then a tiny bit of VB.Net (which was all we were being taught at school).","timestamp":"2009-11-26T13:20:05+00:00","score":2}],"n_turns":4,"n_turns_after_thanks":1,"op_metadata":{"user_id":"anon_1b099fc40ba6f0ab","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_f5e74715352bd971","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c0gbicx","thanks_reply_id":"c0gbiud","post_score":72,"answer_score":2,"preferred_answer_is_top_level":true}}
{"user_id":"anon_013bb4e1d842f3e2","answerer_user_id":"anon_f96b845c1a33e6a4","subreddit":"programming","timestamp":"2009-11-27T23:15:27+00:00","post_id":"a8tfu","question":"Amazon Phone Interview for Software Developer \r\nPosition just got confirmed...any advice?\n\nHey people! Just landed myself a telephonic interview with Amazon for a Software Developer position (Description Follows). \r\n\r\nThis phone interview will be technical in nature and asks me to be prepared to do some coding. \r\n\r\nSoftware Development Engineer Job Description:\r\n\r\nHave a direct impact on the evolution of Amazon eCommerce platform and lead mission critical projects early in your career! At Amazon you will design, code, and contribute to solving some of the most complex technical challenges in the areas of Platform, Applications, Operations, Retail, Transaction Systems, and Merchants!\r\nSoftware Development Engineer: \r\n•\tStrong, object-oriented design and coding skills (C/C++ and/or Java preferably on a UNIX or Linux platform) \r\n•\tKnowledge of Perl or other scripting languages a plus\r\n•\tExperience with distributed (multi-tiered) systems, algorithms, and relational databases\r\n•\tExperience in optimization mathematics (linear programming, nonlinear optimization)\r\n•\tAbility to effectively articulate technical challenges and solutions\r\n•\tDeal well with ambiguous/undefined problems; ability to think abstractly\r\n•\tComputer Science/Computer Engineering degree (or related technical discipline)\r\n•\tPrevious technical internship preferred\r\n•\tGraduate degree a plus\r\n\r\nI am seeking advice on what questions to expect if anyone here might have been through this process before? Any other advice will also be appreciated.\r\n\r\nThanks!","preferred_answer":"The job description is generic. They post the same description at my University for undergraduate interns (yes, even the \"graduate degree a plus\" part). There are a lot of very different teams within Amazon, so you will not necessary touch on to every point listed.\n\nYou were told to be prepared to do some coding for this technical interview, and I suggest you follow this advice. Be prepared to talk code, and talk about your code.\n\nAs for the exact questions to expect -- one is supposed to sign an NDA against just that. I'm not sure how that works for a phone interview though... maybe they'll ask to email in a scan with a signature...","full_conversation":[{"role":"OP","user_id":"anon_013bb4e1d842f3e2","comment_id":"a8tfu","kind":"post","text":"Amazon Phone Interview for Software Developer \r\nPosition just got confirmed...any advice?\n\nHey people! Just landed myself a telephonic interview with Amazon for a Software Developer position (Description Follows). \r\n\r\nThis phone interview will be technical in nature and asks me to be prepared to do some coding. \r\n\r\nSoftware Development Engineer Job Description:\r\n\r\nHave a direct impact on the evolution of Amazon eCommerce platform and lead mission critical projects early in your career! At Amazon you will design, code, and contribute to solving some of the most complex technical challenges in the areas of Platform, Applications, Operations, Retail, Transaction Systems, and Merchants!\r\nSoftware Development Engineer: \r\n•\tStrong, object-oriented design and coding skills (C/C++ and/or Java preferably on a UNIX or Linux platform) \r\n•\tKnowledge of Perl or other scripting languages a plus\r\n•\tExperience with distributed (multi-tiered) systems, algorithms, and relational databases\r\n•\tExperience in optimization mathematics (linear programming, nonlinear optimization)\r\n•\tAbility to effectively articulate technical challenges and solutions\r\n•\tDeal well with ambiguous/undefined problems; ability to think abstractly\r\n•\tComputer Science/Computer Engineering degree (or related technical discipline)\r\n•\tPrevious technical internship preferred\r\n•\tGraduate degree a plus\r\n\r\nI am seeking advice on what questions to expect if anyone here might have been through this process before? Any other advice will also be appreciated.\r\n\r\nThanks!","timestamp":"2009-11-27T23:15:27+00:00","score":0},{"role":"answerer","user_id":"anon_f96b845c1a33e6a4","comment_id":"c0gdjlu","kind":"comment","text":"The job description is generic. They post the same description at my University for undergraduate interns (yes, even the \"graduate degree a plus\" part). There are a lot of very different teams within Amazon, so you will not necessary touch on to every point listed.\n\nYou were told to be prepared to do some coding for this technical interview, and I suggest you follow this advice. Be prepared to talk code, and talk about your code.\n\nAs for the exact questions to expect -- one is supposed to sign an NDA against just that. I'm not sure how that works for a phone interview though... maybe they'll ask to email in a scan with a signature...","timestamp":"2009-11-27T23:56:45+00:00","score":2},{"role":"OP","user_id":"anon_013bb4e1d842f3e2","comment_id":"c0gdkfl","kind":"comment","text":"Thanks...still looking out for any advice though...","timestamp":"2009-11-28T00:17:24+00:00","score":1},{"role":"answerer","user_id":"anon_f96b845c1a33e6a4","comment_id":"c0gdldl","kind":"comment","text":"You might find this useful -- http://maxnoy.com/interviews.html","timestamp":"2009-11-28T00:40:53+00:00","score":2},{"role":"OP","user_id":"anon_013bb4e1d842f3e2","comment_id":"c0gdqng","kind":"comment","text":"Thanks!","timestamp":"2009-11-28T03:02:53+00:00","score":1}],"n_turns":5,"n_turns_after_thanks":2,"op_metadata":{"user_id":"anon_013bb4e1d842f3e2","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_f96b845c1a33e6a4","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c0gdjlu","thanks_reply_id":"c0gdkfl","post_score":0,"answer_score":2,"preferred_answer_is_top_level":true}}
{"user_id":"anon_6c820ee3ed398e63","answerer_user_id":"anon_a0cfd5f1225854b3","subreddit":"programming","timestamp":"2009-11-27T23:20:46+00:00","post_id":"a8tgu","question":"I am trying to learn html/css by making an archaic table using html and my html book, but it's so archaic I can't find help on how to do it and the book doesnt show me. Can someone from reddit give me a hint?\n\nI am trying to make a calendar using tables in html. Yeah ok it's kind of retarded but I thought it would be fun to learn the basics. Anyway, The book says to: create a table body row group containing the days in the month of February. The row group should contain five rows and seven columns of table data cells. There are no spanning cells in any of the rows of columns.\" \"Each tale data cell should have the following content: The day of the month marked as an h3 heading\"","preferred_answer":"I think the key phrase is \"each table data cell\". Inside each TD, they want you to mark up the day of the month as an H3. Something like:\n\n
\n
22
\n \n
\n\nMake sense?","full_conversation":[{"role":"OP","user_id":"anon_6c820ee3ed398e63","comment_id":"a8tgu","kind":"post","text":"I am trying to learn html/css by making an archaic table using html and my html book, but it's so archaic I can't find help on how to do it and the book doesnt show me. Can someone from reddit give me a hint?\n\nI am trying to make a calendar using tables in html. Yeah ok it's kind of retarded but I thought it would be fun to learn the basics. Anyway, The book says to: create a table body row group containing the days in the month of February. The row group should contain five rows and seven columns of table data cells. There are no spanning cells in any of the rows of columns.\" \"Each tale data cell should have the following content: The day of the month marked as an h3 heading\"","timestamp":"2009-11-27T23:20:46+00:00","score":0},{"role":"answerer","user_id":"anon_a0cfd5f1225854b3","comment_id":"c0gdizb","kind":"comment","text":"I think the key phrase is \"each table data cell\". Inside each TD, they want you to mark up the day of the month as an H3. Something like:\n\n
\n
22
\n \n
\n\nMake sense?","timestamp":"2009-11-27T23:41:20+00:00","score":2},{"role":"OP","user_id":"anon_6c820ee3ed398e63","comment_id":"c0gdj6g","kind":"comment","text":"Yeah thanks, the next step they want me to put event information for each day, as a definition list
and the time/price of each event with a
. Do I really have to apply
to each day of the month if I have a stylesheet though? Or can't I apply it to the parent tag or something? That is what is irking me the most.","timestamp":"2009-11-27T23:46:42+00:00","score":1},{"role":"answerer","user_id":"anon_a0cfd5f1225854b3","comment_id":"c0gdjrz","kind":"comment","text":"HTML is for semantics (for example, *this* is a heading and *this* is a link and *this* is a definition), while stylesheets are for presentation (for example, if you want to make all of your heading bold and pink and 500 pixels high). So yah, you'll have to add the H3 to every table cell.\n\nIt's kind of a lame way to mark up a calendar, as you'll probably end up with a lot of empty days. But that's the exercise, so we do what we do.\n\nCopy and paste is your friend. Or choose a short month like February.","timestamp":"2009-11-28T00:00:42+00:00","score":2},{"role":"OP","user_id":"anon_6c820ee3ed398e63","comment_id":"c0gdkfr","kind":"comment","text":"Thank you!","timestamp":"2009-11-28T00:17:29+00:00","score":1}],"n_turns":5,"n_turns_after_thanks":2,"op_metadata":{"user_id":"anon_6c820ee3ed398e63","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_a0cfd5f1225854b3","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c0gdizb","thanks_reply_id":"c0gdj6g","post_score":0,"answer_score":2,"preferred_answer_is_top_level":true}}
{"user_id":"anon_6c820ee3ed398e63","answerer_user_id":"anon_61d623068810cad5","subreddit":"programming","timestamp":"2009-11-28T21:45:24+00:00","post_id":"a91jm","question":"How do I set the height of all the table rows within the table header row group to 5%, using CSS? This is what I have.\n\n\n
\n
Sun
\n\nthen in css:\n\ntable.calendar thead\n{\nheight=\"5%\";\n}\n\nbut I'm setting the height of the table header row group, I want to set the height of the actual table rows. How do I reference those in css? Thanks!","preferred_answer":"table.calendar thead th { height: 5%; }","full_conversation":[{"role":"OP","user_id":"anon_6c820ee3ed398e63","comment_id":"a91jm","kind":"post","text":"How do I set the height of all the table rows within the table header row group to 5%, using CSS? This is what I have.\n\n\n
\n
Sun
\n\nthen in css:\n\ntable.calendar thead\n{\nheight=\"5%\";\n}\n\nbut I'm setting the height of the table header row group, I want to set the height of the actual table rows. How do I reference those in css? Thanks!","timestamp":"2009-11-28T21:45:24+00:00","score":0},{"role":"answerer","user_id":"anon_61d623068810cad5","comment_id":"c0gep3c","kind":"comment","text":"table.calendar thead th { height: 5%; }","timestamp":"2009-11-28T21:58:36+00:00","score":1},{"role":"OP","user_id":"anon_6c820ee3ed398e63","comment_id":"c0geq1d","kind":"comment","text":"Thanks. My instructions say to \"Set the heigfht of the table row within the table header row group of the table to 5%. Set the height of the tabble rows within the tabble body row group to 19% each.\"\n\nI have\n\ntable.calendar thead th\n{\nheight=\"5%\";\n}\n\ntable.calendar tbody th\n{\nheight=\"50%\"\n}\n\nbut tbody doesn't have any th elements --\n\n
\n
26
\n
27
\n\n\n-so shouldnt it be thead tr and tbody tr? For some reason it doesn't format it well at all when I do that though.","timestamp":"2009-11-28T22:21:54+00:00","score":0},{"role":"answerer","user_id":"anon_61d623068810cad5","comment_id":"c0gerqj","kind":"comment","text":"TH and TD are essentially the same element; they behave same way in all respects, except that TH is meant as the 'header' of a row or column of TD data cells. THEAD will typically contain only TH elements (but doesn't have to) while TBODY and TFOOT might contain both TH and TD elements.\n\nYou have to apply your style to both TD and TH elements separately:\n\ntable.calendar tbody th, table.calendar tbody td { height: 19%; }","timestamp":"2009-11-28T23:01:02+00:00","score":1},{"role":"OP","user_id":"anon_6c820ee3ed398e63","comment_id":"c0gflpe","kind":"comment","text":"thanks!!!","timestamp":"2009-11-29T15:28:57+00:00","score":1}],"n_turns":5,"n_turns_after_thanks":2,"op_metadata":{"user_id":"anon_6c820ee3ed398e63","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_61d623068810cad5","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c0gep3c","thanks_reply_id":"c0geq1d","post_score":0,"answer_score":1,"preferred_answer_is_top_level":true}}
{"user_id":"anon_cce49169fa4c4e3b","answerer_user_id":"anon_c7cef9ef13fb7f1d","subreddit":"programming","timestamp":"2009-11-29T03:43:46+00:00","post_id":"a93lu","question":"Researching FPGAs, I came across this Arduino-like platform. Anyone used it?","preferred_answer":"What do you mean when you say Arduino-like? The schematics for many boards are free on the internet along with examples, so I'm not sure what you consider more Arduino-like about the board compared to, say, Xilinx's ML50x set of boards.\n\nXilinx produces a set of schematics for break-out-style boards, and many 3rd party boards are just implementations. Digilent's OpenSparc evaluation board, for example, is the same board as the other Xilinx ML50x boards (the ML50x boards differ by which FPGA they use). Xilinx also posts the bill of materials and PCB's gerber files if you want to create the board yourself. Here they are for the ML507\n\nhttp://www.xilinx.com/products/boards/ml507/docs.htm\n\nI'm using the ML50x boards as examples, but this is true for every Xilinx break-out-style board I've seen.\n\nThere was a topic on which FPGA boards were best for a home brew project a few months back that went over a lot of similar boards:\n\nhttp://www.reddit.com/r/programming/comments/a11gi/i_want_to_buy_an_fpga_dev_board_to_help_prototype/","full_conversation":[{"role":"OP","user_id":"anon_cce49169fa4c4e3b","comment_id":"a93lu","kind":"post","text":"Researching FPGAs, I came across this Arduino-like platform. Anyone used it?","timestamp":"2009-11-29T03:43:46+00:00","score":27},{"role":"answerer","user_id":"anon_c7cef9ef13fb7f1d","comment_id":"c0gfhsj","kind":"comment","text":"What do you mean when you say Arduino-like? The schematics for many boards are free on the internet along with examples, so I'm not sure what you consider more Arduino-like about the board compared to, say, Xilinx's ML50x set of boards.\n\nXilinx produces a set of schematics for break-out-style boards, and many 3rd party boards are just implementations. Digilent's OpenSparc evaluation board, for example, is the same board as the other Xilinx ML50x boards (the ML50x boards differ by which FPGA they use). Xilinx also posts the bill of materials and PCB's gerber files if you want to create the board yourself. Here they are for the ML507\n\nhttp://www.xilinx.com/products/boards/ml507/docs.htm\n\nI'm using the ML50x boards as examples, but this is true for every Xilinx break-out-style board I've seen.\n\nThere was a topic on which FPGA boards were best for a home brew project a few months back that went over a lot of similar boards:\n\nhttp://www.reddit.com/r/programming/comments/a11gi/i_want_to_buy_an_fpga_dev_board_to_help_prototype/","timestamp":"2009-11-29T12:20:13+00:00","score":5},{"role":"OP","user_id":"anon_cce49169fa4c4e3b","comment_id":"c0gfoj2","kind":"comment","text":"Thanks, there sure do seem to be a lot of options out there. It's a bit daunting when you don't know exactly what your requirements will be. (For example, with a lack of experience, I have no idea how many gates I'll need to do what I want.. I'm planning for a DSP application.) I'm thinking the best course is to just buy a really cheap solution to start, and see how far that gets me..","timestamp":"2009-11-29T17:01:53+00:00","score":1},{"role":"answerer","user_id":"anon_c7cef9ef13fb7f1d","comment_id":"c0gfy0b","kind":"comment","text":"Yes, it can be quite daunting, especially if you don't have an application in mind and just want a general board. The one I would recommend is the spartan 3 board from Digilent\n\nhttp://www.digilentinc.com/Products/Detail.cfm?NavPath=2,400,799&Prod=S3BOARD\n\nThe bottom of the web-page has a lot of cores for using the connectors on the board, and the board is used by a lot of people, so it is easy to search for a solution to any problem.\n\nI'd ask yourself, \"What do I want to do?\" If you want to learn, I'd suggest the S3Board and curriculum from a university course on digital design, like 6.111 from MIT's ocw. The FPGA labs are a great intro to digital design. If you want something specific, like a real-time audio analyzer or want to create a soft-core processor, then you can trim down based on the offerings based on your needs and choose the cheapest board.\n\nAlso, if you are affiliated with a university or school, you can usually get boards donated for free. Just something to consider.\n\nhttp://www.xilinx.com/univ/","timestamp":"2009-11-29T20:45:13+00:00","score":1},{"role":"OP","user_id":"anon_cce49169fa4c4e3b","comment_id":"c0gg8sm","kind":"comment","text":"Wow, thanks for all that info. I certainly didn't know about the donation program, I'll make sure to mention it at school, maybe that's the best way to get started.","timestamp":"2009-11-30T00:30:24+00:00","score":1},{"role":"answerer","user_id":"anon_c7cef9ef13fb7f1d","comment_id":"c0gge4r","kind":"comment","text":"Xilinx has been very generous with their donations. We (my research group) have received both discrete FPGAs and development boards for research and classes at the university I'm at.\n\nFor a simple DSP application, the spartan-3 would probably suffice. A more complex design would probably require a Virtex-4 or a Virtex-5. The ML506 is the current-generation, example board from Xilinx for DSP applications, as it uses a Virtex-5 with more DSP-specific slices than on their other example boards. You could implement the DSP portion of your design in the general section of any FPGA, rather than the specific portions of the Virtex-5 -- it depends on want you want to learn and do.\n\nI've heard that Altera has the same type of donation program, but haven't worked with the Altera hardware or software.\n\nYou might want to consider a micro-controller that targets DSP applications. AD has the BlackFin and SHARC processors, and TI has a few processors that I'm not familiar with. AD and TI have university donation programs, too, so you could probably get example boards from them.","timestamp":"2009-11-30T02:23:06+00:00","score":1}],"n_turns":6,"n_turns_after_thanks":3,"op_metadata":{"user_id":"anon_cce49169fa4c4e3b","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_c7cef9ef13fb7f1d","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c0gfhsj","thanks_reply_id":"c0gfoj2","post_score":27,"answer_score":5,"preferred_answer_is_top_level":true}}
{"user_id":"anon_e294854d153a2fbf","answerer_user_id":"anon_114fd0a51a202f4c","subreddit":"programming","timestamp":"2009-11-30T23:48:38+00:00","post_id":"a9nql","question":"Is learning VBA for excel etc. worthwhile for data analysis?\n\nHey Reddit, I need some advice. I'm about to graduate and head to grad school to get a PhD in computational toxicology. I've always had a passing interest in programming, took a couple java classes etc. and as I will be doing a good bit of data analysis/data mining I was wondering if learning VBA would be worthwhile or if there are other languages that would give me more bang for my buck? \n\nSide Note: Most of my work will probably be done in excel.","preferred_answer":"I worked in VB variants for years, and made a living as an Access developer for quite a while.\n\nYou are far better off learning a real language with an upward progression. If you're doing real math, [possibly R](http://www.r-project.org/). If you know Java, there are good-looking reporting tools available (Birt?). Note, I'm not saying these are right--I haven't used them (data analysis is practically non-existent in what I do) but there are good options available that don't lock you into VB*.\n\nOne of the troubles is that learning VB* will only really help you learn VB variants. It doesn't really translate to other languages--it's a dead end. If you learn something like Python, OTOH, you have something you can extend and use on any platform in much larger contexts (eg, Python is essentially the language of Google.) I'll leave it to people more familiar with data analysis to recommend a route--I'm just saying Excel isn't a good one.\n\nAnother is that Excel isn't really suited for serious data analysis; it's an Office program (yeah, yeah; people can do some clever things and make it handle big data sets . . . but they're *clever* things. Not by-design things.)","full_conversation":[{"role":"OP","user_id":"anon_e294854d153a2fbf","comment_id":"a9nql","kind":"post","text":"Is learning VBA for excel etc. worthwhile for data analysis?\n\nHey Reddit, I need some advice. I'm about to graduate and head to grad school to get a PhD in computational toxicology. I've always had a passing interest in programming, took a couple java classes etc. and as I will be doing a good bit of data analysis/data mining I was wondering if learning VBA would be worthwhile or if there are other languages that would give me more bang for my buck? \n\nSide Note: Most of my work will probably be done in excel.","timestamp":"2009-11-30T23:48:38+00:00","score":0},{"role":"answerer","user_id":"anon_114fd0a51a202f4c","comment_id":"c0ginih","kind":"comment","text":"I worked in VB variants for years, and made a living as an Access developer for quite a while.\n\nYou are far better off learning a real language with an upward progression. If you're doing real math, [possibly R](http://www.r-project.org/). If you know Java, there are good-looking reporting tools available (Birt?). Note, I'm not saying these are right--I haven't used them (data analysis is practically non-existent in what I do) but there are good options available that don't lock you into VB*.\n\nOne of the troubles is that learning VB* will only really help you learn VB variants. It doesn't really translate to other languages--it's a dead end. If you learn something like Python, OTOH, you have something you can extend and use on any platform in much larger contexts (eg, Python is essentially the language of Google.) I'll leave it to people more familiar with data analysis to recommend a route--I'm just saying Excel isn't a good one.\n\nAnother is that Excel isn't really suited for serious data analysis; it's an Office program (yeah, yeah; people can do some clever things and make it handle big data sets . . . but they're *clever* things. Not by-design things.)","timestamp":"2009-12-01T06:49:26+00:00","score":3},{"role":"OP","user_id":"anon_e294854d153a2fbf","comment_id":"c0gk3s8","kind":"comment","text":"thanks so much, I'll definitely be looking into R. And I know excel isn't suited for data analysis, however in the internship I worked at last semester, a lot of work was done in excel as pretty much everyone has it, so your boss, your coworker, anyone can grab what you're working on and do whatever with it. I figured while I will probably move away from excel, it never hurts to have that as a nice backup","timestamp":"2009-12-02T01:39:31+00:00","score":2},{"role":"answerer","user_id":"anon_114fd0a51a202f4c","comment_id":"c0gk92n","kind":"comment","text":"In theory it sounds good; in practice, the various Office object models let you down. One regular problem is that the frameworks change somewhat every version--and not always in a backward-compatible manner (I have had to modify code that ran fine for years, and choked the interpreter after an upgrade.) Unless you stick to the most basic commands, there's a fair chance that older versions won't run your code--plus a chance that newer ones won't.\n\nIf you want to be able to distribute code, your best bet is either a compileable application, or one that runs in an interpreter designed for portability (eg, Java.) VB* isn't even really compatible with other VB*s . .. and VB.NET? They never heard of it...\n\nI also expect (bolstered by the fact that you took Java) that you will eventually want to *do* something with the data. If you eventually decide to make an application (/viewer/modeler/...) you will have done yourself a favour if you've learned something like python (which is extremely numerically capable) or the like.\n\nI got good at VB*, years ago (starting with Access 1). It has been the single most crippling thing for me, as far as picking up serious programming.","timestamp":"2009-12-02T03:14:42+00:00","score":2},{"role":"OP","user_id":"anon_e294854d153a2fbf","comment_id":"c0gkhv8","kind":"comment","text":"once again, thanks so much for the great advice. I think I'll really look into Python/R/Java. You are right in that I probably will want to so something, as well as making applications to suit my needs. Would you suggest python or java, or another language, as my base to start going from. I'm not daunted by eventually \"dabbling\" in multiple languages, especially if they have similar syntax","timestamp":"2009-12-02T06:01:26+00:00","score":2},{"role":"answerer","user_id":"anon_114fd0a51a202f4c","comment_id":"c0gl1ko","kind":"comment","text":"I've done more Java (read: hardly any) than Python (read: practically none) or R (none), so my opinions on each wouldn't by useful.\n\nIf you're not daunted, then I would encourage you to dabble in each. Try to find out the relative strengths of each and use the best match for the specific code you're working on. If you can replace other peoples' holy wars with a 'best tool for the job' approach, you can have a long and fruitful, *happy* programming career.\n\nSome simple decision points are: do you want the app to run in a browser as an applet/do you want to compile it as a native app; dynamic typing can let you bang out code very fast/static-typing may be more helpful on a larger application. The trick is to find the languages domain (R's domain is math/analysis/reporting) and use the languages to their best advantage; the day you find yourself digging data out of old reports, write yourself some perl . . .","timestamp":"2009-12-02T16:00:16+00:00","score":2}],"n_turns":6,"n_turns_after_thanks":3,"op_metadata":{"user_id":"anon_e294854d153a2fbf","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_114fd0a51a202f4c","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c0ginih","thanks_reply_id":"c0gk3s8","post_score":0,"answer_score":3,"preferred_answer_is_top_level":true}}
{"user_id":"anon_cc245b81f2bf24ea","answerer_user_id":"anon_65669f867b9c55b4","subreddit":"programming","timestamp":"2009-12-01T19:47:37+00:00","post_id":"a9zj4","question":"AskProggit: Sorting complexity proofs?\n\nif you have a list of objects and a function that says true of false to check if two are equal it takes O(n^2) to simplify the list so that nothing is in there twice.. but if you (also) have an ordering (so the function says Less, GreaterOrEqual) you can make the complexity O(nlogn).\n\nIt makes some sense, the ordering gives you more information per comparison but can that argument about 'information-flow' actually be used to prove this and/or other things?","preferred_answer":"[next time try google](http://en.wikipedia.org/wiki/Sorting_algorithm)","full_conversation":[{"role":"OP","user_id":"anon_cc245b81f2bf24ea","comment_id":"a9zj4","kind":"post","text":"AskProggit: Sorting complexity proofs?\n\nif you have a list of objects and a function that says true of false to check if two are equal it takes O(n^2) to simplify the list so that nothing is in there twice.. but if you (also) have an ordering (so the function says Less, GreaterOrEqual) you can make the complexity O(nlogn).\n\nIt makes some sense, the ordering gives you more information per comparison but can that argument about 'information-flow' actually be used to prove this and/or other things?","timestamp":"2009-12-01T19:47:37+00:00","score":0},{"role":"answerer","user_id":"anon_65669f867b9c55b4","comment_id":"c0gjgt1","kind":"comment","text":"[next time try google](http://en.wikipedia.org/wiki/Sorting_algorithm)","timestamp":"2009-12-01T19:50:42+00:00","score":-4},{"role":"OP","user_id":"anon_cc245b81f2bf24ea","comment_id":"c0gjh70","kind":"comment","text":"> next time try google\n\nThanks that's really helpful I've never heard of google or sorting algorithms before.","timestamp":"2009-12-01T19:55:56+00:00","score":3},{"role":"answerer","user_id":"anon_65669f867b9c55b4","comment_id":"c0gjhbu","kind":"comment","text":"Well then stop asking us to do your hw and figure it out.","timestamp":"2009-12-01T19:57:56+00:00","score":-2},{"role":"OP","user_id":"anon_cc245b81f2bf24ea","comment_id":"c0gjhgi","kind":"comment","text":"> Well then stop asking us to do your hw and figure it out.\n\nIt's not my hw and I'm not asking you to \"figure it out\", there's not even a set problem here how can you possibly be serious. I think you must just be some kind of joker that repeats all the cliches (google it, rtfm, do your own homework, etc.). None of this improves any discussion.","timestamp":"2009-12-01T19:59:51+00:00","score":1},{"role":"answerer","user_id":"anon_65669f867b9c55b4","comment_id":"c0gji44","kind":"comment","text":"Hmm... probably not. Check my profile.","timestamp":"2009-12-01T20:09:27+00:00","score":-2}],"n_turns":6,"n_turns_after_thanks":3,"op_metadata":{"user_id":"anon_cc245b81f2bf24ea","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_65669f867b9c55b4","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c0gjgt1","thanks_reply_id":"c0gjh70","post_score":0,"answer_score":-4,"preferred_answer_is_top_level":true}}
{"user_id":"anon_aa2752682f44a22e","answerer_user_id":"anon_3491a595680eff07","subreddit":"programming","timestamp":"2009-12-02T21:37:50+00:00","post_id":"aafbk","question":"Going to start programming a game in XNA -- any tips?\n\nA friend and I are going to create some community games. We have a C# book, some basic programming knowledge in Java and VB(I know, full of lawlz). \n \nWe are doing this as a learning experience, and for fun. \nDoes Proggit have some suggestions for us? \n \nEDIT: Any other languages to learn?","preferred_answer":"I've been playing in XNA on and off for a year or so now and can say that I have been very surprised at how approachable the API is.\n\nHere are a few thoughts (complete with asides): \nIf you plan to jump into 3D with XNA your first area of focus should probably be picking your 3D modeling platform and getting comfortable with the interface. I ended up sticking with Mod Tool Pro. I have an older version of 3DS Max at my disposal, and I was much more comfortable with Blender - but each of the other packages required too much hackery with export file formats to get the models into XNA. So Mod Tool it was.\n\nOnce I committed to Mod Tool I started with a series of tutorials:\nThis series did the job nicely:\n\nhttp://www.youtube.com/watch?v=1LBnMMqro0M&feature=related\n\n(BTW: I firmly believe that there is no such thing as a standardized interface in the 3D modeling world and it's totally frustrating. I always feel like I am are starting from scratch every time I pick up a new tool.)\n\nOnce your comfortable with modeling, skinning, rigging, and integrating with XNA, it's time to build your first 3D app!\n\nI ran through the tutorial that has you build out a fixed turret and shoot down flying saucers:\nhttp://creators.xna.com/en-US/education/gettingstarted/bg3d/chapter1\nIt's fantastic in that it covers all of the basics... initializing the screen, input, sounds, loading models, and dealing with all of your basic 3D concerns (translation, transforms, etc). And its very short - you can knock it out in a few hours.\n\nNext up for me was tackling skinning and animation: for that I turned to the Guitar Matey Tutorial:\n\nhttp://blogs.msdn.com/dawate/archive/2008/02/05/building-a-3d-game-in-xna-from-scratch-free-video-tutorial-series-now-available.aspx\n\nThat's as far as I have gotten. \n\nAside from that just know your target platform. There are rules around distributing games to the PC community under the Games for Windows banner that make XNA a bit of a drag, and if your looking to build an XBox 360 game you have some pretty draconian limitations around file size.\n\nGood luck!","full_conversation":[{"role":"OP","user_id":"anon_aa2752682f44a22e","comment_id":"aafbk","kind":"post","text":"Going to start programming a game in XNA -- any tips?\n\nA friend and I are going to create some community games. We have a C# book, some basic programming knowledge in Java and VB(I know, full of lawlz). \n \nWe are doing this as a learning experience, and for fun. \nDoes Proggit have some suggestions for us? \n \nEDIT: Any other languages to learn?","timestamp":"2009-12-02T21:37:50+00:00","score":8},{"role":"answerer","user_id":"anon_3491a595680eff07","comment_id":"c0gm2sg","kind":"comment","text":"I've been playing in XNA on and off for a year or so now and can say that I have been very surprised at how approachable the API is.\n\nHere are a few thoughts (complete with asides): \nIf you plan to jump into 3D with XNA your first area of focus should probably be picking your 3D modeling platform and getting comfortable with the interface. I ended up sticking with Mod Tool Pro. I have an older version of 3DS Max at my disposal, and I was much more comfortable with Blender - but each of the other packages required too much hackery with export file formats to get the models into XNA. So Mod Tool it was.\n\nOnce I committed to Mod Tool I started with a series of tutorials:\nThis series did the job nicely:\n\nhttp://www.youtube.com/watch?v=1LBnMMqro0M&feature=related\n\n(BTW: I firmly believe that there is no such thing as a standardized interface in the 3D modeling world and it's totally frustrating. I always feel like I am are starting from scratch every time I pick up a new tool.)\n\nOnce your comfortable with modeling, skinning, rigging, and integrating with XNA, it's time to build your first 3D app!\n\nI ran through the tutorial that has you build out a fixed turret and shoot down flying saucers:\nhttp://creators.xna.com/en-US/education/gettingstarted/bg3d/chapter1\nIt's fantastic in that it covers all of the basics... initializing the screen, input, sounds, loading models, and dealing with all of your basic 3D concerns (translation, transforms, etc). And its very short - you can knock it out in a few hours.\n\nNext up for me was tackling skinning and animation: for that I turned to the Guitar Matey Tutorial:\n\nhttp://blogs.msdn.com/dawate/archive/2008/02/05/building-a-3d-game-in-xna-from-scratch-free-video-tutorial-series-now-available.aspx\n\nThat's as far as I have gotten. \n\nAside from that just know your target platform. There are rules around distributing games to the PC community under the Games for Windows banner that make XNA a bit of a drag, and if your looking to build an XBox 360 game you have some pretty draconian limitations around file size.\n\nGood luck!","timestamp":"2009-12-03T01:21:27+00:00","score":10},{"role":"OP","user_id":"anon_aa2752682f44a22e","comment_id":"c0go391","kind":"comment","text":"Thank you so much! Saved and copied. I'll probably start with 2D but when I make the jump I will come back to this! Any experience with Blender?","timestamp":"2009-12-04T03:22:07+00:00","score":1},{"role":"answerer","user_id":"anon_3491a595680eff07","comment_id":"c0gs076","kind":"comment","text":"Blender was the first modeler I tried to integrate with XNA - I really wanted it to work, but the .x model formats still didn't export seamlessly from the beginning. Other people have taken a crack at writing .x exporters for Blender but the last time I looked they each still had issues.\nYou can take a peak at one of the open source exporters here:\nhttp://directpython.sourceforge.net/exportx.html\n\nGiven that your going to be learning so much about the workflow, and data types in the beginning I would suggest that you first start with Mod Tool (it will only cost you an email address with your basic creator's club membership). :) There are some benefit's to introducing yourself to the platform using Mod Tool:\nMany of the 3D XNA tutorials you find out there will assume that you are using Mod Tool and are written with that in mind. You also have a very active community on the Mod Tool site and XNA forums that you can turn to when you have questions. And because Mod Tool is so tightly linked to XNA - it's usually the first modeler to be updated when there is a change to the XNA platform.\n\nThat said, don't give up up on eventually using Blender as your primary modeler if that's what you are comfortable with. Just realize that you will probably have to do your initial work in Blender then export to an intermediate format (.3DS is always a good one to try first) and re-import into Mod Tool before publishing to your XNA project.","timestamp":"2009-12-06T13:49:12+00:00","score":1}],"n_turns":4,"n_turns_after_thanks":1,"op_metadata":{"user_id":"anon_aa2752682f44a22e","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_3491a595680eff07","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c0gm2sg","thanks_reply_id":"c0go391","post_score":8,"answer_score":10,"preferred_answer_is_top_level":true}}
{"user_id":"anon_5df1008403daaef6","answerer_user_id":"anon_d62d4c42674d30cc","subreddit":"programming","timestamp":"2009-12-05T19:34:13+00:00","post_id":"abh76","question":"What string type should I use for a C++ project?\n\nI'm toying with writing a cross-platform interpreter for a little scripting language in C++. I'd like to keep it as simple and lightweight as possible, and I want to keep the door open for using this on limited memory devices (think game consoles), so I want close control over heap usage.\n\nOne design decision that has to be made early is what it uses for strings. My options are:\n\n**1. Use C-style `char*`**\n\nPros:\n\n* Simple.\n* Everyone understands it.\n* stdlib is easy to use.\n* Apparent about what it's doing with memory.\n\nCons:\n\n* Tedious to use.\n* Have to check for overflow everywhere.\n\n**2. Use `std::string`**\n\nPros:\n\n* Works more like a native type than char* (==, +=, etc.)\n* Lots of features.\n* Well tested.\n\nCons:\n\n* Complex.\n* Basic stuff seems harder than it should be (formatting?).\n* Brings in more std than I may want to depend on.\n* Does magical stuff on the heap without my knowledge (unless I provide my own allocator).\n* Have to import `std` or fully-qualify it everywhere. (Fully-qualified names entirely defeat the point of namespaces to me. It may as well be std_string, std_cout, etc. at that point.)\n\n**3. Write my own string class**\n\nPros:\n\n* Get to control the semantics and memory usage.\n* Can make it work the way I want.\n\nCons:\n\n* Reinventing the wheel.\n* May make interoperability (getting strings in and out of my lib) harder.\n* Will take a while to get it right and flush the bugs out.\n\nGiven those, I'm curious if anyone has any other thoughts or ideas before I pick one. (Also, please don't tell me to use C instead of C++. For purposes of this discussion, let's presume Zeus himself told me he will strike me down with a bolt of lightning if I don't use C++.)\n\nThoughts?","preferred_answer":"// frequently_used_std.h\n using std::cout;\n using std::cin;\n using std::endl;\n ...\n\n\n // All other files\n #include \"frequently_used_std.h\"","full_conversation":[{"role":"OP","user_id":"anon_5df1008403daaef6","comment_id":"abh76","kind":"post","text":"What string type should I use for a C++ project?\n\nI'm toying with writing a cross-platform interpreter for a little scripting language in C++. I'd like to keep it as simple and lightweight as possible, and I want to keep the door open for using this on limited memory devices (think game consoles), so I want close control over heap usage.\n\nOne design decision that has to be made early is what it uses for strings. My options are:\n\n**1. Use C-style `char*`**\n\nPros:\n\n* Simple.\n* Everyone understands it.\n* stdlib is easy to use.\n* Apparent about what it's doing with memory.\n\nCons:\n\n* Tedious to use.\n* Have to check for overflow everywhere.\n\n**2. Use `std::string`**\n\nPros:\n\n* Works more like a native type than char* (==, +=, etc.)\n* Lots of features.\n* Well tested.\n\nCons:\n\n* Complex.\n* Basic stuff seems harder than it should be (formatting?).\n* Brings in more std than I may want to depend on.\n* Does magical stuff on the heap without my knowledge (unless I provide my own allocator).\n* Have to import `std` or fully-qualify it everywhere. (Fully-qualified names entirely defeat the point of namespaces to me. It may as well be std_string, std_cout, etc. at that point.)\n\n**3. Write my own string class**\n\nPros:\n\n* Get to control the semantics and memory usage.\n* Can make it work the way I want.\n\nCons:\n\n* Reinventing the wheel.\n* May make interoperability (getting strings in and out of my lib) harder.\n* Will take a while to get it right and flush the bugs out.\n\nGiven those, I'm curious if anyone has any other thoughts or ideas before I pick one. (Also, please don't tell me to use C instead of C++. For purposes of this discussion, let's presume Zeus himself told me he will strike me down with a bolt of lightning if I don't use C++.)\n\nThoughts?","timestamp":"2009-12-05T19:34:13+00:00","score":4},{"role":"answerer","user_id":"anon_d62d4c42674d30cc","comment_id":"c0grrp8","kind":"comment","text":"// frequently_used_std.h\n using std::cout;\n using std::cin;\n using std::endl;\n ...\n\n\n // All other files\n #include \"frequently_used_std.h\"","timestamp":"2009-12-06T07:42:59+00:00","score":13},{"role":"OP","user_id":"anon_5df1008403daaef6","comment_id":"c0gs1dc","kind":"comment","text":"You know, that's a simple solution and a really good idea. Thanks!","timestamp":"2009-12-06T14:35:44+00:00","score":4},{"role":"answerer","user_id":"anon_d62d4c42674d30cc","comment_id":"c0gs6hj","kind":"comment","text":"Really, having seen you argue about having to list std::xxx in many thread never realize to use #include or #define. And think too much about what string class to use when you can just do\r\n\r\n typedef mystring std::string;\r\n\r\nAnd use mystring in all places, and change class only if there turns out to be problem after that. All this makes me think you haven't used C++ enough to have to think about this performace problem yet. You have to learn to program first. Don't get stuck on planning to be enterprisey.","timestamp":"2009-12-06T17:14:02+00:00","score":3},{"role":"OP","user_id":"anon_5df1008403daaef6","comment_id":"c0gspbr","kind":"comment","text":"> Really, having seen you argue about having to list std::xxx in many thread never realize to use #include or #define.\n\nAt work, we don't import entire namespaces, and most of the C++ coding standards I read explicitly forbit importing std in a header, and some even in a .cpp.\n\n> typedef mystring std::string;\n\nThat's what I'm doing right now.\n\n> You have to learn to program first.\n\nHave you ever done any C++ programming outside of a PC? After you ship a DS game, which has 4MB of memory total (including all of your art and sound), and must run without crashing for several days, memory fragmentation becomes a very real concern.\n\n> Don't get stuck on planning to be enterprisey.\n\nIf I was trying to be enterprisey, I'd be using a managed language. What I'm trying to do is write it in suck a way that I wouldn't shy away from using it on a game console.","timestamp":"2009-12-06T23:32:03+00:00","score":2}],"n_turns":5,"n_turns_after_thanks":2,"op_metadata":{"user_id":"anon_5df1008403daaef6","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_d62d4c42674d30cc","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c0grrp8","thanks_reply_id":"c0gs1dc","post_score":4,"answer_score":13,"preferred_answer_is_top_level":false}}
{"user_id":"anon_20e70ad6a6b27960","answerer_user_id":"anon_b83288917ee5d027","subreddit":"programming","timestamp":"2009-12-09T02:27:40+00:00","post_id":"aclsk","question":"Ask Proggit: Does anybody know of a language with semantics like this?\n\nI was reading through the first chapter of a programming book when I came to the part about assignment.\n\n x <- 4\n y <- 3*x\n\nAt this point, x is 4 and y is 12. Then on the next line, the value of x changes.\n\n x <- 5\n\nNow x is 5 and y is still 12. Is there any language that would see y as 15?","preferred_answer":"It's like a spreadsheet but without the visual grid layout. You can replace the value of any cell/variable, and when you do, the value of anything else which depends on it is updated automatically. (By updated, this could be eager or lazy)","full_conversation":[{"role":"OP","user_id":"anon_20e70ad6a6b27960","comment_id":"aclsk","kind":"post","text":"Ask Proggit: Does anybody know of a language with semantics like this?\n\nI was reading through the first chapter of a programming book when I came to the part about assignment.\n\n x <- 4\n y <- 3*x\n\nAt this point, x is 4 and y is 12. Then on the next line, the value of x changes.\n\n x <- 5\n\nNow x is 5 and y is still 12. Is there any language that would see y as 15?","timestamp":"2009-12-09T02:27:40+00:00","score":5},{"role":"answerer","user_id":"anon_b83288917ee5d027","comment_id":"c0gwz2i","kind":"comment","text":"It's like a spreadsheet but without the visual grid layout. You can replace the value of any cell/variable, and when you do, the value of anything else which depends on it is updated automatically. (By updated, this could be eager or lazy)","timestamp":"2009-12-09T02:33:25+00:00","score":5},{"role":"OP","user_id":"anon_20e70ad6a6b27960","comment_id":"c0gwz7p","kind":"comment","text":"Thank you! I would have never thought of that. Is there a word for the \"spreadsheet paradigm?\"\n\nAlso, is there such a thing as a gridless spreadsheet?","timestamp":"2009-12-09T02:35:53+00:00","score":3},{"role":"answerer","user_id":"anon_b83288917ee5d027","comment_id":"c0gwzwi","kind":"comment","text":"Most spreadsheets would be considered non-recursive reactive functional languages. I'm considering just the cell expressions here; not any scripting language that may accompany them. \n\nWhat you're thinking of might be found in [reactive programming](http://en.wikipedia.org/wiki/Reactive_programming)","timestamp":"2009-12-09T02:47:32+00:00","score":7}],"n_turns":4,"n_turns_after_thanks":1,"op_metadata":{"user_id":"anon_20e70ad6a6b27960","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_b83288917ee5d027","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c0gwz2i","thanks_reply_id":"c0gwz7p","post_score":5,"answer_score":5,"preferred_answer_is_top_level":true}}
{"user_id":"anon_b451632613602122","answerer_user_id":"anon_849fefa3013da38e","subreddit":"programming","timestamp":"2009-12-10T01:38:34+00:00","post_id":"aczvm","question":"What should I learn with? Flex or haXe?\n\nI want to start making flash applications, including facebook applications using flash. I have no money for CS4 or flex builder.\n\nI've looked into my options somewhat and found both flex sdk+actionscript or haXe as options. Am I better off with flex/actionscript, or haXe? Or are there any other options I should consider?","preferred_answer":">Flex Builder is just a flavored Eclipse.\n\nOr you could also just use straight Eclipse with the Flex Builder plugin. Performance is way better IMO. I'm contracting for Adobe at the moment and everyone here prefers it to the Flex Builder IDE.","full_conversation":[{"role":"OP","user_id":"anon_b451632613602122","comment_id":"aczvm","kind":"post","text":"What should I learn with? Flex or haXe?\n\nI want to start making flash applications, including facebook applications using flash. I have no money for CS4 or flex builder.\n\nI've looked into my options somewhat and found both flex sdk+actionscript or haXe as options. Am I better off with flex/actionscript, or haXe? Or are there any other options I should consider?","timestamp":"2009-12-10T01:38:34+00:00","score":0},{"role":"answerer","user_id":"anon_849fefa3013da38e","comment_id":"c0gywve","kind":"comment","text":">Flex Builder is just a flavored Eclipse.\n\nOr you could also just use straight Eclipse with the Flex Builder plugin. Performance is way better IMO. I'm contracting for Adobe at the moment and everyone here prefers it to the Flex Builder IDE.","timestamp":"2009-12-10T02:31:22+00:00","score":4},{"role":"OP","user_id":"anon_b451632613602122","comment_id":"c0gz72e","kind":"comment","text":"I was planning on using FlashDevelop, but I will look into the Eclipse option, thanks.","timestamp":"2009-12-10T05:49:22+00:00","score":1},{"role":"answerer","user_id":"anon_849fefa3013da38e","comment_id":"c0gz7o4","kind":"comment","text":"If you have the latest version of Eclipse check out the [Flash Builder 4 Plugin](http://labs.adobe.com/wiki/index.php/Flash_Builder_4:Release_Notes#Installing_Flash_Builder_plug-in). Has a lot of great new features for Flex.","timestamp":"2009-12-10T06:03:41+00:00","score":1}],"n_turns":4,"n_turns_after_thanks":1,"op_metadata":{"user_id":"anon_b451632613602122","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_849fefa3013da38e","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c0gywve","thanks_reply_id":"c0gz72e","post_score":0,"answer_score":4,"preferred_answer_is_top_level":false}}
{"user_id":"anon_6c820ee3ed398e63","answerer_user_id":"anon_40977600e8fac10c","subreddit":"programming","timestamp":"2009-12-11T02:21:32+00:00","post_id":"adeod","question":"Java question - Is there a better way to make this sentinel while loop exit after I put in the sentinel value, but still perform my conversion?\n\nimport java.util.Scanner;\n\n\npublic class TempConverter {\n\t/**\n\t * @param args \n\t */\n\tstatic Scanner console = new Scanner(System.in);\n\tstatic final double FTOC = 5.0 / 9.0;\n\tstatic final int OFFSET = 40;\n\tstatic final int SENTINEL = -40;\n\t\n\t\n\tpublic static void main(String[] args) {\n\t\t// TODO Auto-generated method stub\n\t\t\n\t\tdouble degreesF, degreesC;\n\t\tSystem.out.println(\"Enter temperature in degrees Fahrenheit to convert to celsius (enter -40 to quit): \");\n\t\tdegreesF = console.nextDouble();\n\t\tdegreesC = ((degreesF + OFFSET) * FTOC) - OFFSET;\n\t\tSystem.out.printf(degreesF + \" degrees Fahrenheit is equal to %.2f %n\", degreesC);\n\t\twhile(degreesF != SENTINEL)\n\t\t{\n\t\t\tSystem.out.println(\"Enter next temperature to convert or enter -40 to quit: \");\n\t\t\tdegreesF = console.nextDouble();\n\t\t\tdegreesC = ((degreesF + OFFSET) * FTOC) - OFFSET;\n\t\t\tSystem.out.printf(degreesF + \" degrees Fahrenheit is equal to %.2f %n\", degreesC);\n\t\t}\n\t}\n }","preferred_answer":"well....for starters...initialize degreesF to zero. and delete the 4 lines outside the loop.","full_conversation":[{"role":"OP","user_id":"anon_6c820ee3ed398e63","comment_id":"adeod","kind":"post","text":"Java question - Is there a better way to make this sentinel while loop exit after I put in the sentinel value, but still perform my conversion?\n\nimport java.util.Scanner;\n\n\npublic class TempConverter {\n\t/**\n\t * @param args \n\t */\n\tstatic Scanner console = new Scanner(System.in);\n\tstatic final double FTOC = 5.0 / 9.0;\n\tstatic final int OFFSET = 40;\n\tstatic final int SENTINEL = -40;\n\t\n\t\n\tpublic static void main(String[] args) {\n\t\t// TODO Auto-generated method stub\n\t\t\n\t\tdouble degreesF, degreesC;\n\t\tSystem.out.println(\"Enter temperature in degrees Fahrenheit to convert to celsius (enter -40 to quit): \");\n\t\tdegreesF = console.nextDouble();\n\t\tdegreesC = ((degreesF + OFFSET) * FTOC) - OFFSET;\n\t\tSystem.out.printf(degreesF + \" degrees Fahrenheit is equal to %.2f %n\", degreesC);\n\t\twhile(degreesF != SENTINEL)\n\t\t{\n\t\t\tSystem.out.println(\"Enter next temperature to convert or enter -40 to quit: \");\n\t\t\tdegreesF = console.nextDouble();\n\t\t\tdegreesC = ((degreesF + OFFSET) * FTOC) - OFFSET;\n\t\t\tSystem.out.printf(degreesF + \" degrees Fahrenheit is equal to %.2f %n\", degreesC);\n\t\t}\n\t}\n }","timestamp":"2009-12-11T02:21:32+00:00","score":0},{"role":"answerer","user_id":"anon_40977600e8fac10c","comment_id":"c0h0top","kind":"comment","text":"well....for starters...initialize degreesF to zero. and delete the 4 lines outside the loop.","timestamp":"2009-12-11T02:43:06+00:00","score":2},{"role":"OP","user_id":"anon_6c820ee3ed398e63","comment_id":"c0h0tv6","kind":"comment","text":"oh haha thank you. ok now how do I add \"degrees Celsius\" after degreesC in printf?\n\nnm this worked\n\n System.out.printf(degreesF + \" degrees Fahrenheit is equal to %.2f degrees Celsius. %n\", degreesC);","timestamp":"2009-12-11T02:45:50+00:00","score":1},{"role":"answerer","user_id":"anon_40977600e8fac10c","comment_id":"c0h0u62","kind":"comment","text":"printf...i can't actually remember a time where I actually used that...anywho try println\n\n System.out.println(\"text here\"+ variable here +\"more text\" + another variable);\n\nedit:gah brain not working so well after finishing my last project anywho, never a fan of the printf style of printing and preferred DecimalFormat.format(string)\n\n System.out.println((new DecimalFormat(\"###.##\")).format(22.2372));","timestamp":"2009-12-11T02:50:47+00:00","score":0},{"role":"OP","user_id":"anon_6c820ee3ed398e63","comment_id":"c0h0v69","kind":"comment","text":"why is that better? Do you just wrap the (new Dec....format..) in the text you want?","timestamp":"2009-12-11T03:07:36+00:00","score":1},{"role":"answerer","user_id":"anon_40977600e8fac10c","comment_id":"c0h157u","kind":"comment","text":"Not entirely sure using DecimalFormat is any better or worse then printf, I just consider it more readable. Also,what I did there is really only good for a single use, something like this would be a better for reuse.\n\n DecimalFormat d = new DecimalFormat(###.##); <- look up in the java api to get more formats\n System.out.prinln(d.format(decOne)+ \" \"+ d.format(decTwo));","timestamp":"2009-12-11T06:11:27+00:00","score":1}],"n_turns":6,"n_turns_after_thanks":3,"op_metadata":{"user_id":"anon_6c820ee3ed398e63","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_40977600e8fac10c","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c0h0top","thanks_reply_id":"c0h0tv6","post_score":0,"answer_score":2,"preferred_answer_is_top_level":true}}
{"user_id":"anon_d6b67355837ad44c","answerer_user_id":"anon_4951f195a1537a8d","subreddit":"programming","timestamp":"2009-12-11T04:36:31+00:00","post_id":"adfww","question":"Reddit, I have very little programming experience but I have a really fun and simple idea. Would you please help me?\n\nI have an image that has various expressions listed with blank boxes above them. I'd like a way to select the expression, take a picture with a webcam or upload a photo then place the photo in the box. Eventually the user would save the image.\n\nAny help would be greatly appreciated.","preferred_answer":"Your down votes make no sense. That is incredibly retarded. I think reddit needs to force justification of downvotes when posts are new.\n\nAnyhow... the way I would go about doing it.\nUse html5 canvas to just render whatever the user has entered in an input box.\n\nSo in javascript it would just something like $('something').onChange(function if(textExists){removeText} text.Draw(xPosition, yPosition, size))\nAnd you can do the same thing with any number of graphics.\n\nthen do http://www.nihilogic.dk/labs/canvas2image/ or similar to just turn it into an image\n\nif you already have the expression text for the below the box hardcoded i gues you would skip that thing about the input box. You could just have a user select a bunch of images, line them up with html5, and export the image from the canvas stage whenever your done","full_conversation":[{"role":"OP","user_id":"anon_d6b67355837ad44c","comment_id":"adfww","kind":"post","text":"Reddit, I have very little programming experience but I have a really fun and simple idea. Would you please help me?\n\nI have an image that has various expressions listed with blank boxes above them. I'd like a way to select the expression, take a picture with a webcam or upload a photo then place the photo in the box. Eventually the user would save the image.\n\nAny help would be greatly appreciated.","timestamp":"2009-12-11T04:36:31+00:00","score":0},{"role":"answerer","user_id":"anon_4951f195a1537a8d","comment_id":"c0h1qq7","kind":"comment","text":"Your down votes make no sense. That is incredibly retarded. I think reddit needs to force justification of downvotes when posts are new.\n\nAnyhow... the way I would go about doing it.\nUse html5 canvas to just render whatever the user has entered in an input box.\n\nSo in javascript it would just something like $('something').onChange(function if(textExists){removeText} text.Draw(xPosition, yPosition, size))\nAnd you can do the same thing with any number of graphics.\n\nthen do http://www.nihilogic.dk/labs/canvas2image/ or similar to just turn it into an image\n\nif you already have the expression text for the below the box hardcoded i gues you would skip that thing about the input box. You could just have a user select a bunch of images, line them up with html5, and export the image from the canvas stage whenever your done","timestamp":"2009-12-11T16:24:09+00:00","score":1},{"role":"OP","user_id":"anon_d6b67355837ad44c","comment_id":"c0h2512","kind":"comment","text":"Thanks for your input. I'm totally confused, but will look into this and see if over time I can put it to use. I appreciate it.","timestamp":"2009-12-11T19:52:56+00:00","score":1},{"role":"answerer","user_id":"anon_4951f195a1537a8d","comment_id":"c0h2ap9","kind":"comment","text":"* Add iecanvas.js so things work in IE\n* Add a Canvas element to your page as big as the picture you want\n* Add text to your canvas element in javascript by specifying the location it should sit at and using html5 canvas commands\n* draw any boxes or shapes you need with html5 canvas commands\n* have a file input field for people to upload their pics that drops it directly in the canvas. To be tricky you can make it default to the first available square. This part will have lots of options if im understanding you so it cant be simplified more\n* Then do the canvas to image thing that my previous link talks about, itll work in firefox, and in chrome at least people can copy the image and save it in irfanview or similar","timestamp":"2009-12-11T21:16:43+00:00","score":1}],"n_turns":4,"n_turns_after_thanks":1,"op_metadata":{"user_id":"anon_d6b67355837ad44c","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_4951f195a1537a8d","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c0h1qq7","thanks_reply_id":"c0h2512","post_score":0,"answer_score":1,"preferred_answer_is_top_level":false}}
{"user_id":"anon_8fd85cfc2c3bd024","answerer_user_id":"anon_0111e42141a3e66a","subreddit":"programming","timestamp":"2009-12-11T22:11:36+00:00","post_id":"adqqj","question":"JavaFX or Adobe Flash / Air?\n\nI'm looking to create my next application. I want it to work on multiple platforms and screen sizes. It appers to me that Adobe and JavaFX are pitching their platforms as multi OS and can/will run on mobile devices. Which do you think is the best bet?","preferred_answer":"I built a Media Player using JavaFX. I felt it was immature. Certain APIs don't work correctly, and display differently if you're running in as a plain application, as an applet, or as a JNLP. The node based architecture is pretty cool, and I enjoyed it to an extent, but there's an extent to which you don't understand what you're doing because it's a totally different programming style from what most are used to. Additionally, the lack of a mature layout manager really pissed me off and forced me to use a plethora of position bindings, which slowed down resizing of my application way too much.\n\n\n\nThe one thing I DID like about JavaFX is the fact that you can still use many Java classes with lesser degree of verbosity, which is unbelievably useful.\n\n\n\nFlash:\nFlash definitely has a greater marketshare, but Flash is not free, and neither is Flex unless you're unemployed or a student. I don't have much experience, but the ability to do animations in Flash easily is definitely a plus. \n\n\n\nI don't know much about Flash, but I know that it definitely takes less time for an embedded Flash object to load than a Java applet. I believe it also can be distributed as an executable if you're using AIR, as opposed to JavaFX which requires a command line argument like \"javafx -jar mediabox.jar\" (unless you use JNLP which has almost the same access rights as an applet).\n\n\n\nSilverlight might be something you'd like to look into. You have the base of a huge framework, with nice upcoming features. Unfortunately, you'd be relying on Mono for Linux support, which might deter you. XAML is a bit difficult to use for styling. Moreso than Flash. C# is really great, however, it's a complex language, and can be confusing if you're not used to it.\n\n\n\nGood luck!","full_conversation":[{"role":"OP","user_id":"anon_8fd85cfc2c3bd024","comment_id":"adqqj","kind":"post","text":"JavaFX or Adobe Flash / Air?\n\nI'm looking to create my next application. I want it to work on multiple platforms and screen sizes. It appers to me that Adobe and JavaFX are pitching their platforms as multi OS and can/will run on mobile devices. Which do you think is the best bet?","timestamp":"2009-12-11T22:11:36+00:00","score":1},{"role":"answerer","user_id":"anon_0111e42141a3e66a","comment_id":"c0h2t71","kind":"comment","text":"I built a Media Player using JavaFX. I felt it was immature. Certain APIs don't work correctly, and display differently if you're running in as a plain application, as an applet, or as a JNLP. The node based architecture is pretty cool, and I enjoyed it to an extent, but there's an extent to which you don't understand what you're doing because it's a totally different programming style from what most are used to. Additionally, the lack of a mature layout manager really pissed me off and forced me to use a plethora of position bindings, which slowed down resizing of my application way too much.\n\n\n\nThe one thing I DID like about JavaFX is the fact that you can still use many Java classes with lesser degree of verbosity, which is unbelievably useful.\n\n\n\nFlash:\nFlash definitely has a greater marketshare, but Flash is not free, and neither is Flex unless you're unemployed or a student. I don't have much experience, but the ability to do animations in Flash easily is definitely a plus. \n\n\n\nI don't know much about Flash, but I know that it definitely takes less time for an embedded Flash object to load than a Java applet. I believe it also can be distributed as an executable if you're using AIR, as opposed to JavaFX which requires a command line argument like \"javafx -jar mediabox.jar\" (unless you use JNLP which has almost the same access rights as an applet).\n\n\n\nSilverlight might be something you'd like to look into. You have the base of a huge framework, with nice upcoming features. Unfortunately, you'd be relying on Mono for Linux support, which might deter you. XAML is a bit difficult to use for styling. Moreso than Flash. C# is really great, however, it's a complex language, and can be confusing if you're not used to it.\n\n\n\nGood luck!","timestamp":"2009-12-12T03:08:24+00:00","score":2},{"role":"OP","user_id":"anon_8fd85cfc2c3bd024","comment_id":"c0h2tt5","kind":"comment","text":"I really appreciate the feed back. Adobe is opening up [flash/flex](http://www.openscreenproject.org/) for next year, so that won't be a problem.","timestamp":"2009-12-12T03:23:27+00:00","score":1},{"role":"answerer","user_id":"anon_0111e42141a3e66a","comment_id":"c0h2vma","kind":"comment","text":"Right, but just Flex. Not Flash CS5, of course. But still, you might not even need something like that.\n\nAnd no problemo!","timestamp":"2009-12-12T04:06:51+00:00","score":1}],"n_turns":4,"n_turns_after_thanks":1,"op_metadata":{"user_id":"anon_8fd85cfc2c3bd024","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_0111e42141a3e66a","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c0h2t71","thanks_reply_id":"c0h2tt5","post_score":1,"answer_score":2,"preferred_answer_is_top_level":true}}
{"user_id":"anon_96af86e17553ef2f","answerer_user_id":"anon_54b7cadf6ac43381","subreddit":"programming","timestamp":"2009-12-13T00:46:19+00:00","post_id":"ae1uo","question":"I'm looking for the name of a concept or algorithm that I'm trying to implement. Can anyone help?\n\nI'm trying to write a program that is identical in concept to a \"choose your own adventure\" story (but with a very different application). At any point in time, there will be a set of available decisions about what to do next. So, the 'story' has a tree structure to it.\n\nThe problem I have is that which choices you are presented with at any point should depend on which path you took to get to that point. Otherwise there will be logical problems with the 'storyline.' I could characterize each node in the tree by its content _and_ set of allowed decisions, but in this application that would lead to a large amount of redundant content.\n\nI'm having trouble figuring out myself a good way to do this, and I am even having a hard time searching for it-- Googling \"programming story tree\" etc. isn't much help. Is there a name for this sort of application, in particular ways to deal with the problem I specified? Any help is appreciated, thank you!","preferred_answer":"It's important to clearly phrase the question because that's a good deal of the answer, but yeah, you have the correct idea. I'll rephrase again:\n\n- you have a story which is your old school \"choose your own adventure\" style decision tree\n- you have a state map which is essentially a bag of bits\n- any action taken in your tree (i.e. node hop) can have a side effect of setting the value for one (or more) bit(s) in your state map\n- any node in your tree can be conditionally hidden from the player if one (or more) bit(s) is set in your state map.\n- playing the game is walking the tree in rule #1 given the rules #2, #3 and #4.","full_conversation":[{"role":"OP","user_id":"anon_96af86e17553ef2f","comment_id":"ae1uo","kind":"post","text":"I'm looking for the name of a concept or algorithm that I'm trying to implement. Can anyone help?\n\nI'm trying to write a program that is identical in concept to a \"choose your own adventure\" story (but with a very different application). At any point in time, there will be a set of available decisions about what to do next. So, the 'story' has a tree structure to it.\n\nThe problem I have is that which choices you are presented with at any point should depend on which path you took to get to that point. Otherwise there will be logical problems with the 'storyline.' I could characterize each node in the tree by its content _and_ set of allowed decisions, but in this application that would lead to a large amount of redundant content.\n\nI'm having trouble figuring out myself a good way to do this, and I am even having a hard time searching for it-- Googling \"programming story tree\" etc. isn't much help. Is there a name for this sort of application, in particular ways to deal with the problem I specified? Any help is appreciated, thank you!","timestamp":"2009-12-13T00:46:19+00:00","score":6},{"role":"answerer","user_id":"anon_54b7cadf6ac43381","comment_id":"c0h43ev","kind":"comment","text":"It's important to clearly phrase the question because that's a good deal of the answer, but yeah, you have the correct idea. I'll rephrase again:\n\n- you have a story which is your old school \"choose your own adventure\" style decision tree\n- you have a state map which is essentially a bag of bits\n- any action taken in your tree (i.e. node hop) can have a side effect of setting the value for one (or more) bit(s) in your state map\n- any node in your tree can be conditionally hidden from the player if one (or more) bit(s) is set in your state map.\n- playing the game is walking the tree in rule #1 given the rules #2, #3 and #4.","timestamp":"2009-12-13T01:54:59+00:00","score":9},{"role":"OP","user_id":"anon_96af86e17553ef2f","comment_id":"c0h43mi","kind":"comment","text":"Thank you!","timestamp":"2009-12-13T01:59:51+00:00","score":2},{"role":"answerer","user_id":"anon_54b7cadf6ac43381","comment_id":"c0h43tm","kind":"comment","text":"np","timestamp":"2009-12-13T02:05:08+00:00","score":2}],"n_turns":4,"n_turns_after_thanks":1,"op_metadata":{"user_id":"anon_96af86e17553ef2f","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_54b7cadf6ac43381","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c0h43ev","thanks_reply_id":"c0h43mi","post_score":6,"answer_score":9,"preferred_answer_is_top_level":false}}
{"user_id":"anon_f6dcf8396a5418a5","answerer_user_id":"anon_5ab5d81fb38668be","subreddit":"programming","timestamp":"2009-12-17T04:41:03+00:00","post_id":"afl23","question":"Where can I learn \"professional\" programming habits/practices/skills?\n\nI've been a hobbyist coder for a long time. I've got a decent grasp of Comp Sci basics, practical experience with quite a few languages, and hundreds of thousands of lines of code under my belt.\n\nI want to make the jump to doing some freelance projects, some contracting, and hopefully maybe get a job (in coding) at some point.\n\nThe problem is, pretty much all of my experience comes from writing code for my own for pet projects, small applications, scripts, et cetera.\n\nI've got a decent grasp on all the \"technical\" aspects of being a programmer, and for any technical areas where I am deficient I can easily educate myself.\n\nThe problem is I can't find any sites that teach the \"other\" stuff.\n\nSource control, bug tracking, best practices, tons of other topics I'm not even aware of.....\n\n\nI recently switched from a very primitive/wacky/hacked together form of \"source control\" to using bazaar, which was like a revelation to me....\n\nI really want to get a solid grounding in all this stuff. I've been learning the basics of using bazaar from the docs, but more sites couldn't hurt and I also want to be at least passingly familiar with other systems as well.\n\n\n...and if anybody has a recommendation for simple/easy bug tracking for my personal projects...whether it be software or just the method you use...would be appreciated.\n\nSo yea, please point me to any websites, books, advice, et cetera on learning all this \"other\" stuff!\n\n\nnote:\nTo a lesser extent I'm also interested in sites about how to start/go about free-lancing/contracting et cetera...for the most part I can find info on these topics, but more couldn't hurt...so if anyone has recommendations please post them.\n\n\nAt any rate I think learning this stuff would help my work on my own even if I never jump to doing it as a professional.\n\n\nEdit: Thanks everyone for the helpful advice.\n\nSo far the number one response has been \"just join a project/use the tools\"....that's certainly good advice and by no means wrong...I plan on doing so.\n\nbut, Let me clarify more what I'm interested in now:\n\n1)What tools are *you* using? Why? etc\n\n2)More Stuff like this:\n\n[Visual Guide to Version Control](http://betterexplained.com/articles/a-visual-guide-to-version-control)\n\n\n[Version Control Introduction](http://www.bbassett.net/talks/version-control/)\n\n(On any of the topics we've discussed.)\n\nOh, and one thing I forgot to mention I'm also interested in: UI design...this is something I never worried about much. If anyone knows any good resources to learn about it, please share.\n\nI'm researching on my own, but I intended this post as a request for people who were looking for the same info I am at one point, and found it, and can now point me to it.","preferred_answer":"learn by doing\n\nto some degree, stackoverflow.com is helpful, but not as much as some people may claim.\n\nreview various tools, install them, and attempt to use them. that's what i suggest.","full_conversation":[{"role":"OP","user_id":"anon_f6dcf8396a5418a5","comment_id":"afl23","kind":"post","text":"Where can I learn \"professional\" programming habits/practices/skills?\n\nI've been a hobbyist coder for a long time. I've got a decent grasp of Comp Sci basics, practical experience with quite a few languages, and hundreds of thousands of lines of code under my belt.\n\nI want to make the jump to doing some freelance projects, some contracting, and hopefully maybe get a job (in coding) at some point.\n\nThe problem is, pretty much all of my experience comes from writing code for my own for pet projects, small applications, scripts, et cetera.\n\nI've got a decent grasp on all the \"technical\" aspects of being a programmer, and for any technical areas where I am deficient I can easily educate myself.\n\nThe problem is I can't find any sites that teach the \"other\" stuff.\n\nSource control, bug tracking, best practices, tons of other topics I'm not even aware of.....\n\n\nI recently switched from a very primitive/wacky/hacked together form of \"source control\" to using bazaar, which was like a revelation to me....\n\nI really want to get a solid grounding in all this stuff. I've been learning the basics of using bazaar from the docs, but more sites couldn't hurt and I also want to be at least passingly familiar with other systems as well.\n\n\n...and if anybody has a recommendation for simple/easy bug tracking for my personal projects...whether it be software or just the method you use...would be appreciated.\n\nSo yea, please point me to any websites, books, advice, et cetera on learning all this \"other\" stuff!\n\n\nnote:\nTo a lesser extent I'm also interested in sites about how to start/go about free-lancing/contracting et cetera...for the most part I can find info on these topics, but more couldn't hurt...so if anyone has recommendations please post them.\n\n\nAt any rate I think learning this stuff would help my work on my own even if I never jump to doing it as a professional.\n\n\nEdit: Thanks everyone for the helpful advice.\n\nSo far the number one response has been \"just join a project/use the tools\"....that's certainly good advice and by no means wrong...I plan on doing so.\n\nbut, Let me clarify more what I'm interested in now:\n\n1)What tools are *you* using? Why? etc\n\n2)More Stuff like this:\n\n[Visual Guide to Version Control](http://betterexplained.com/articles/a-visual-guide-to-version-control)\n\n\n[Version Control Introduction](http://www.bbassett.net/talks/version-control/)\n\n(On any of the topics we've discussed.)\n\nOh, and one thing I forgot to mention I'm also interested in: UI design...this is something I never worried about much. If anyone knows any good resources to learn about it, please share.\n\nI'm researching on my own, but I intended this post as a request for people who were looking for the same info I am at one point, and found it, and can now point me to it.","timestamp":"2009-12-17T04:41:03+00:00","score":28},{"role":"answerer","user_id":"anon_5ab5d81fb38668be","comment_id":"c0hbvxw","kind":"comment","text":"learn by doing\n\nto some degree, stackoverflow.com is helpful, but not as much as some people may claim.\n\nreview various tools, install them, and attempt to use them. that's what i suggest.","timestamp":"2009-12-17T04:48:50+00:00","score":5},{"role":"OP","user_id":"anon_f6dcf8396a5418a5","comment_id":"c0hbx8f","kind":"comment","text":"Thanks for the reply.\n\nCould you recommend some?\n\nThat's part of the problem, I don't even really know what \"tools\" are used...so it's hard to pick X tool and say I'll teach myself to use it.","timestamp":"2009-12-17T05:12:25+00:00","score":3},{"role":"answerer","user_id":"anon_5ab5d81fb38668be","comment_id":"c0hbxmw","kind":"comment","text":"really depends what language you use. i use .net, (java will be similar) so:\n\n- build servers: cruise control, hudson, others.\n- source control: svn (best, imho), git, mercrucial. \n- tools: nant, ant (scripting build tasks, etc)\n- deployment: (disclaimer: this is something i've written: http://www.mirios.com.au/dashy), there are other automatic deployment systems popping up though, and it's a nice thing to do\n- testing: unit testing: nunit, xunit, probably similar tools for java\n- OR/M mappers: undeniably useful, but pick a good one. we use LLBLGen Pro (costs money, totally worth it), but some free ones are around and okay, but for me, in .net, there is nothing better. in java \"hibernate\" is popular.\n- bug tracking: trac [free, great]. there are others\n\nthat's all i can think of from the top of my head. apologies for formatting.","timestamp":"2009-12-17T05:20:20+00:00","score":8},{"role":"OP","user_id":"anon_f6dcf8396a5418a5","comment_id":"c0hby3f","kind":"comment","text":"This is exactly the sort of reply I was hoping for, thank you.\n\nThe majority of this stuff are things that, ideally I probably should have used as a single developer on small projects, but I didn't \"have\" to...\n\nI mostly do javascript, perl, and python stuff right now, but I do some java and I plan on getting into it more because there are a LOT of java jobs in my area.\n\nThanks","timestamp":"2009-12-17T05:29:37+00:00","score":3},{"role":"answerer","user_id":"anon_5ab5d81fb38668be","comment_id":"c0hbyak","kind":"comment","text":"Yeah, Java is a huge area. Have a crack at j2ee, you can get yourself some appserver (tomcat, websphere) and just try and get something running on it :) From there you end up screwing around with JSPs and beans and all sorts of other crap; java has a lot of libs for that. You may also be interested in profilers (\"ants profiler\"), but I personally don't use them. Sometimes useful though. NAnt/Ant will be good to learn, because you really want to automate your builds (via cruise control or hudson [go for hudson, it's more respected and has more plugins]). Once that's done, you get excited about automating other things (i.e. deployments, like i've tried to do) and testing (unit testing, which you run and get reports on, and so on), as well as DB migrations (RedGate is what we use, and that costs money, but there are some free ones around).\n\nAnyway, glad I was marginally helpful :)","timestamp":"2009-12-17T05:33:35+00:00","score":2},{"role":"OP","user_id":"anon_f6dcf8396a5418a5","comment_id":"c0hc2a3","kind":"comment","text":"I'm glad you were helpful too :-)","timestamp":"2009-12-17T07:02:29+00:00","score":1}],"n_turns":7,"n_turns_after_thanks":4,"op_metadata":{"user_id":"anon_f6dcf8396a5418a5","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_5ab5d81fb38668be","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c0hbvxw","thanks_reply_id":"c0hbx8f","post_score":28,"answer_score":5,"preferred_answer_is_top_level":true}}
{"user_id":"anon_678a8189222718cf","answerer_user_id":"anon_72772b7224e99e35","subreddit":"programming","timestamp":"2009-12-17T06:37:45+00:00","post_id":"afm8x","question":"AskProggit: Is there a good place to learn Objective-C/Cocoa?\n\nIt's winter break and I finally have some free time and I'd like to learn how to develop for OS X and iPhone, so it seemed like a good time to learn.\n\nI have previous programming experience (know a bit of C++; C#, Java and Python quite well), so I would appreciate a guide that doesn't start off with \"what is a variable\" or something like that. \n\nThanks :D","preferred_answer":"Pick up a copy of Aaron Hilegass's book, *Cocoa Programming*. Then, join your local Cocoaheads group. (See cocoaheads.org)","full_conversation":[{"role":"OP","user_id":"anon_678a8189222718cf","comment_id":"afm8x","kind":"post","text":"AskProggit: Is there a good place to learn Objective-C/Cocoa?\n\nIt's winter break and I finally have some free time and I'd like to learn how to develop for OS X and iPhone, so it seemed like a good time to learn.\n\nI have previous programming experience (know a bit of C++; C#, Java and Python quite well), so I would appreciate a guide that doesn't start off with \"what is a variable\" or something like that. \n\nThanks :D","timestamp":"2009-12-17T06:37:45+00:00","score":0},{"role":"answerer","user_id":"anon_72772b7224e99e35","comment_id":"c0hc1db","kind":"comment","text":"Pick up a copy of Aaron Hilegass's book, *Cocoa Programming*. Then, join your local Cocoaheads group. (See cocoaheads.org)","timestamp":"2009-12-17T06:40:37+00:00","score":4},{"role":"OP","user_id":"anon_678a8189222718cf","comment_id":"c0hc1q8","kind":"comment","text":"Thanks for the suggestion. Should I be concerned with the fact that the revision of the book is from before Snow Leopard? Or should everything work more or less?","timestamp":"2009-12-17T06:49:09+00:00","score":1},{"role":"answerer","user_id":"anon_72772b7224e99e35","comment_id":"c0hc1sc","kind":"comment","text":"There have been additions to the API and the feature set of the language since the book came out, but it's still an excellent introduction.","timestamp":"2009-12-17T06:50:43+00:00","score":2}],"n_turns":4,"n_turns_after_thanks":1,"op_metadata":{"user_id":"anon_678a8189222718cf","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_72772b7224e99e35","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c0hc1db","thanks_reply_id":"c0hc1q8","post_score":0,"answer_score":4,"preferred_answer_is_top_level":true}}
{"user_id":"anon_ec2d2ce12751c22d","answerer_user_id":"anon_c3a4fce3b1db9407","subreddit":"programming","timestamp":"2009-12-22T06:14:55+00:00","post_id":"ahcax","question":"Ask Proggit: Have any of you ever wanted to write a compiler or interpreter?\n\nHi everyone,\n\nI'm looking for feedback on a project I would like to start. Basically, I would like to start an educational project built around compiler and interpreter design.\n\nI remember wanting to learn how to write a compiler for the longest time. However, each time I'd approach the subject to learn more, I would run into some kind of hurdle and eventually get distracted by other projects. The hurdle usually came in the form of poor access to good educational information.\n\nThere are books available like the famous Dragon book. However, I feel that there needs to be an alternative entry vector into the field of compiler and interpreter design. The project I'm considering would consist of a simple yet fully functioning compiler (or interpreter) with a heavy amount of documentation. Beyond this trivial implementation, subjects like JIT, stack vs register, dispatching methods, and compiler frameworks could be explored.\n\nI have a small interpreter half written for a compiler design class I took at university. But I also plan on building a web site to hold all the documentation and educational material.\n\nWould any of you benefit from a project like this? I'm willing to go it alone for quite a while, but eventually I would need help from the open source community.\n\nThanks, Nick","preferred_answer":"Excellent idea. I started hacking on a personal dialect of SIOD about eight years ago, and have thought about ways to turn the work into something like what you're talking about for some time. Here are a couple thoughts/suggestions.\n\n* Start from scratch. It'll be easier for you audience to follow along when you start with a blank slate. Otherwise, you're continually explaning whatever code is already there.\n* Develop the code in a public repository, so people can see and review your progress.\n* Blog as you go... each blog post should refer into the source repo for context.\n* Forget about \"subjects like JIT, stack vs register, dispatching methods, and compiler frameworks\" until you have something basic working. Start with something that works end to end and then embellish.\n* Don't forget unit tests. More than many other kinds of development, unit tests pay off big when developing a language... it's just too easy for things to have subtle and unforseen interactions. (My own pet project has about 8,000 unit tests, and realistically needs about 20,000).\n* Don't be afraid to screw up. This is a big enough project that it's inevitable that you will... the key is to learn from it and move on. (I regularly throw away major pieces of work when it turns out they don't fit well. The reason I haven't jumped off a bridge out of frustration is that I've also kept a bunch of stuff around that has fit well.)\n\nAnyway... those are just my thoughts on the matter. If you do this, post it here, preferably multiple times.\n\n(One potential role model you might want to look at is Slava Pestov... he's done a pretty good job of documenting progress on Factor over the years. These days it's all about fairly advanced compiler optimizations, but the idea is the same.)","full_conversation":[{"role":"OP","user_id":"anon_ec2d2ce12751c22d","comment_id":"ahcax","kind":"post","text":"Ask Proggit: Have any of you ever wanted to write a compiler or interpreter?\n\nHi everyone,\n\nI'm looking for feedback on a project I would like to start. Basically, I would like to start an educational project built around compiler and interpreter design.\n\nI remember wanting to learn how to write a compiler for the longest time. However, each time I'd approach the subject to learn more, I would run into some kind of hurdle and eventually get distracted by other projects. The hurdle usually came in the form of poor access to good educational information.\n\nThere are books available like the famous Dragon book. However, I feel that there needs to be an alternative entry vector into the field of compiler and interpreter design. The project I'm considering would consist of a simple yet fully functioning compiler (or interpreter) with a heavy amount of documentation. Beyond this trivial implementation, subjects like JIT, stack vs register, dispatching methods, and compiler frameworks could be explored.\n\nI have a small interpreter half written for a compiler design class I took at university. But I also plan on building a web site to hold all the documentation and educational material.\n\nWould any of you benefit from a project like this? I'm willing to go it alone for quite a while, but eventually I would need help from the open source community.\n\nThanks, Nick","timestamp":"2009-12-22T06:14:55+00:00","score":25},{"role":"answerer","user_id":"anon_c3a4fce3b1db9407","comment_id":"c0hkx85","kind":"comment","text":"Excellent idea. I started hacking on a personal dialect of SIOD about eight years ago, and have thought about ways to turn the work into something like what you're talking about for some time. Here are a couple thoughts/suggestions.\n\n* Start from scratch. It'll be easier for you audience to follow along when you start with a blank slate. Otherwise, you're continually explaning whatever code is already there.\n* Develop the code in a public repository, so people can see and review your progress.\n* Blog as you go... each blog post should refer into the source repo for context.\n* Forget about \"subjects like JIT, stack vs register, dispatching methods, and compiler frameworks\" until you have something basic working. Start with something that works end to end and then embellish.\n* Don't forget unit tests. More than many other kinds of development, unit tests pay off big when developing a language... it's just too easy for things to have subtle and unforseen interactions. (My own pet project has about 8,000 unit tests, and realistically needs about 20,000).\n* Don't be afraid to screw up. This is a big enough project that it's inevitable that you will... the key is to learn from it and move on. (I regularly throw away major pieces of work when it turns out they don't fit well. The reason I haven't jumped off a bridge out of frustration is that I've also kept a bunch of stuff around that has fit well.)\n\nAnyway... those are just my thoughts on the matter. If you do this, post it here, preferably multiple times.\n\n(One potential role model you might want to look at is Slava Pestov... he's done a pretty good job of documenting progress on Factor over the years. These days it's all about fairly advanced compiler optimizations, but the idea is the same.)","timestamp":"2009-12-22T15:23:38+00:00","score":9},{"role":"OP","user_id":"anon_ec2d2ce12751c22d","comment_id":"c0hl4x5","kind":"comment","text":"Awesome. Thanks for the feedback. I've got my partially written interpreter up on github call [Juno](http://github.com/ncarlson/Juno/). Don't laugh :D.\n\nOne big question is whether or not I should target an intermediate code rather than just executing code directly from the AST. With Juno, I exposed some pretty simple stack machine functions. Here's a factorial program that runs on Juno - [Factorial.jas](http://github.com/ncarlson/Juno/blob/master/examples/jas/factorial.jas).","timestamp":"2009-12-22T17:35:39+00:00","score":1},{"role":"answerer","user_id":"anon_c3a4fce3b1db9407","comment_id":"c0hl5tp","kind":"comment","text":"> One big question is whether or not I should target an intermediate code rather than just executing code directly from the AST.\n\nDo both. :-)\n\nWhat I've done is started with SIOD's 'execute the AST' model and am progressively doing more and more work at compile time. Currently, I have Scheme compiling down into a dedicated binary AST type composed of rather primitive operations. The plan is to use this design to build up some key optimizations (inlining, lambda lifting, etc.) and eventually switch (maybe) to a linear bytecode representation. My plan is to measure the performance along the way to get a feel for how modern machines run this kind of code.\n\nPart of the thing that's killed me time-wise is that I've got the compiler running both ahead of time (batch style) and interactively. The build process has the compiler compiling itself, which I'm doing with a separate global environment for the host and target compilers. It's taken a while to get it working right, and taken even longer to fully understand how it's working. The ultimate goal here is Smalltalk like self-hosting. (I've also used this infrastructure to port a lot of the existing C parts of SIOD into Scheme, most notably the reader and the printer.)\n\nOne other piece of advice: I'd make an FFI the first 'big' language feature I implement. Too much of what you want to do is in the 'outside world' not to have a decent way to get there. I've just kept the standard SIOD mechanism for registering primitives, which is painful and repetitive to get right.","timestamp":"2009-12-22T17:48:35+00:00","score":1}],"n_turns":4,"n_turns_after_thanks":1,"op_metadata":{"user_id":"anon_ec2d2ce12751c22d","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_c3a4fce3b1db9407","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c0hkx85","thanks_reply_id":"c0hl4x5","post_score":25,"answer_score":9,"preferred_answer_is_top_level":true}}
{"user_id":"anon_734355976dd321ba","answerer_user_id":"anon_bf4c388e9f2fb8f3","subreddit":"programming","timestamp":"2009-12-23T15:29:03+00:00","post_id":"ahvks","question":"Help! How to emulate up/down keys on Mac OS X!\n\nMy Macbook's up/down keys are not working, i suspect someone spilled some beer on it during a party yesterday!\n\nI have to write some code due to tomorrow, and as you may imagine, coding without those two keys in impossible...\n\nDoes anyone know a way to emulate the up/down keys? I'm using Apple Terminal and Mac Os X 10.5","preferred_answer":"Open the Keyboard Viewer and clicking on the images of the keys will deliver the keystrokes. You can turn on the Keyboard Viewer in System Preferences -> International -> Input Menu. You can make it small by clicking the green zoom button.","full_conversation":[{"role":"OP","user_id":"anon_734355976dd321ba","comment_id":"ahvks","kind":"post","text":"Help! How to emulate up/down keys on Mac OS X!\n\nMy Macbook's up/down keys are not working, i suspect someone spilled some beer on it during a party yesterday!\n\nI have to write some code due to tomorrow, and as you may imagine, coding without those two keys in impossible...\n\nDoes anyone know a way to emulate the up/down keys? I'm using Apple Terminal and Mac Os X 10.5","timestamp":"2009-12-23T15:29:03+00:00","score":0},{"role":"answerer","user_id":"anon_bf4c388e9f2fb8f3","comment_id":"c0hmurk","kind":"comment","text":"Open the Keyboard Viewer and clicking on the images of the keys will deliver the keystrokes. You can turn on the Keyboard Viewer in System Preferences -> International -> Input Menu. You can make it small by clicking the green zoom button.","timestamp":"2009-12-23T15:31:58+00:00","score":5},{"role":"OP","user_id":"anon_734355976dd321ba","comment_id":"c0hmv2y","kind":"comment","text":"Thank you! Makes coding a little less painful... However I was looking for a direct way to emulate the keys... Something like Alt+a=UP Alt+b=DOWN.","timestamp":"2009-12-23T15:36:56+00:00","score":2},{"role":"answerer","user_id":"anon_bf4c388e9f2fb8f3","comment_id":"c0hmvdg","kind":"comment","text":"I don't have a fix for that, sorry.","timestamp":"2009-12-23T15:42:09+00:00","score":2}],"n_turns":4,"n_turns_after_thanks":1,"op_metadata":{"user_id":"anon_734355976dd321ba","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_bf4c388e9f2fb8f3","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c0hmurk","thanks_reply_id":"c0hmv2y","post_score":0,"answer_score":5,"preferred_answer_is_top_level":true}}
{"user_id":"anon_62c36c8623376973","answerer_user_id":"anon_c74c63e96348479a","subreddit":"programming","timestamp":"2009-12-23T15:37:23+00:00","post_id":"ahvo1","question":"Ask progitt: What are the options for having a webpage respond to keystrokes for navigation?\n\nI loathe tiny navigational buttons on web pages. I hate trying to hit a 8x8 pixel target on a busy page. It seems like one option to remove this frustration, particularly for a paged site, would be to enable 'next page' and 'previous page' navigation by keystroke.\n\nI realize that there are some serious concerns with having web pages respond to keystrokes, but I am curious if it's possible. What technologies you are aware of that could be used to provide this kind of functionality?","preferred_answer":"It is absolutely possible. You're going to have to familiarize yourself with javascript quite a bit, as there are some higher level things you're going to be using. Quirksmode has a good write-up of it JS events, [here](http://www.quirksmode.org/js/introevents.html). What you're going to have to do is observe all events, pick out the keypress events and then detect which key is being pressed. There are several libraries that make this a bit easier (Prototype & jQuery). Also, google 'event handling' for more.\n\n[Edit] Whatever you do, don't take away the normal navigation, though. There are expected ways to use the web. If users have to re-learn how to interact, they're just going to give up and bounce.","full_conversation":[{"role":"OP","user_id":"anon_62c36c8623376973","comment_id":"ahvo1","kind":"post","text":"Ask progitt: What are the options for having a webpage respond to keystrokes for navigation?\n\nI loathe tiny navigational buttons on web pages. I hate trying to hit a 8x8 pixel target on a busy page. It seems like one option to remove this frustration, particularly for a paged site, would be to enable 'next page' and 'previous page' navigation by keystroke.\n\nI realize that there are some serious concerns with having web pages respond to keystrokes, but I am curious if it's possible. What technologies you are aware of that could be used to provide this kind of functionality?","timestamp":"2009-12-23T15:37:23+00:00","score":1},{"role":"answerer","user_id":"anon_c74c63e96348479a","comment_id":"c0hmynn","kind":"comment","text":"It is absolutely possible. You're going to have to familiarize yourself with javascript quite a bit, as there are some higher level things you're going to be using. Quirksmode has a good write-up of it JS events, [here](http://www.quirksmode.org/js/introevents.html). What you're going to have to do is observe all events, pick out the keypress events and then detect which key is being pressed. There are several libraries that make this a bit easier (Prototype & jQuery). Also, google 'event handling' for more.\n\n[Edit] Whatever you do, don't take away the normal navigation, though. There are expected ways to use the web. If users have to re-learn how to interact, they're just going to give up and bounce.","timestamp":"2009-12-23T16:36:14+00:00","score":2},{"role":"OP","user_id":"anon_62c36c8623376973","comment_id":"c0hmywv","kind":"comment","text":"Thanks for the thorough answer!","timestamp":"2009-12-23T16:40:11+00:00","score":2},{"role":"answerer","user_id":"anon_c74c63e96348479a","comment_id":"c0hmzg9","kind":"comment","text":"Sure. Here is something I wrote in like 5 seconds....I have no idea if it works, but it will be something along these lines:\n\n\n document.onkeydown = function(e){\n\tif (!e) var e = window.event\n\tif (e.keyCode) code = e.keyCode;\n\telse if (e.which) code = e.which;\n\n\tif(code == 13){\n //Enter Key\n\t\twindow.location.href=\"/controller/action\";\n\t} \n\t//You'll need to figure out the exact keycodes\n\t//They differ from OS to OS, also.\n }\n\n\n[Edit] Wait, were you talking about from a user's perspective or a developer's?","timestamp":"2009-12-23T16:49:05+00:00","score":2}],"n_turns":4,"n_turns_after_thanks":1,"op_metadata":{"user_id":"anon_62c36c8623376973","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_c74c63e96348479a","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c0hmynn","thanks_reply_id":"c0hmywv","post_score":1,"answer_score":2,"preferred_answer_is_top_level":true}}
{"user_id":"anon_da35472ab373f3d9","answerer_user_id":"anon_ab797fd987410942","subreddit":"programming","timestamp":"2009-12-24T01:54:03+00:00","post_id":"ai1j8","question":"Need help choosing a data structure\n\nSo, I'm building a server that keeps meta data about a 2D map in a plane. Basically it will keep a bunch of records like\n\n* Feature A is at (x1, y1)\n* Feature B is at (x2, y2)\n\nThe only information clients can get from the server is the features located immediately north, south, east, and west of a given point.\n\nThere will be situations where the size of the map cannot be known or is infinite, so a simple 2D array will run into problems. I've been looking into sparse matrix data structures, but don't know enough about them to make a call.\n\nSo, my requirements for this data structure are:\n\n* It is able to support maps of any size\n* It has a fast(er) lookup time for adjacent positions\n\nI'm thinking I should keep it simple and just use a set data structure; O(n) isn't *too* bad. But I would like this server to scale up to several clients; if anyone knows of a good data structure for this, I'm all ears.","preferred_answer":"http://en.wikipedia.org/wiki/Kd-tree#Nearest_neighbor_search\n\nseemed like what you were looking for at first glance.\n\n> The only information clients can get from the server is the features located immediately north, south, east, and west of a given point.\n\nThis statement makes me question if you are looking for neighbors in only one dimension?","full_conversation":[{"role":"OP","user_id":"anon_da35472ab373f3d9","comment_id":"ai1j8","kind":"post","text":"Need help choosing a data structure\n\nSo, I'm building a server that keeps meta data about a 2D map in a plane. Basically it will keep a bunch of records like\n\n* Feature A is at (x1, y1)\n* Feature B is at (x2, y2)\n\nThe only information clients can get from the server is the features located immediately north, south, east, and west of a given point.\n\nThere will be situations where the size of the map cannot be known or is infinite, so a simple 2D array will run into problems. I've been looking into sparse matrix data structures, but don't know enough about them to make a call.\n\nSo, my requirements for this data structure are:\n\n* It is able to support maps of any size\n* It has a fast(er) lookup time for adjacent positions\n\nI'm thinking I should keep it simple and just use a set data structure; O(n) isn't *too* bad. But I would like this server to scale up to several clients; if anyone knows of a good data structure for this, I'm all ears.","timestamp":"2009-12-24T01:54:03+00:00","score":0},{"role":"answerer","user_id":"anon_ab797fd987410942","comment_id":"c0hnwug","kind":"comment","text":"http://en.wikipedia.org/wiki/Kd-tree#Nearest_neighbor_search\n\nseemed like what you were looking for at first glance.\n\n> The only information clients can get from the server is the features located immediately north, south, east, and west of a given point.\n\nThis statement makes me question if you are looking for neighbors in only one dimension?","timestamp":"2009-12-24T02:16:03+00:00","score":3},{"role":"OP","user_id":"anon_da35472ab373f3d9","comment_id":"c0hnxmm","kind":"comment","text":"This looks like exactly what I'm looking for, thanks!\n\n> This statement makes me question if you are looking for neighbors in only one dimension?\n\nI'm sorry, I don't understand. I'm looking for neighbors in two dimensions: (x + 1, y), (x - 1, y), (x, y + 1), (x, y - 1). The \"given point\" I mentioned is the client's current position on the map.","timestamp":"2009-12-24T02:33:41+00:00","score":1},{"role":"answerer","user_id":"anon_ab797fd987410942","comment_id":"c0ho6iu","kind":"comment","text":"If you are only looking for 4 exact points in a set, then it seems you could just serialize the coordinates for a key and use any data structure that can represent an associative array? (hash, self balancing tree).\n\nExample:\n Assuming map points are (1,1), (4,5), (4,3), (3,4), (9999,9999)\n\n associative array could look like:\n 1,1 => A\n 4,5 => B\n 4,3 => C\n 3,4 => D\n 9999,9999 => E\n \n Client requests lookup for (3,5), so lookup keys:\n 3,4: matches D\n 3,6: miss\n 4,5: matches B\n 2,5: miss\n\nNot knowing your future requirements, but guessing that you might want to find the next nearest location if a 1 unit adjacent isn't found, the kd-tree seems like your best general purpose solution.","timestamp":"2009-12-24T05:49:16+00:00","score":2}],"n_turns":4,"n_turns_after_thanks":1,"op_metadata":{"user_id":"anon_da35472ab373f3d9","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_ab797fd987410942","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c0hnwug","thanks_reply_id":"c0hnxmm","post_score":0,"answer_score":3,"preferred_answer_is_top_level":true}}
{"user_id":"anon_1b11757d33424678","answerer_user_id":"anon_3cdd3c1d79ab397e","subreddit":"programming","timestamp":"2009-12-24T11:46:58+00:00","post_id":"ai6e3","question":"Q: How to emulate polymorphism in FP?\n\nIn FP, you have closures... in which a **specific** function gets tied to a **specific** set of data, allowing this 'piece' of code+data to be moved around and used more or less as an OO 'object'. \n\nBut, then, do FP programmers ever feel a need to override/extend the code/behavior part of this piece, just as OO programmers override/extend a method in the derived class and call it via a superclass reference all the time?\n\nIf yes, how is it done? If no, how is this need worked around? Would appreciate any links / info on this. Thanks...","preferred_answer":"> You said that you use Closures as objects. That's sorta curious. There's lots of reasons to use closures to keep state and things, but as de-facto objects: that's a new one to me.\n\n[Obligatory koan](http://people.csail.mit.edu/gregs/ll1-discuss-archive-html/msg03277.html).","full_conversation":[{"role":"OP","user_id":"anon_1b11757d33424678","comment_id":"ai6e3","kind":"post","text":"Q: How to emulate polymorphism in FP?\n\nIn FP, you have closures... in which a **specific** function gets tied to a **specific** set of data, allowing this 'piece' of code+data to be moved around and used more or less as an OO 'object'. \n\nBut, then, do FP programmers ever feel a need to override/extend the code/behavior part of this piece, just as OO programmers override/extend a method in the derived class and call it via a superclass reference all the time?\n\nIf yes, how is it done? If no, how is this need worked around? Would appreciate any links / info on this. Thanks...","timestamp":"2009-12-24T11:46:58+00:00","score":0},{"role":"answerer","user_id":"anon_3cdd3c1d79ab397e","comment_id":"c0hohor","kind":"comment","text":"> You said that you use Closures as objects. That's sorta curious. There's lots of reasons to use closures to keep state and things, but as de-facto objects: that's a new one to me.\n\n[Obligatory koan](http://people.csail.mit.edu/gregs/ll1-discuss-archive-html/msg03277.html).","timestamp":"2009-12-24T12:02:29+00:00","score":10},{"role":"OP","user_id":"anon_1b11757d33424678","comment_id":"c0hohyd","kind":"comment","text":"+1. Thanks ealf. Your link (and, the link inside that page) is, it seems, what I was looking for. I haven't read the whole thing yet but I KNOW what I'm looking for IS most likely in there :-) Thanks again, and Merry Christmas, btw!","timestamp":"2009-12-24T12:17:13+00:00","score":1},{"role":"answerer","user_id":"anon_3cdd3c1d79ab397e","comment_id":"c0hoi0s","kind":"comment","text":"Merry Christmas, all y'all! *goes back to wrapping packages*","timestamp":"2009-12-24T12:20:09+00:00","score":1}],"n_turns":4,"n_turns_after_thanks":1,"op_metadata":{"user_id":"anon_1b11757d33424678","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_3cdd3c1d79ab397e","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c0hohor","thanks_reply_id":"c0hohyd","post_score":0,"answer_score":10,"preferred_answer_is_top_level":false}}
{"user_id":"anon_7b4c6477565a84d3","answerer_user_id":"anon_16a59ba4eb17fe1e","subreddit":"programming","timestamp":"2009-12-26T07:30:02+00:00","post_id":"aimlg","question":"AskProggit: How do I find the dominant color in an image? If I want to find images in a collection of images that best match a selected color, what is the best way to do it for a website? Is there a library that can do that?","preferred_answer":"I did this years ago by performing color quantization to a 32-color palette, and then take the most frequent pixel encountered. Slightly hacky, but it did the trick.","full_conversation":[{"role":"OP","user_id":"anon_7b4c6477565a84d3","comment_id":"aimlg","kind":"post","text":"AskProggit: How do I find the dominant color in an image? If I want to find images in a collection of images that best match a selected color, what is the best way to do it for a website? Is there a library that can do that?","timestamp":"2009-12-26T07:30:02+00:00","score":0},{"role":"answerer","user_id":"anon_16a59ba4eb17fe1e","comment_id":"c0hr71d","kind":"comment","text":"I did this years ago by performing color quantization to a 32-color palette, and then take the most frequent pixel encountered. Slightly hacky, but it did the trick.","timestamp":"2009-12-26T08:34:50+00:00","score":2},{"role":"OP","user_id":"anon_7b4c6477565a84d3","comment_id":"c0hrktk","kind":"comment","text":"Thanks, that's half the problem solved - the other half is to find the similarity between that pixel color and the color I'm looking for to determine if it's close enough.","timestamp":"2009-12-26T17:58:44+00:00","score":1},{"role":"answerer","user_id":"anon_16a59ba4eb17fe1e","comment_id":"c0ht3tn","kind":"comment","text":"That is pretty simple; calculate the distance from your color to the most frequent quantized color in 3D space (ie sqrt(r_delta^2+g_delta^2+b_delta^2) - since the human eye is more susceptible to green, you might want to perform color space conversion before calculating the distance (i.e. YCbCr).","timestamp":"2009-12-27T20:32:54+00:00","score":1}],"n_turns":4,"n_turns_after_thanks":1,"op_metadata":{"user_id":"anon_7b4c6477565a84d3","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_16a59ba4eb17fe1e","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c0hr71d","thanks_reply_id":"c0hrktk","post_score":0,"answer_score":2,"preferred_answer_is_top_level":true}}
{"user_id":"anon_dd94c7205de9a2fd","answerer_user_id":"anon_5f7847ea89fdc898","subreddit":"programming","timestamp":"2009-12-28T23:09:46+00:00","post_id":"ajbx8","question":"What should I do with my working, playable 3d MOPRG?\n\nScreenshots at [evidyon.com](http://www.evidyon.com/gallery.html)\n\n\nI've spent a good number of years teaching myself to code and write games. Throughout college \"Evidyon\" has been my hobby project, and last summer a few friends (on the content side) and I finally got it to a playable state. This is an isometric-3d fast-paced multiplayer fantasy video game. It's client/server model, features real-time combat and has a persistent world. The game is more than 140 thousand lines (of my own code) and is written on top of DirectX 9/ENet/sqlite.\n\nIt has its own extensive game editor, server, client, auto-updating launcher, patching utility, and oodles of custom 3d content. There is a particle effects system, bone-based skinned mesh support, several kinds of monster AI, a complete GUI framework, sound effect integration and tons of code relating to gameplay (spells, races, classes, monsters, maps, dungeons, etc). Everything from spells, items and maps to game-events and bug-fixes can be pushed out with only a few clicks.\n\nThe game was played actively in the past with dozens of people online at any given time and there are more than a few thousand accounts on the active server.\n\n \n\nHere's the problem: It's unlikely I'll have a significant amount of time to commit to the project in the future.\n \n \nWhile this project was really fun to work on, one person can't turn it into a business that is able to compete with the giant, free MMOs out there today. With classes this semester, I already had essentially no time to work on the project. Updates were lacking and the player-base has all but vanished.\n\nWhile it has some issues--the graphics are entirely based on the extremely outdated fixed-function pipeline--it's an MORPG coded by 1 person that really works. I know firsthand how hard it is to learn to program games, and there is so much good code in this project that it would be a shame just to see it collect dust on my hard drive.\n\nOpen-sourcing is a possibility, but I don't want to just dump this thing on the internet and look the other way. I'm considering writing articles for GameDev.net on some of the various parts, and pulling out modules that showcase interesting or hard-to-find functionality (like the slick navigation algorithm the monsters use, or the way the game feels lag-free even under 400 ms of jittery packet delay).\n\n \nAny ideas?\n\n \n \n \n\n**tl;dr** I created an MORPG and people played it for a while, but I have no time to develop it further. What should I do?\n\n\n**edit** Thank you everyone who has responded! It seems that there are plenty of people interested in the source code of the game, and that it would be useful enough for me to devote a bit of time to getting it and some tutorials online. I'll start cleaning things up and preparing material, and hope to come back with a public release before school resumes in February. Thanks again!","preferred_answer":"Figured it out.\n\n[Network]\nServer1=evidyon.no-ip.org\n\nChange the config to have that at the bottom instead of what's there now. The game has potential. Installation was easy, movement was slick, and one of the guards came running over to defend.. that was cool.","full_conversation":[{"role":"OP","user_id":"anon_dd94c7205de9a2fd","comment_id":"ajbx8","kind":"post","text":"What should I do with my working, playable 3d MOPRG?\n\nScreenshots at [evidyon.com](http://www.evidyon.com/gallery.html)\n\n\nI've spent a good number of years teaching myself to code and write games. Throughout college \"Evidyon\" has been my hobby project, and last summer a few friends (on the content side) and I finally got it to a playable state. This is an isometric-3d fast-paced multiplayer fantasy video game. It's client/server model, features real-time combat and has a persistent world. The game is more than 140 thousand lines (of my own code) and is written on top of DirectX 9/ENet/sqlite.\n\nIt has its own extensive game editor, server, client, auto-updating launcher, patching utility, and oodles of custom 3d content. There is a particle effects system, bone-based skinned mesh support, several kinds of monster AI, a complete GUI framework, sound effect integration and tons of code relating to gameplay (spells, races, classes, monsters, maps, dungeons, etc). Everything from spells, items and maps to game-events and bug-fixes can be pushed out with only a few clicks.\n\nThe game was played actively in the past with dozens of people online at any given time and there are more than a few thousand accounts on the active server.\n\n \n\nHere's the problem: It's unlikely I'll have a significant amount of time to commit to the project in the future.\n \n \nWhile this project was really fun to work on, one person can't turn it into a business that is able to compete with the giant, free MMOs out there today. With classes this semester, I already had essentially no time to work on the project. Updates were lacking and the player-base has all but vanished.\n\nWhile it has some issues--the graphics are entirely based on the extremely outdated fixed-function pipeline--it's an MORPG coded by 1 person that really works. I know firsthand how hard it is to learn to program games, and there is so much good code in this project that it would be a shame just to see it collect dust on my hard drive.\n\nOpen-sourcing is a possibility, but I don't want to just dump this thing on the internet and look the other way. I'm considering writing articles for GameDev.net on some of the various parts, and pulling out modules that showcase interesting or hard-to-find functionality (like the slick navigation algorithm the monsters use, or the way the game feels lag-free even under 400 ms of jittery packet delay).\n\n \nAny ideas?\n\n \n \n \n\n**tl;dr** I created an MORPG and people played it for a while, but I have no time to develop it further. What should I do?\n\n\n**edit** Thank you everyone who has responded! It seems that there are plenty of people interested in the source code of the game, and that it would be useful enough for me to devote a bit of time to getting it and some tutorials online. I'll start cleaning things up and preparing material, and hope to come back with a public release before school resumes in February. Thanks again!","timestamp":"2009-12-28T23:09:46+00:00","score":101},{"role":"answerer","user_id":"anon_5f7847ea89fdc898","comment_id":"c0hvakt","kind":"comment","text":"Figured it out.\n\n[Network]\nServer1=evidyon.no-ip.org\n\nChange the config to have that at the bottom instead of what's there now. The game has potential. Installation was easy, movement was slick, and one of the guards came running over to defend.. that was cool.","timestamp":"2009-12-29T02:47:35+00:00","score":1},{"role":"OP","user_id":"anon_dd94c7205de9a2fd","comment_id":"c0hvcgl","kind":"comment","text":"Thanks for pointing that fix out, I forgot people might actually want to run it! Hah. Anyway, glad you liked it.","timestamp":"2009-12-29T03:24:04+00:00","score":3},{"role":"answerer","user_id":"anon_5f7847ea89fdc898","comment_id":"c0hve3p","kind":"comment","text":"Is this C++? What software did you use for the graphics and 3d models?","timestamp":"2009-12-29T03:56:13+00:00","score":1},{"role":"OP","user_id":"anon_dd94c7205de9a2fd","comment_id":"c0hve8h","kind":"comment","text":"Yes, this is written in pure C++. Photoshop for the textures, and the amazingly awesome [FragMotion](http://www.fragmosoft.com/) for the meshes.","timestamp":"2009-12-29T03:58:58+00:00","score":1}],"n_turns":5,"n_turns_after_thanks":2,"op_metadata":{"user_id":"anon_dd94c7205de9a2fd","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_5f7847ea89fdc898","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c0hvakt","thanks_reply_id":"c0hvcgl","post_score":101,"answer_score":1,"preferred_answer_is_top_level":false}}
{"user_id":"anon_136cc9e6862d57d6","answerer_user_id":"anon_81d4c5c1d200409a","subreddit":"programming","timestamp":"2009-12-30T05:51:56+00:00","post_id":"ajshr","question":"Regarding reddit's database model\n\nHi,\nI wanna know how Reddit stores the tree structure of its conversations in database? Does it use XML to store the tree structure and apply stylesheet to it? How does it achieve its spectacular n level hierarchy?","preferred_answer":">I am being honest,\n\nSorry. And you deserve an honest answer. \nBut we aren not totally clear what part of it you don't understand.\n\nLook at it like this: There is one \"array\" type in PHP. \nDo you think the internal representation thinks of it as a hierarchy?\nNope. It's just a dictionary (like a row in a database) that may happen to contain other dictionaries. \n\nHere is a piece of example PHP code (i normally don't write in PHP anymore but the languages I use mostly have frameworks that create models and everything, I have only done manual SQL in php). So this example is PHP, my apologies. In ruby for example, you can just install a plugin and turn on act_as_tree. But that wouldn't be very educational now would it.\n\n function q( $qry, $arg ){\n // some code that executes a query and replaces question marks \n // in the query with the _escaped_ arguments from $arg\n // it returns all the results as an array\n // this should have been part of PHP, but PHP sucks so it isn't.\n }\n\n function draw_node( node ){\n $row = q (\" SELECT * FROM comments WHERE parent=?\", array( node ));\n foreach ($row in $result) {\n print \"
\" + htmlescapechars( $row['comment'] ) \"
\"\n print \"
\"\n draw_node( $row['id'] )\n print \"
\"\n }\n }\n \nThe comment table is very simple here:\n\n- id: auto generated/incremented id\n- comment: the text of the comment\n- parent: the id of the parent comment; this is null for top level comments\n\nThe thing you seem to be confused about is that one would _not_ query the whole tree at once. I mean one query that just returns the whole tree. \n\nAlthough it is possible in SQL with a stored procedure. But you still have to rebuild the tree from the data returned. It is even possible upto a certain level if you use left joins. But that get's ugly really fast. (and the end result would be a lot of duplicated data for every row).\n\nIf the amount of queries create a performance problem, it's much wiser to cache the tree, or if it's constant, the whole html of the tree. I don't know if there are any smart caching libraries out there for PHP.\n\nBut it's not that hard to do yourself. Here is an example:\n\n function qtree( $table, $key, $node )\n {\n $result = q(\"SELECT * from `?` where `id`=? \", array( $table, $node )\n if (! length ($result) ) return null;\n $result = $result[0]\n $result['children'] = array ();\n $children = q(\"SELECT `id` from `?` where `?`=?\", array( $table, $key, $node )\n\n foreach ( $child in $children ){\n $result['children'][$child['id']] = qtree( $table, $key, $child['id'] )\n }\n return $result;\n }\n\n function cache_tree( $table, $key, $node, $age ){\n $r = q(\"SELECT * FROM `tree_cache` WHERE `table`='?' AND `key`=? AND `node`=? AND `updated_at` > ?\", array($table, $key, $node, $age)\n if( !length($r) ) then{\n q(\"DELETE FROM `tree_cache` WHERE `table`='?', `key`='?', `node`=?\", array($tree, $key, $node)\n q(\"INSERT INTO `tree_cache` SET `table`='?', `key`=?, `node`=?, `tree`='?' \", array( $table, $key, $node, json_encode( qtree( $table, $key, $node ) ) );\n return cache_tree( $table, $key, $node, $age );\n }\n return json_decode( $r['tree'], true )\n } \n\nNotice that you give the give the cache-tree function an _age_ argument.\nThis should be the minimum timestamp for the cache. Otherwise it will regenerate the cache.\n\nThis uses a tree_cache table which has the following columns:\n\n- table: char of the table name\n- node: the id within that table (could be null)\n- key: char of the key used to make the tree \n- tree: actual tree data stored as json for space reasons\n- updated_at: timestamp\n\nMake sure there is an index on (table, key, node) together.\n\nIf you don't want to bother with the _age_ and always want the data be real time, use something like this:\n\n function smart_cache_tree( $table, $key, $node ){\n $r = q(\"SELECT MAX(`updated_at`) as `age` FROM $table\")\n if (!length($r)) return null;\n $r = $r[0];\n return cache_tree( $table, $key, $node, $r['age'] )\n }\n \nHowever, make sure the target table has a `updated_at` column _and_ that there is an INDEX on that column.\n\nIt likely has bugs the above code. PHP is a long long time ago for me.\nBut the general idea should be clear.\n\nPS. I'm using json-encode and json-decode for serialisation. But if I'm rememberring correctly those functions have bugs. Perhaps you want to serialize differently.","full_conversation":[{"role":"OP","user_id":"anon_136cc9e6862d57d6","comment_id":"ajshr","kind":"post","text":"Regarding reddit's database model\n\nHi,\nI wanna know how Reddit stores the tree structure of its conversations in database? Does it use XML to store the tree structure and apply stylesheet to it? How does it achieve its spectacular n level hierarchy?","timestamp":"2009-12-30T05:51:56+00:00","score":0},{"role":"answerer","user_id":"anon_81d4c5c1d200409a","comment_id":"c0hxukv","kind":"comment","text":">I am being honest,\n\nSorry. And you deserve an honest answer. \nBut we aren not totally clear what part of it you don't understand.\n\nLook at it like this: There is one \"array\" type in PHP. \nDo you think the internal representation thinks of it as a hierarchy?\nNope. It's just a dictionary (like a row in a database) that may happen to contain other dictionaries. \n\nHere is a piece of example PHP code (i normally don't write in PHP anymore but the languages I use mostly have frameworks that create models and everything, I have only done manual SQL in php). So this example is PHP, my apologies. In ruby for example, you can just install a plugin and turn on act_as_tree. But that wouldn't be very educational now would it.\n\n function q( $qry, $arg ){\n // some code that executes a query and replaces question marks \n // in the query with the _escaped_ arguments from $arg\n // it returns all the results as an array\n // this should have been part of PHP, but PHP sucks so it isn't.\n }\n\n function draw_node( node ){\n $row = q (\" SELECT * FROM comments WHERE parent=?\", array( node ));\n foreach ($row in $result) {\n print \"
\" + htmlescapechars( $row['comment'] ) \"
\"\n print \"
\"\n draw_node( $row['id'] )\n print \"
\"\n }\n }\n \nThe comment table is very simple here:\n\n- id: auto generated/incremented id\n- comment: the text of the comment\n- parent: the id of the parent comment; this is null for top level comments\n\nThe thing you seem to be confused about is that one would _not_ query the whole tree at once. I mean one query that just returns the whole tree. \n\nAlthough it is possible in SQL with a stored procedure. But you still have to rebuild the tree from the data returned. It is even possible upto a certain level if you use left joins. But that get's ugly really fast. (and the end result would be a lot of duplicated data for every row).\n\nIf the amount of queries create a performance problem, it's much wiser to cache the tree, or if it's constant, the whole html of the tree. I don't know if there are any smart caching libraries out there for PHP.\n\nBut it's not that hard to do yourself. Here is an example:\n\n function qtree( $table, $key, $node )\n {\n $result = q(\"SELECT * from `?` where `id`=? \", array( $table, $node )\n if (! length ($result) ) return null;\n $result = $result[0]\n $result['children'] = array ();\n $children = q(\"SELECT `id` from `?` where `?`=?\", array( $table, $key, $node )\n\n foreach ( $child in $children ){\n $result['children'][$child['id']] = qtree( $table, $key, $child['id'] )\n }\n return $result;\n }\n\n function cache_tree( $table, $key, $node, $age ){\n $r = q(\"SELECT * FROM `tree_cache` WHERE `table`='?' AND `key`=? AND `node`=? AND `updated_at` > ?\", array($table, $key, $node, $age)\n if( !length($r) ) then{\n q(\"DELETE FROM `tree_cache` WHERE `table`='?', `key`='?', `node`=?\", array($tree, $key, $node)\n q(\"INSERT INTO `tree_cache` SET `table`='?', `key`=?, `node`=?, `tree`='?' \", array( $table, $key, $node, json_encode( qtree( $table, $key, $node ) ) );\n return cache_tree( $table, $key, $node, $age );\n }\n return json_decode( $r['tree'], true )\n } \n\nNotice that you give the give the cache-tree function an _age_ argument.\nThis should be the minimum timestamp for the cache. Otherwise it will regenerate the cache.\n\nThis uses a tree_cache table which has the following columns:\n\n- table: char of the table name\n- node: the id within that table (could be null)\n- key: char of the key used to make the tree \n- tree: actual tree data stored as json for space reasons\n- updated_at: timestamp\n\nMake sure there is an index on (table, key, node) together.\n\nIf you don't want to bother with the _age_ and always want the data be real time, use something like this:\n\n function smart_cache_tree( $table, $key, $node ){\n $r = q(\"SELECT MAX(`updated_at`) as `age` FROM $table\")\n if (!length($r)) return null;\n $r = $r[0];\n return cache_tree( $table, $key, $node, $r['age'] )\n }\n \nHowever, make sure the target table has a `updated_at` column _and_ that there is an INDEX on that column.\n\nIt likely has bugs the above code. PHP is a long long time ago for me.\nBut the general idea should be clear.\n\nPS. I'm using json-encode and json-decode for serialisation. But if I'm rememberring correctly those functions have bugs. Perhaps you want to serialize differently.","timestamp":"2009-12-30T09:12:39+00:00","score":3},{"role":"OP","user_id":"anon_136cc9e6862d57d6","comment_id":"c0hxusv","kind":"comment","text":"Thanks man, this is elaborate! \nMy actual question of database representation still remains though..","timestamp":"2009-12-30T09:21:23+00:00","score":0},{"role":"answerer","user_id":"anon_81d4c5c1d200409a","comment_id":"c0hxvti","kind":"comment","text":"Ehm, I thought I was quite clear about that.\n\nThe comment table is very simple here:\n\n- id: auto generated/incremented id\n- comment: the text of the comment\n- parent: the id of the parent comment; this is null for top level comments\n\nBut if that isn't clear enough, here is ACTUAL sql code to create the tree.\n\n CREATE TABLE `comments` (\n `id` INT NOT NULL COMMENT 'the primary key',\n `parent` INT NOT NULL COMMENT 'the id of the parent comment',\n `comment` TEXT NOT NULL COMMENT 'the actual comment',\n PRIMARY KEY ( `id` )\n ) \n\nSo this tree:\n\n \"PHP Sucks\"\n - \"I know\"\n - \"It's horrible\"\n - \"You are a troll, you know?\"\n - \"How do you do a tree in php?\"\n - \"You mean in sql, right?\"\n - \"It's not the language, it's the users and the design patterns that just are all wrong\" \n \nWould be something like:\n\n insert into `comments` (id, parent, comment) VALUES\n (0, NULL, \"PHP Sucks\"),\n (1, 0, \"I know\"),\n (2, 0, \"It's horrible\"),\n (3, 2, \"You are a troll, you know?\")\n (4, 0, \"How do you do a tree in php?\"),\n (5, 4, \"You mean in sql, right?\")\n (6, 0, \"It's not the language, it's the users and the design patterns that just ...\")","timestamp":"2009-12-30T10:00:52+00:00","score":2},{"role":"OP","user_id":"anon_136cc9e6862d57d6","comment_id":"c0hxvvm","kind":"comment","text":"It's clear this time. Embarrassed and grateful!","timestamp":"2009-12-30T10:03:07+00:00","score":1}],"n_turns":5,"n_turns_after_thanks":2,"op_metadata":{"user_id":"anon_136cc9e6862d57d6","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_81d4c5c1d200409a","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c0hxukv","thanks_reply_id":"c0hxusv","post_score":0,"answer_score":3,"preferred_answer_is_top_level":false}}
{"user_id":"anon_5f074b83b8ed6752","answerer_user_id":"anon_56c88f8a4fdd9a1d","subreddit":"programming","timestamp":"2009-12-31T01:41:29+00:00","post_id":"ak3ch","question":"What road should I take to develop on the iPhone?\n\nHave a Mac? Check. Have Xcode? Check. Have an iPhone? Check. Know Objective-C? Negative.\n\nMy question is, in order to learn Objective-C is it necessary to have a good understanding of C? My programming skills are in the Javascript, Ruby, and PHP spectrum. The goal here is the shortest path to take for iPhone development, so is it possible to learn Objective-C without learning C first? If so, does anyone recommend any good books/resources?","preferred_answer":"[iPhone Application Programming](http://deimos3.apple.com/WebObjects/Core.woa/Browse/itunes.stanford.edu.2024353965.02024353968) @ Standford University free via iTunes U ([course homepage](http://cs193p.stanford.edu/))\n\nThe lectures and assignments are illustrative and to the point, focusing mainly on the Cocoa way of doing things. They take you through a lot of the fundamentals of XCode and Cocoa development in screencast fashion, including browsing the Cocoa API through the built-in documentation. It's definitely worth your time, even if you don't follow through all the way to the end, at which point you'll have a functioning Twitter client that looks and feels like a proper iPhone app.\n\nJavascript, Ruby and PHP are different enough from each other that I don't think Objective-C will be a problem for you.","full_conversation":[{"role":"OP","user_id":"anon_5f074b83b8ed6752","comment_id":"ak3ch","kind":"post","text":"What road should I take to develop on the iPhone?\n\nHave a Mac? Check. Have Xcode? Check. Have an iPhone? Check. Know Objective-C? Negative.\n\nMy question is, in order to learn Objective-C is it necessary to have a good understanding of C? My programming skills are in the Javascript, Ruby, and PHP spectrum. The goal here is the shortest path to take for iPhone development, so is it possible to learn Objective-C without learning C first? If so, does anyone recommend any good books/resources?","timestamp":"2009-12-31T01:41:29+00:00","score":0},{"role":"answerer","user_id":"anon_56c88f8a4fdd9a1d","comment_id":"c0hz8yr","kind":"comment","text":"[iPhone Application Programming](http://deimos3.apple.com/WebObjects/Core.woa/Browse/itunes.stanford.edu.2024353965.02024353968) @ Standford University free via iTunes U ([course homepage](http://cs193p.stanford.edu/))\n\nThe lectures and assignments are illustrative and to the point, focusing mainly on the Cocoa way of doing things. They take you through a lot of the fundamentals of XCode and Cocoa development in screencast fashion, including browsing the Cocoa API through the built-in documentation. It's definitely worth your time, even if you don't follow through all the way to the end, at which point you'll have a functioning Twitter client that looks and feels like a proper iPhone app.\n\nJavascript, Ruby and PHP are different enough from each other that I don't think Objective-C will be a problem for you.","timestamp":"2009-12-31T01:57:31+00:00","score":2},{"role":"OP","user_id":"anon_5f074b83b8ed6752","comment_id":"c0hz91j","kind":"comment","text":"Thanks :-)\n\nBut should I pick up C before Objective-C? I'm sure learning it \"can't hurt\", at the very least, but is it something that's pretty much necessary?","timestamp":"2009-12-31T01:59:04+00:00","score":1},{"role":"answerer","user_id":"anon_56c88f8a4fdd9a1d","comment_id":"c0hz9xh","kind":"comment","text":"Just dive into Objective-C and don't sweat it. It wouldn't hurt, sure, but I would imagine that with Javascript, Ruby and PHP experience you're at or very near to a point where learning another language is just learning another language.\n\nIf you hit a roadblock that is truly due to the language (which I would expect is unlikely), then yes, maybe you'll want to take a look at another C-derived language for a while before you return to Objective-C.","timestamp":"2009-12-31T02:16:02+00:00","score":2}],"n_turns":4,"n_turns_after_thanks":1,"op_metadata":{"user_id":"anon_5f074b83b8ed6752","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_56c88f8a4fdd9a1d","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c0hz8yr","thanks_reply_id":"c0hz91j","post_score":0,"answer_score":2,"preferred_answer_is_top_level":true}}
{"user_id":"anon_c050e0f80d0394a5","answerer_user_id":"anon_677c3e98a539c9b7","subreddit":"programming","timestamp":"2010-01-01T03:35:45+00:00","post_id":"akfaf","question":"Ask Proggit: What language is the online game Yahoo towers built on?\n\nJust curious.","preferred_answer":"It needed to load an applet, so Java.","full_conversation":[{"role":"OP","user_id":"anon_c050e0f80d0394a5","comment_id":"akfaf","kind":"post","text":"Ask Proggit: What language is the online game Yahoo towers built on?\n\nJust curious.","timestamp":"2010-01-01T03:35:45+00:00","score":0},{"role":"answerer","user_id":"anon_677c3e98a539c9b7","comment_id":"c0i1c9t","kind":"comment","text":"It needed to load an applet, so Java.","timestamp":"2010-01-01T04:03:24+00:00","score":2},{"role":"OP","user_id":"anon_c050e0f80d0394a5","comment_id":"c0i1dcu","kind":"comment","text":"Thank you. \n\nI also have another question. Is Java applet dead? Does anyone still use it?","timestamp":"2010-01-01T04:38:18+00:00","score":1},{"role":"answerer","user_id":"anon_677c3e98a539c9b7","comment_id":"c0i1dg5","kind":"comment","text":"What do you mean, \"is Java applet dead\" ?\n\nI didn't see many people in the game rooms so it looks pretty dead to me. But hey, it's New Years Eve, people probably have better things to do tonight than play a Java game. (Hopefully =p)","timestamp":"2010-01-01T04:41:18+00:00","score":1},{"role":"OP","user_id":"anon_c050e0f80d0394a5","comment_id":"c0i1drm","kind":"comment","text":"I don't mean the game itself. I wanted to know if people like programmers still use applets.","timestamp":"2010-01-01T04:50:47+00:00","score":1},{"role":"answerer","user_id":"anon_677c3e98a539c9b7","comment_id":"c0i1dvt","kind":"comment","text":"Java applets are still used whenever people want to embed Java applets on a webpage....","timestamp":"2010-01-01T04:54:33+00:00","score":2}],"n_turns":6,"n_turns_after_thanks":3,"op_metadata":{"user_id":"anon_c050e0f80d0394a5","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_677c3e98a539c9b7","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c0i1c9t","thanks_reply_id":"c0i1dcu","post_score":0,"answer_score":2,"preferred_answer_is_top_level":true}}
{"user_id":"anon_1ee3f2fa504fcc94","answerer_user_id":"anon_a422682ba3dff109","subreddit":"programming","timestamp":"2010-01-01T06:37:57+00:00","post_id":"akg8s","question":"Clojure - A passable Lisp?\n\nHi all,\n\nAfter reading the article [The Nature of Lisp](http://www.defmacro.org/ramblings/lisp.html) I've finally decided to give Lisp a try. Given that I'm a typical Java programmer, Clojure seemed to be a nice choice. But is Clojure a passable Lisp? Do Clojure programmers feel that they have achieved *teh* nirvana after getting down and dirty with Clojure? Does being tied to the JVM make Clojure an \"almost Lisp\" implementation? Would I be better off with some other Lisp implementation as a beginner?\n\nSuggestions much appreciated. TIA!","preferred_answer":"I suggest the path to nivana is spelled SICP.\n\n http://mitpress.mit.edu/sicp","full_conversation":[{"role":"OP","user_id":"anon_1ee3f2fa504fcc94","comment_id":"akg8s","kind":"post","text":"Clojure - A passable Lisp?\n\nHi all,\n\nAfter reading the article [The Nature of Lisp](http://www.defmacro.org/ramblings/lisp.html) I've finally decided to give Lisp a try. Given that I'm a typical Java programmer, Clojure seemed to be a nice choice. But is Clojure a passable Lisp? Do Clojure programmers feel that they have achieved *teh* nirvana after getting down and dirty with Clojure? Does being tied to the JVM make Clojure an \"almost Lisp\" implementation? Would I be better off with some other Lisp implementation as a beginner?\n\nSuggestions much appreciated. TIA!","timestamp":"2010-01-01T06:37:57+00:00","score":0},{"role":"answerer","user_id":"anon_a422682ba3dff109","comment_id":"c0i1h93","kind":"comment","text":"I suggest the path to nivana is spelled SICP.\n\n http://mitpress.mit.edu/sicp","timestamp":"2010-01-01T06:47:11+00:00","score":3},{"role":"OP","user_id":"anon_1ee3f2fa504fcc94","comment_id":"c0i1huy","kind":"comment","text":"That seems so..academic and old; but I'll still give it a try. Thanks.","timestamp":"2010-01-01T07:08:02+00:00","score":-2},{"role":"answerer","user_id":"anon_a422682ba3dff109","comment_id":"c0i1iu6","kind":"comment","text":"Hopefully you won't see it that way after just the first few pages. It is many peoples favorite programming text ever. It isn't a dry text. The footnotes are fun too.","timestamp":"2010-01-01T07:39:16+00:00","score":1}],"n_turns":4,"n_turns_after_thanks":1,"op_metadata":{"user_id":"anon_1ee3f2fa504fcc94","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_a422682ba3dff109","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c0i1h93","thanks_reply_id":"c0i1huy","post_score":0,"answer_score":3,"preferred_answer_is_top_level":true}}
{"user_id":"anon_b477753e11ef235b","answerer_user_id":"anon_f53f7e35febc415c","subreddit":"programming","timestamp":"2010-01-02T04:05:41+00:00","post_id":"akode","question":"Looking for some ideas for a new programming language","preferred_answer":"Do what dylan does. Anything after the word \"end\" is ignored (treated like a comment).\n\nSo you can type \"end\" or you can type \"end something or another\" and it would be the same thing.\n\nWhile you are at it crib the \"alias\" command from ruby and alias \"}\" to \"end\".\n\nVoila you have now covered cases B,C, and D.\n\nif you really want to go nuts you can alias { to a no-op of some sort and you will have covered all your cases. \n\n\nPersonally I would save the braces for something else.","full_conversation":[{"role":"OP","user_id":"anon_b477753e11ef235b","comment_id":"akode","kind":"post","text":"Looking for some ideas for a new programming language","timestamp":"2010-01-02T04:05:41+00:00","score":0},{"role":"answerer","user_id":"anon_f53f7e35febc415c","comment_id":"c0i2qx2","kind":"comment","text":"Do what dylan does. Anything after the word \"end\" is ignored (treated like a comment).\n\nSo you can type \"end\" or you can type \"end something or another\" and it would be the same thing.\n\nWhile you are at it crib the \"alias\" command from ruby and alias \"}\" to \"end\".\n\nVoila you have now covered cases B,C, and D.\n\nif you really want to go nuts you can alias { to a no-op of some sort and you will have covered all your cases. \n\n\nPersonally I would save the braces for something else.","timestamp":"2010-01-02T04:51:47+00:00","score":1},{"role":"OP","user_id":"anon_b477753e11ef235b","comment_id":"c0i2ufu","kind":"comment","text":"Thank you, I really like your suggestion to copy dylan.\r\n\r\nAs for the brace, I'm thinking I need an entirely different symbol to translate to end. I tried \".\", that that's way too hard to pick out of an otherwise empty line..","timestamp":"2010-01-02T06:06:01+00:00","score":1},{"role":"answerer","user_id":"anon_f53f7e35febc415c","comment_id":"c0i2vuu","kind":"comment","text":"You could go the php way and make keywords like endif, endwhile etc.\n\nI don't know what other sigil makes sense though. Period may seem like a good choice because we use it in english but really ending a definition is more like ending a paragraph and not a sentence.\n\nYou could take the python approach and significant indents.\n\nOr M\\maybe take a hint from markup. Double carriage return marks an end. I mean if you can have significant horizontal whitespace you can have significant vertical whitespace right?\n\nOTOH I fucking hate significant whitespace.","timestamp":"2010-01-02T06:36:47+00:00","score":2},{"role":"OP","user_id":"anon_b477753e11ef235b","comment_id":"c0i2wns","kind":"comment","text":"> You could go the php way and make keywords like endif, endwhile etc.\r\n\r\nI don't think I want that, though it would solve one question. Currently I'm debating two ways of handling what comes after end.\r\n\r\n1. Treat is like a comment as you suggested eariler.\r\n\r\n2. If there is \"end if\", make sure it is actually ending an if block. If there is just \"end\", assume the programmer knows what he is doing.\r\n\r\n> Double carriage return marks an end.\r\n\r\nTempting, really tempting. But expect that will start to suck as soon as you write a block that is more than a a few lines long.","timestamp":"2010-01-02T06:55:21+00:00","score":1}],"n_turns":5,"n_turns_after_thanks":2,"op_metadata":{"user_id":"anon_b477753e11ef235b","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_f53f7e35febc415c","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c0i2qx2","thanks_reply_id":"c0i2ufu","post_score":0,"answer_score":1,"preferred_answer_is_top_level":true}}
{"user_id":"anon_ceb153b89e40941b","answerer_user_id":"anon_59e609d1ff198342","subreddit":"programming","timestamp":"2010-01-02T21:39:02+00:00","post_id":"akvx6","question":"Best Linux/UNIX way to step through and debug C program?\n\nDammit, Jim, I'm a sysadmin not a programmer! \n\nSo I've been tasked with debugging this abandoned C program on a server I admin. The last time I did any major screwing around in C, Borland's Turbo C/C++ IDE was fresh and kicked ass. Not only am I woefully rusty in my C, but I'm clueless as to getting a UNIX enviroment/IDE that comes close to the Tubo C IDE I so fondly remember.\n\nI need a way to trace and debug this puppy ASAP. I don't care if it's console mode (any good emacs tutorials out there for this?) or a huge bloated GUI will all the bells and whistles (does Eclipse have these kinds of features?).\n\nAny and all pointers would be appreciated.\n\nEDIT: Yes, I have the source file. The platform is FreeBSD 8.0. It's nothing so complicated as a memory leak or anything obscure. It's just a relatively simple program which has begun puking since the the rollover to 2010. The author(s) are long since gone. If I was an experienced C coder, I'd be able to fix this in my sleep. As I'm just an admin with *light* experience in C (CS101 twenty years ago), I need a visual crutch to help me track down and try to fix the bug.\n\nThus far, \"kdbg\" has been the most immediately helpful, as I can easily step along the code and watch all the variables as they change. Eclipse had problems and Netbeans is very slick, though both are sluggish and absolute beasts in terms of system resources (relatively speaking, anyway). What I should be doing is re-learning to code in C while learning one of these two nicer IDEs. Maybe when I have the time.\n\nFINAL EDIT: I've solved the problem. See [here](http://www.reddit.com/r/programming/comments/akvx6/best_linuxunix_way_to_step_through_and_debug_c/c0i4zqk) for my response to a post about the nature of the problem. In the end, I used emacs/gdb and kdbg, the latter being the most useful, while I'm determined to get more versed with the former for future debugging sessions. Thanks for all the suggestions.","preferred_answer":"> something a little more graphical\n\nThis is UNIX, there's [no way](http://en.wikipedia.org/wiki/Data_Display_Debugger) they would have something like that.","full_conversation":[{"role":"OP","user_id":"anon_ceb153b89e40941b","comment_id":"akvx6","kind":"post","text":"Best Linux/UNIX way to step through and debug C program?\n\nDammit, Jim, I'm a sysadmin not a programmer! \n\nSo I've been tasked with debugging this abandoned C program on a server I admin. The last time I did any major screwing around in C, Borland's Turbo C/C++ IDE was fresh and kicked ass. Not only am I woefully rusty in my C, but I'm clueless as to getting a UNIX enviroment/IDE that comes close to the Tubo C IDE I so fondly remember.\n\nI need a way to trace and debug this puppy ASAP. I don't care if it's console mode (any good emacs tutorials out there for this?) or a huge bloated GUI will all the bells and whistles (does Eclipse have these kinds of features?).\n\nAny and all pointers would be appreciated.\n\nEDIT: Yes, I have the source file. The platform is FreeBSD 8.0. It's nothing so complicated as a memory leak or anything obscure. It's just a relatively simple program which has begun puking since the the rollover to 2010. The author(s) are long since gone. If I was an experienced C coder, I'd be able to fix this in my sleep. As I'm just an admin with *light* experience in C (CS101 twenty years ago), I need a visual crutch to help me track down and try to fix the bug.\n\nThus far, \"kdbg\" has been the most immediately helpful, as I can easily step along the code and watch all the variables as they change. Eclipse had problems and Netbeans is very slick, though both are sluggish and absolute beasts in terms of system resources (relatively speaking, anyway). What I should be doing is re-learning to code in C while learning one of these two nicer IDEs. Maybe when I have the time.\n\nFINAL EDIT: I've solved the problem. See [here](http://www.reddit.com/r/programming/comments/akvx6/best_linuxunix_way_to_step_through_and_debug_c/c0i4zqk) for my response to a post about the nature of the problem. In the end, I used emacs/gdb and kdbg, the latter being the most useful, while I'm determined to get more versed with the former for future debugging sessions. Thanks for all the suggestions.","timestamp":"2010-01-02T21:39:02+00:00","score":22},{"role":"answerer","user_id":"anon_59e609d1ff198342","comment_id":"c0i3vd9","kind":"comment","text":"> something a little more graphical\n\nThis is UNIX, there's [no way](http://en.wikipedia.org/wiki/Data_Display_Debugger) they would have something like that.","timestamp":"2010-01-02T22:34:19+00:00","score":10},{"role":"OP","user_id":"anon_ceb153b89e40941b","comment_id":"c0i3vqz","kind":"comment","text":"Thanks! Snarkism aside, your suggestion is a good one. I totally forgot about DDD.","timestamp":"2010-01-02T22:42:47+00:00","score":6},{"role":"answerer","user_id":"anon_59e609d1ff198342","comment_id":"c0i40ix","kind":"comment","text":"I'm really waiting for gdb 7.0 to see wide-spread use, so I can get some decent visualization of STL containers. Once it hits Netbeans I'll be set!","timestamp":"2010-01-03T00:15:15+00:00","score":1}],"n_turns":4,"n_turns_after_thanks":1,"op_metadata":{"user_id":"anon_ceb153b89e40941b","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_59e609d1ff198342","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c0i3vd9","thanks_reply_id":"c0i3vqz","post_score":22,"answer_score":10,"preferred_answer_is_top_level":false}}
{"user_id":"anon_e0fc7c1789328719","answerer_user_id":"anon_a8736eddc612e67b","subreddit":"programming","timestamp":"2010-01-04T17:17:26+00:00","post_id":"alg09","question":"Has anyone successfully used Redditjobs to find a job / place a candidate?\n\nIt's 300 bucks to post a job here, and I can't justify such an untested search method to my boss for that price. Anyone here experience or hear of any success?","preferred_answer":"Seems like this is a trend that Joel Spolsky popularized in some articles he wrote about his own job board - charge a high price to make the customers value the board more, basically. Here's [one such article](http://www.joelonsoftware.com/items/2006/09/05b.html), although I think the one I'm thinking of was a later analysis of the approach.","full_conversation":[{"role":"OP","user_id":"anon_e0fc7c1789328719","comment_id":"alg09","kind":"post","text":"Has anyone successfully used Redditjobs to find a job / place a candidate?\n\nIt's 300 bucks to post a job here, and I can't justify such an untested search method to my boss for that price. Anyone here experience or hear of any success?","timestamp":"2010-01-04T17:17:26+00:00","score":49},{"role":"answerer","user_id":"anon_a8736eddc612e67b","comment_id":"c0i73hq","kind":"comment","text":"Seems like this is a trend that Joel Spolsky popularized in some articles he wrote about his own job board - charge a high price to make the customers value the board more, basically. Here's [one such article](http://www.joelonsoftware.com/items/2006/09/05b.html), although I think the one I'm thinking of was a later analysis of the approach.","timestamp":"2010-01-04T17:54:02+00:00","score":4},{"role":"OP","user_id":"anon_e0fc7c1789328719","comment_id":"c0i79l9","kind":"comment","text":"Great link. Thanks!","timestamp":"2010-01-04T19:28:46+00:00","score":2},{"role":"answerer","user_id":"anon_a8736eddc612e67b","comment_id":"c0i9kbj","kind":"comment","text":"The actual article I was thinking of was [this one](http://www.inc.com/magazine/20090101/how-hard-could-it-be-thanks-or-no-thanks.html):\n\n> Little gears were turning in my head: $250 times 50 ads times 12 months -- that revenue would allow me to hire another programmer! So we added classified ads to the site. Noah wrote the first draft of the code in about two weeks, and I spent another two weeks polishing and debugging it. The total time to build the job listing service was roughly a month.\n\n> Instead of charging the going rate of $250, we decided to charge $350. Why not? I figured we could establish ourselves as having the premium product simply by charging a premium. In the absence of additional information, consumers often use prices to judge products, and I wanted our site to be the Lexus of job listings. A few months later, 37signals raised its price to $300.\n\n> By the time you read this, that little four-week project will have made Fog Creek Software $1 million -- nearly all of it profit.","timestamp":"2010-01-05T21:51:41+00:00","score":1}],"n_turns":4,"n_turns_after_thanks":1,"op_metadata":{"user_id":"anon_e0fc7c1789328719","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_a8736eddc612e67b","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c0i73hq","thanks_reply_id":"c0i79l9","post_score":49,"answer_score":4,"preferred_answer_is_top_level":true}}
{"user_id":"anon_35df3774761b5adf","answerer_user_id":"anon_72fe6b5a4b2a0958","subreddit":"programming","timestamp":"2010-01-04T18:18:57+00:00","post_id":"algs4","question":"Ask Proggit: does anyone else hate using the arrow keys in Google Chrome's Ominbox (address bar)?\n\nI like Google Chrome for a number of reasons, but I don't like using the arrow keys to complete URLs because I have to take my hand off of the home row. I much prefer Firefox's use of the Tab key for completion. Is there any Chrome extension (or setting I am missing) that fixes this? I am aware of other keyboard-centric browsers like Conkeror and Vimperator. I just wanted to be sure to give Google Chrome a fair chance because it is a larger player.","preferred_answer":"I don't know if this helps, but I use gtk Emacs keybinding. That means I can C-n C-p in the location bar. Of course you also get char/word movement which is nice.\n\n cat ~/.gtkrc-2.0 \n gtk-key-theme-name = \"Emacs\"\n\nI'm still waiting for some chrome extension like [firemacs](https://addons.mozilla.org/firefox/addon/4141) though.","full_conversation":[{"role":"OP","user_id":"anon_35df3774761b5adf","comment_id":"algs4","kind":"post","text":"Ask Proggit: does anyone else hate using the arrow keys in Google Chrome's Ominbox (address bar)?\n\nI like Google Chrome for a number of reasons, but I don't like using the arrow keys to complete URLs because I have to take my hand off of the home row. I much prefer Firefox's use of the Tab key for completion. Is there any Chrome extension (or setting I am missing) that fixes this? I am aware of other keyboard-centric browsers like Conkeror and Vimperator. I just wanted to be sure to give Google Chrome a fair chance because it is a larger player.","timestamp":"2010-01-04T18:18:57+00:00","score":0},{"role":"answerer","user_id":"anon_72fe6b5a4b2a0958","comment_id":"c0ic5ef","kind":"comment","text":"I don't know if this helps, but I use gtk Emacs keybinding. That means I can C-n C-p in the location bar. Of course you also get char/word movement which is nice.\n\n cat ~/.gtkrc-2.0 \n gtk-key-theme-name = \"Emacs\"\n\nI'm still waiting for some chrome extension like [firemacs](https://addons.mozilla.org/firefox/addon/4141) though.","timestamp":"2010-01-07T02:06:27+00:00","score":2},{"role":"OP","user_id":"anon_35df3774761b5adf","comment_id":"c0ich7r","kind":"comment","text":"Thank you, that does help. I had forgotten about this. I had set up my ~/.gtkrc-2.0 to use emacs keybindings for Firefox but, for some reason, it doesn't work with my Chrome setup. I will look into fixing this. It helps knowing that it works for you.","timestamp":"2010-01-07T05:22:14+00:00","score":1},{"role":"answerer","user_id":"anon_72fe6b5a4b2a0958","comment_id":"c0icu6u","kind":"comment","text":"IIRC there was a bug in earlier chromium versions where it didn't honor the gtk key themes. Maybe updating chromium fixes your problem.","timestamp":"2010-01-07T13:28:17+00:00","score":1},{"role":"OP","user_id":"anon_35df3774761b5adf","comment_id":"c0id7fd","kind":"comment","text":"My bad, it was actually working-- I just hadn't set up all the bindings correctly. Thanks!","timestamp":"2010-01-07T17:12:30+00:00","score":1}],"n_turns":5,"n_turns_after_thanks":2,"op_metadata":{"user_id":"anon_35df3774761b5adf","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_72fe6b5a4b2a0958","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c0ic5ef","thanks_reply_id":"c0ich7r","post_score":0,"answer_score":2,"preferred_answer_is_top_level":true}}
{"user_id":"anon_6298ae34dee4ac30","answerer_user_id":"anon_d029fff69c16da36","subreddit":"programming","timestamp":"2010-01-06T06:58:40+00:00","post_id":"am46a","question":"Accounting for Real People when doing Software Project Planning - How?\n\nHow do we account for the fact we have real people working on software projects when doing project planning?\n\nLet's say I know all the items in my project scope, who will do each of them and how long in pure ideal effort (person-days) each will take. I have made sure to include everyone in their own estimates.\n\nYet Real people are not Ideal people. So I need to introduce some multipliers of the ideal effort in days to account for things like:\n\n* natural capacity of the person for the task\n\n* people are going to get sick or go on vacation\n\n* people are going to have personal problems that affect them\n\n* we need time to test the project as well after the people think they are finished\n\n* the people will have to talk and discuss problems together creating unforeseen overhead\n\n* the production system will die and use up most of your resources for a few days\n\n\nI'm thinking of having a global 40% multiplier.\nBut that may lead to over-estimation.\n\nHow do all you project planners account for this?","preferred_answer":"You've asked a difficult question.\n\nFirst, I refer you to McConnell's *Software Estimation: Demystifying the Black Art* for a general overview of estimation.\n\nThe key is that you need historical data to be able to model the impact of individuals, rates of sick leave, time-to-test and like. Failing that you will need to rely on industry averages, such as those available from [ISBG](http://www.isbsg.org/) and others.\n\nWhat information are you storing now? Do you track time spent per-task, or just flat timesheets for the accounting department?\n\nIn this vein I refer you to Humphrey's *A Discipline for Software Engineering*. It proposes a \"Personal Software Process\" that requires buckets of paperwork, but from it you can extract the idea that each programmer should be tracking metrics on themselves. They themselves should be aware of their productivity, quality etc so that they can improve it and use that to moderate their estimates.\n\nBut really, your estimates will have poor confidence unless and until you have gathered a solid body of historical data to work with.","full_conversation":[{"role":"OP","user_id":"anon_6298ae34dee4ac30","comment_id":"am46a","kind":"post","text":"Accounting for Real People when doing Software Project Planning - How?\n\nHow do we account for the fact we have real people working on software projects when doing project planning?\n\nLet's say I know all the items in my project scope, who will do each of them and how long in pure ideal effort (person-days) each will take. I have made sure to include everyone in their own estimates.\n\nYet Real people are not Ideal people. So I need to introduce some multipliers of the ideal effort in days to account for things like:\n\n* natural capacity of the person for the task\n\n* people are going to get sick or go on vacation\n\n* people are going to have personal problems that affect them\n\n* we need time to test the project as well after the people think they are finished\n\n* the people will have to talk and discuss problems together creating unforeseen overhead\n\n* the production system will die and use up most of your resources for a few days\n\n\nI'm thinking of having a global 40% multiplier.\nBut that may lead to over-estimation.\n\nHow do all you project planners account for this?","timestamp":"2010-01-06T06:58:40+00:00","score":4},{"role":"answerer","user_id":"anon_d029fff69c16da36","comment_id":"c0iallg","kind":"comment","text":"You've asked a difficult question.\n\nFirst, I refer you to McConnell's *Software Estimation: Demystifying the Black Art* for a general overview of estimation.\n\nThe key is that you need historical data to be able to model the impact of individuals, rates of sick leave, time-to-test and like. Failing that you will need to rely on industry averages, such as those available from [ISBG](http://www.isbsg.org/) and others.\n\nWhat information are you storing now? Do you track time spent per-task, or just flat timesheets for the accounting department?\n\nIn this vein I refer you to Humphrey's *A Discipline for Software Engineering*. It proposes a \"Personal Software Process\" that requires buckets of paperwork, but from it you can extract the idea that each programmer should be tracking metrics on themselves. They themselves should be aware of their productivity, quality etc so that they can improve it and use that to moderate their estimates.\n\nBut really, your estimates will have poor confidence unless and until you have gathered a solid body of historical data to work with.","timestamp":"2010-01-06T09:22:01+00:00","score":2},{"role":"OP","user_id":"anon_6298ae34dee4ac30","comment_id":"c0iamto","kind":"comment","text":"Thanks for the help. Historical data is non existent here.\nBummer. I've gone witha 35% multiplier.","timestamp":"2010-01-06T10:04:52+00:00","score":2},{"role":"answerer","user_id":"anon_d029fff69c16da36","comment_id":"c0iaqbj","kind":"comment","text":"To improve your estimates, perform at least a PERT estimate and/or a Delphi Wideband estimate. Both of these rely on you integrating estimates given by your team members.\n\nThe Delphi method involves multiple rounds of estimation with the aim of converging on a consensus estimate. Delphi \"wideband\" means you're doing using the Delphi method to estimate best, likely and worst cases.\n\nPERT involves a single round of estimates which are integrated using simple statistics. Out of the method falls a best, most likely and worst case scenarios. It also supplies a \"95% confidence\" date; ie a schedule date where your project has a 19/20 chance of delivering before.","timestamp":"2010-01-06T12:29:58+00:00","score":1}],"n_turns":4,"n_turns_after_thanks":1,"op_metadata":{"user_id":"anon_6298ae34dee4ac30","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_d029fff69c16da36","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c0iallg","thanks_reply_id":"c0iamto","post_score":4,"answer_score":2,"preferred_answer_is_top_level":true}}
{"user_id":"anon_56625a4d62d23464","answerer_user_id":"anon_6efaa115ba60d4e2","subreddit":"programming","timestamp":"2010-01-08T01:52:45+00:00","post_id":"amxzh","question":"Ask proggit: Looking for a good LCD for \r\nprogramming. Preferably under $200. What's your \r\nrecommendation, and do you prefer widescreen or \r\nnon-wide?","preferred_answer":"Read my post below about the Dell, read the reviews on it, then look at the price tag.","full_conversation":[{"role":"OP","user_id":"anon_56625a4d62d23464","comment_id":"amxzh","kind":"post","text":"Ask proggit: Looking for a good LCD for \r\nprogramming. Preferably under $200. What's your \r\nrecommendation, and do you prefer widescreen or \r\nnon-wide?","timestamp":"2010-01-08T01:52:45+00:00","score":12},{"role":"answerer","user_id":"anon_6efaa115ba60d4e2","comment_id":"c0if99g","kind":"comment","text":"Read my post below about the Dell, read the reviews on it, then look at the price tag.","timestamp":"2010-01-08T15:17:06+00:00","score":1},{"role":"OP","user_id":"anon_56625a4d62d23464","comment_id":"c0if9vg","kind":"comment","text":"Looks nice! Thanks for pointing it out.\r\n\r\nI was reading a review or two on Amazon that worried me, though. One person said that at the native res (1920 x 1080) \"makes text too small for comfortable reading.\" Would you say this is accurate? How's the size of text compared to your usual monitor res on other monitors?\r\n\r\nAnother person said \"this monitor has an absolutely terrible vertical viewing angle. Colors are displayed completely inaccurately if you're looking at the monitor at any angle other than directly head on.\" How's the vertical viewing angle in your opinion?","timestamp":"2010-01-08T15:26:55+00:00","score":1},{"role":"answerer","user_id":"anon_6efaa115ba60d4e2","comment_id":"c0igf7u","kind":"comment","text":"No, I can read text just fine on it. I really don't have any complaints about it.","timestamp":"2010-01-09T00:52:01+00:00","score":1}],"n_turns":4,"n_turns_after_thanks":1,"op_metadata":{"user_id":"anon_56625a4d62d23464","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_6efaa115ba60d4e2","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c0if99g","thanks_reply_id":"c0if9vg","post_score":12,"answer_score":1,"preferred_answer_is_top_level":false}}
{"user_id":"anon_0101f9090d45368d","answerer_user_id":"anon_5568abb1c5cb7566","subreddit":"programming","timestamp":"2010-01-11T05:44:21+00:00","post_id":"ao1wq","question":"Hey Reddit Web Programmers! How do I open several links on one page?","preferred_answer":"[This is what you're looking for.](https://addons.mozilla.org/en-US/firefox/addon/4336)","full_conversation":[{"role":"OP","user_id":"anon_0101f9090d45368d","comment_id":"ao1wq","kind":"post","text":"Hey Reddit Web Programmers! How do I open several links on one page?","timestamp":"2010-01-11T05:44:21+00:00","score":0},{"role":"answerer","user_id":"anon_5568abb1c5cb7566","comment_id":"c0ikds2","kind":"comment","text":"[This is what you're looking for.](https://addons.mozilla.org/en-US/firefox/addon/4336)","timestamp":"2010-01-11T05:49:46+00:00","score":1},{"role":"OP","user_id":"anon_0101f9090d45368d","comment_id":"c0ikehn","kind":"comment","text":"It says the addon is for older versions of firefox but thanks, I didn't know something like that existed.","timestamp":"2010-01-11T06:03:54+00:00","score":1},{"role":"answerer","user_id":"anon_5568abb1c5cb7566","comment_id":"c0ikf00","kind":"comment","text":"[This](http://www.jamesvandyke.com/2008/01/23/turn-off-add-on-compatibility-check-in-firefox-3-beta/)","timestamp":"2010-01-11T06:14:35+00:00","score":1}],"n_turns":4,"n_turns_after_thanks":1,"op_metadata":{"user_id":"anon_0101f9090d45368d","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_5568abb1c5cb7566","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c0ikds2","thanks_reply_id":"c0ikehn","post_score":0,"answer_score":1,"preferred_answer_is_top_level":true}}
{"user_id":"anon_244471fc15c763d1","answerer_user_id":"anon_bb98bd3b14d6894d","subreddit":"programming","timestamp":"2010-01-11T08:03:07+00:00","post_id":"ao3gp","question":"Best way to store and access over 100k small images in a windows environment?\n\nI've got 100s of thousands of images (about 25kb each). Currently they're in about 50 separate directories to ease the strain on Windows having to open them. \n\nWhat's a good way of storing these images such that I can access and display one of them at a time from within a C++ or Matlab gui?\n\n**Edit: Thanks for the input guys, I'd never have suspected zipping could help!!**","preferred_answer":"I wouldn't use Oracle. I'd go for something like [SQLite](http://www.sqlite.org/). Effectively SQLite is a free C library that gives you access to an SQL database. You create a DB either with the CLI tool that comes with it or via a C/C++ call. Then you can load your image files in as binary blobs (the datatype is literally called blob. A type that stores binary data exactly as you put it in).\n\nJust load the file into memory and dump it into a blob. To retrieve you load the blob back into memory as you would a file. That data can then be passed into whatever drawing function handles your images. If you have any meta-data (filenames or tags or whatever you feel like) you can create a record holding it and use that to search the DB. This will be simpler and potentially faster than searching a zip.\n\nI'm assuming Matlab can call C functions? If it can then it can integrate to SQLite directly.","full_conversation":[{"role":"OP","user_id":"anon_244471fc15c763d1","comment_id":"ao3gp","kind":"post","text":"Best way to store and access over 100k small images in a windows environment?\n\nI've got 100s of thousands of images (about 25kb each). Currently they're in about 50 separate directories to ease the strain on Windows having to open them. \n\nWhat's a good way of storing these images such that I can access and display one of them at a time from within a C++ or Matlab gui?\n\n**Edit: Thanks for the input guys, I'd never have suspected zipping could help!!**","timestamp":"2010-01-11T08:03:07+00:00","score":0},{"role":"answerer","user_id":"anon_bb98bd3b14d6894d","comment_id":"c0il1bn","kind":"comment","text":"I wouldn't use Oracle. I'd go for something like [SQLite](http://www.sqlite.org/). Effectively SQLite is a free C library that gives you access to an SQL database. You create a DB either with the CLI tool that comes with it or via a C/C++ call. Then you can load your image files in as binary blobs (the datatype is literally called blob. A type that stores binary data exactly as you put it in).\n\nJust load the file into memory and dump it into a blob. To retrieve you load the blob back into memory as you would a file. That data can then be passed into whatever drawing function handles your images. If you have any meta-data (filenames or tags or whatever you feel like) you can create a record holding it and use that to search the DB. This will be simpler and potentially faster than searching a zip.\n\nI'm assuming Matlab can call C functions? If it can then it can integrate to SQLite directly.","timestamp":"2010-01-11T16:33:29+00:00","score":2},{"role":"OP","user_id":"anon_244471fc15c763d1","comment_id":"c0il2b4","kind":"comment","text":"Awesome, I'll read up on some SQL then :) Thanks very much for the detailed reply, it gives me somewhere to start researching.","timestamp":"2010-01-11T16:49:43+00:00","score":1},{"role":"answerer","user_id":"anon_bb98bd3b14d6894d","comment_id":"c0il2nh","kind":"comment","text":"To get the most basic needs you effectively want to index on the path name of the file. This will give you fast look up for your images.","timestamp":"2010-01-11T16:55:05+00:00","score":1}],"n_turns":4,"n_turns_after_thanks":1,"op_metadata":{"user_id":"anon_244471fc15c763d1","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_bb98bd3b14d6894d","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c0il1bn","thanks_reply_id":"c0il2b4","post_score":0,"answer_score":2,"preferred_answer_is_top_level":false}}
{"user_id":"anon_5c19b1eeab66c98a","answerer_user_id":"anon_e84712238709398f","subreddit":"programming","timestamp":"2010-01-13T07:45:59+00:00","post_id":"ap033","question":"Dear Proggit, how do you handle SQL exceptions?\n\nI am working on a project and I want to know what a good approach would be to handle SQL exceptions. \n\nA simple example would be if you try to add a user to a database but that user already exists. Do you check if that user name exists before hand, or do you wait for an exception and handle it that way?\n\nSidenote: I am using the Kohana (php) framework. Maybe they have exception tools I'm not aware of.","preferred_answer":"There are a couple of ways to do handle your duplicate user example:\n\n1. You can accept the POST data, perform your query, and display an error message when the page renders if there is a duplicate user. It's generally a good idea to re-populate most of the fields with the POST'd data.\n\n2. You can use AJAX so that when the user blurs the username field (or clicks a \"Check availability\" button), a separate http request is launched that takes the username field and checks it against the database, returning wether or not the username exists.\n\n3. More generally (although PHP specific), you could register a [separate error handler](http://www.alexatnet.com/node/23), so that any SQL (and PHP) errors are automatically converted to exceptions. Then register a top-level exception handler with [set\\_exception\\_handler()](http://php.net/manual/en/function.set-exception-handler.php) and then have the site e-mail you with the details of the uncaught exception and render a nice error-page for the user.\n\nI haven't used kohana, so I can't help you there. In summary, the first two points address how to handle errors you are anticipating, while the third is a pretty solid way to handle any exceptions/errors that you are not.","full_conversation":[{"role":"OP","user_id":"anon_5c19b1eeab66c98a","comment_id":"ap033","kind":"post","text":"Dear Proggit, how do you handle SQL exceptions?\n\nI am working on a project and I want to know what a good approach would be to handle SQL exceptions. \n\nA simple example would be if you try to add a user to a database but that user already exists. Do you check if that user name exists before hand, or do you wait for an exception and handle it that way?\n\nSidenote: I am using the Kohana (php) framework. Maybe they have exception tools I'm not aware of.","timestamp":"2010-01-13T07:45:59+00:00","score":0},{"role":"answerer","user_id":"anon_e84712238709398f","comment_id":"c0iompq","kind":"comment","text":"There are a couple of ways to do handle your duplicate user example:\n\n1. You can accept the POST data, perform your query, and display an error message when the page renders if there is a duplicate user. It's generally a good idea to re-populate most of the fields with the POST'd data.\n\n2. You can use AJAX so that when the user blurs the username field (or clicks a \"Check availability\" button), a separate http request is launched that takes the username field and checks it against the database, returning wether or not the username exists.\n\n3. More generally (although PHP specific), you could register a [separate error handler](http://www.alexatnet.com/node/23), so that any SQL (and PHP) errors are automatically converted to exceptions. Then register a top-level exception handler with [set\\_exception\\_handler()](http://php.net/manual/en/function.set-exception-handler.php) and then have the site e-mail you with the details of the uncaught exception and render a nice error-page for the user.\n\nI haven't used kohana, so I can't help you there. In summary, the first two points address how to handle errors you are anticipating, while the third is a pretty solid way to handle any exceptions/errors that you are not.","timestamp":"2010-01-13T08:58:59+00:00","score":2},{"role":"OP","user_id":"anon_5c19b1eeab66c98a","comment_id":"c0ipv4i","kind":"comment","text":"Thank you for the advice","timestamp":"2010-01-13T23:07:21+00:00","score":2},{"role":"answerer","user_id":"anon_e84712238709398f","comment_id":"c0ipwql","kind":"comment","text":"No problem. FWIW, I don't know why this submission received the downvotes that it did. Perhaps proggit is just *that* anti-PHP.","timestamp":"2010-01-13T23:30:48+00:00","score":2}],"n_turns":4,"n_turns_after_thanks":1,"op_metadata":{"user_id":"anon_5c19b1eeab66c98a","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_e84712238709398f","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c0iompq","thanks_reply_id":"c0ipv4i","post_score":0,"answer_score":2,"preferred_answer_is_top_level":true}}
{"user_id":"anon_80d1f194138ba209","answerer_user_id":"anon_3792ba89ca0cfa21","subreddit":"programming","timestamp":"2010-01-13T21:57:32+00:00","post_id":"apab4","question":"Can someone help me find a link to the javascript framework that had 3d graphs?\n\nSomething like 3-6 months ago there was a web site that had 3d wireframe graphs that you could drag to spin, graphs you could zoom in and out on, or drag around. It was on a blue background, and I remember the presentation talking about their choice to use Canvas rather than SVG.\n\nCan anyone help me find that framework again?","preferred_answer":"I think you might be thinking of http://www.ajax.org.","full_conversation":[{"role":"OP","user_id":"anon_80d1f194138ba209","comment_id":"apab4","kind":"post","text":"Can someone help me find a link to the javascript framework that had 3d graphs?\n\nSomething like 3-6 months ago there was a web site that had 3d wireframe graphs that you could drag to spin, graphs you could zoom in and out on, or drag around. It was on a blue background, and I remember the presentation talking about their choice to use Canvas rather than SVG.\n\nCan anyone help me find that framework again?","timestamp":"2010-01-13T21:57:32+00:00","score":0},{"role":"answerer","user_id":"anon_3792ba89ca0cfa21","comment_id":"c0iprqr","kind":"comment","text":"I think you might be thinking of http://www.ajax.org.","timestamp":"2010-01-13T22:24:43+00:00","score":2},{"role":"OP","user_id":"anon_80d1f194138ba209","comment_id":"c0iptjj","kind":"comment","text":"Wow, that is exactly what I was thinking of, thanks! They really need to work on their SEO as I spent about half an hour googling combinations of the keywords ajax, javascript, framework, 3d, chart, and canvas without finding this site.","timestamp":"2010-01-13T22:46:54+00:00","score":1},{"role":"answerer","user_id":"anon_3792ba89ca0cfa21","comment_id":"c0ipu8j","kind":"comment","text":"[Try this](http://www.google.com/search?hl=en&client=opera&rls=en&hs=2cC&q=javascript+3d+chart+site%3Areddit.com&aq=f&oq=&aqi=)","timestamp":"2010-01-13T22:55:20+00:00","score":1}],"n_turns":4,"n_turns_after_thanks":1,"op_metadata":{"user_id":"anon_80d1f194138ba209","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_3792ba89ca0cfa21","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c0iprqr","thanks_reply_id":"c0iptjj","post_score":0,"answer_score":2,"preferred_answer_is_top_level":true}}
{"user_id":"anon_61009d3b1e7790ce","answerer_user_id":"anon_2d3942044e8647a6","subreddit":"programming","timestamp":"2010-01-14T16:41:26+00:00","post_id":"apm5p","question":"What is the correct way to calculate the contrast between two colours?\n\nHere's the problem I'm trying to solve: Given an RGB triplet and an assumption that we're talking about the sRGB colour space, how can I calculate a shade of that colour that appears to be as dark compared to the original colour as, say, 90% white looks compared to 100% white? I don't need to solve for colours very close to black, so I can assume a minimum apparent brightness. I'm also assuming that if I can calculate the contrast between two colours, I can solve for the second colour using constraints on hue and saturation.\n\nI've tried converting to the HSL colour space, reducing L by a fixed number (or multiplying by a fixed factor), but I end up with inconsistent contrasts. In particular, I can't distinguish between HSL (60°, 100%, 60%) and HSL (60°, 100%, 50%), while HSL (60°, 100%, 50%) and HSL (60°, 100%, 40%) are clear as night and day. For most other hues and saturations, the contrast between 60 and 50 is just fine.\n\nI'm guessing I'm working in the wrong colour space, but I'm fairly naïve about perception of colour. Can anyone point me in the right direction?\n\n**EDIT:** [NotAbel](http://www.reddit.com/r/programming/comments/apm5p/what_is_the_correct_way_to_calculate_the_contrast/c0ir9ch) gave me the answer I was looking for, so here's my Javascript implementation of the colour space conversions for anyone looking to do the same. RGB is assumed to be sRGB normalized to the range \\[0,1\\]. Formulae for [sRGB to XYZ](http://en.wikipedia.org/wiki/SRGB#The_reverse_transformation) and [XYZ to L\\*a\\*b\\*](http://en.wikipedia.org/wiki/Lab_color_space#The_forward_transformation) were both sourced from Wikipedia. Also, here's an [image of the results](http://i.imgur.com/XZDDx.png) with darkened/lightened colour inside the background colour.\n\n function rgbToXYZ (rgb) {\n var r = rgb.r, g = rgb.g, b = rgb.b;\n function fXYZ (t) {\n return t <= 0.04045 ? t/12.92 : Math.pow((t+0.055)/1.055,2.4);\n }\n r = fXYZ(r);\n g = fXYZ(g);\n b = fXYZ(b);\n var x = 0.4124*r + 0.3576*g + 0.1805*b;\n var y = 0.2126*r + 0.7152*g + 0.0722*b;\n var z = 0.0193*r + 0.1192*g + 0.9505*b;\n \n return { x: x, y: y, z: z };\n }\n \n function xyzToRGB (xyz) {\n var x = xyz.x, y = xyz.y, z = xyz.z;\n var r = 3.2410*x - 1.5374*y - 0.4986*z;\n var g = -0.9692*x + 1.8760*y + 0.0416*z;\n var b = 0.0556*x - 0.2040*y + 1.0570*z;\n function fXYZ (t) {\n return t <= 0.0031308 ? 12.92*t : (1+0.055)*Math.pow(t,1/2.4) - 0.055;\n }\n r = fXYZ(r);\n g = fXYZ(g);\n b = fXYZ(b);\n r = r < 0 ? 0 : r > 1 ? 1 : r;\n g = g < 0 ? 0 : g > 1 ? 1 : g;\n b = b < 0 ? 0 : b > 1 ? 1 : b;\n return { r: r, g: g, b: b };\n }\n \n function xyzToLab (xyz) {\n var x = xyz.x, y = xyz.y, z = xyz.z;\n function fLab (t) {\n return t > 0.00886 ? Math.pow(t,1/3) : 7.787*t + 4/29;\n }\n var L = 116 * fLab(y) - 16;\n var a = 500 * (fLab(x) - fLab(y));\n var b = 200 * (fLab(y) - fLab(z));\n return { L: L, a: a, b: b };\n }\n \n function LabToXYZ (lab) {\n var L = lab.L, a = lab.a, b = lab.b;\n var y = (L + 16) / 116;\n var x = y + a / 500;\n var z = y - b / 200;\n function fLab (t) {\n return t > 0.2069 ? Math.pow(t,3) : (t - 16/116)*0.1284;\n }\n y = fLab(y);\n x = fLab(x);\n z = fLab(z);\n return { x: x, y: y, z: z };\n }","preferred_answer":"To expand a little, your flow is going to be kind of like this:\n\n> sRBG -> XYZ (This puts you in the device-independent tristimulus space. Don't worry too much about white points or the vagaries of chromatic adaptation.)\n\n> XYZ -> L\\*C\\*H\\* (This puts you in a device-independent luminance/chroma/hue space.)\n\n> Swizzle L\\* however you want.\n\n> XYZ -> L\\*C\\*H\\* -> sRGB (Gets you back to device-dependent rgb.)","full_conversation":[{"role":"OP","user_id":"anon_61009d3b1e7790ce","comment_id":"apm5p","kind":"post","text":"What is the correct way to calculate the contrast between two colours?\n\nHere's the problem I'm trying to solve: Given an RGB triplet and an assumption that we're talking about the sRGB colour space, how can I calculate a shade of that colour that appears to be as dark compared to the original colour as, say, 90% white looks compared to 100% white? I don't need to solve for colours very close to black, so I can assume a minimum apparent brightness. I'm also assuming that if I can calculate the contrast between two colours, I can solve for the second colour using constraints on hue and saturation.\n\nI've tried converting to the HSL colour space, reducing L by a fixed number (or multiplying by a fixed factor), but I end up with inconsistent contrasts. In particular, I can't distinguish between HSL (60°, 100%, 60%) and HSL (60°, 100%, 50%), while HSL (60°, 100%, 50%) and HSL (60°, 100%, 40%) are clear as night and day. For most other hues and saturations, the contrast between 60 and 50 is just fine.\n\nI'm guessing I'm working in the wrong colour space, but I'm fairly naïve about perception of colour. Can anyone point me in the right direction?\n\n**EDIT:** [NotAbel](http://www.reddit.com/r/programming/comments/apm5p/what_is_the_correct_way_to_calculate_the_contrast/c0ir9ch) gave me the answer I was looking for, so here's my Javascript implementation of the colour space conversions for anyone looking to do the same. RGB is assumed to be sRGB normalized to the range \\[0,1\\]. Formulae for [sRGB to XYZ](http://en.wikipedia.org/wiki/SRGB#The_reverse_transformation) and [XYZ to L\\*a\\*b\\*](http://en.wikipedia.org/wiki/Lab_color_space#The_forward_transformation) were both sourced from Wikipedia. Also, here's an [image of the results](http://i.imgur.com/XZDDx.png) with darkened/lightened colour inside the background colour.\n\n function rgbToXYZ (rgb) {\n var r = rgb.r, g = rgb.g, b = rgb.b;\n function fXYZ (t) {\n return t <= 0.04045 ? t/12.92 : Math.pow((t+0.055)/1.055,2.4);\n }\n r = fXYZ(r);\n g = fXYZ(g);\n b = fXYZ(b);\n var x = 0.4124*r + 0.3576*g + 0.1805*b;\n var y = 0.2126*r + 0.7152*g + 0.0722*b;\n var z = 0.0193*r + 0.1192*g + 0.9505*b;\n \n return { x: x, y: y, z: z };\n }\n \n function xyzToRGB (xyz) {\n var x = xyz.x, y = xyz.y, z = xyz.z;\n var r = 3.2410*x - 1.5374*y - 0.4986*z;\n var g = -0.9692*x + 1.8760*y + 0.0416*z;\n var b = 0.0556*x - 0.2040*y + 1.0570*z;\n function fXYZ (t) {\n return t <= 0.0031308 ? 12.92*t : (1+0.055)*Math.pow(t,1/2.4) - 0.055;\n }\n r = fXYZ(r);\n g = fXYZ(g);\n b = fXYZ(b);\n r = r < 0 ? 0 : r > 1 ? 1 : r;\n g = g < 0 ? 0 : g > 1 ? 1 : g;\n b = b < 0 ? 0 : b > 1 ? 1 : b;\n return { r: r, g: g, b: b };\n }\n \n function xyzToLab (xyz) {\n var x = xyz.x, y = xyz.y, z = xyz.z;\n function fLab (t) {\n return t > 0.00886 ? Math.pow(t,1/3) : 7.787*t + 4/29;\n }\n var L = 116 * fLab(y) - 16;\n var a = 500 * (fLab(x) - fLab(y));\n var b = 200 * (fLab(y) - fLab(z));\n return { L: L, a: a, b: b };\n }\n \n function LabToXYZ (lab) {\n var L = lab.L, a = lab.a, b = lab.b;\n var y = (L + 16) / 116;\n var x = y + a / 500;\n var z = y - b / 200;\n function fLab (t) {\n return t > 0.2069 ? Math.pow(t,3) : (t - 16/116)*0.1284;\n }\n y = fLab(y);\n x = fLab(x);\n z = fLab(z);\n return { x: x, y: y, z: z };\n }","timestamp":"2010-01-14T16:41:26+00:00","score":41},{"role":"answerer","user_id":"anon_2d3942044e8647a6","comment_id":"c0ir9np","kind":"comment","text":"To expand a little, your flow is going to be kind of like this:\n\n> sRBG -> XYZ (This puts you in the device-independent tristimulus space. Don't worry too much about white points or the vagaries of chromatic adaptation.)\n\n> XYZ -> L\\*C\\*H\\* (This puts you in a device-independent luminance/chroma/hue space.)\n\n> Swizzle L\\* however you want.\n\n> XYZ -> L\\*C\\*H\\* -> sRGB (Gets you back to device-dependent rgb.)","timestamp":"2010-01-14T17:07:07+00:00","score":14},{"role":"OP","user_id":"anon_61009d3b1e7790ce","comment_id":"c0irj9d","kind":"comment","text":"Thanks, this was exactly what I was looking for. I just finished implementing it and the results look great.","timestamp":"2010-01-14T19:13:44+00:00","score":5},{"role":"answerer","user_id":"anon_2d3942044e8647a6","comment_id":"c0irjlz","kind":"comment","text":"Glad to help :-)","timestamp":"2010-01-14T19:18:00+00:00","score":5}],"n_turns":4,"n_turns_after_thanks":1,"op_metadata":{"user_id":"anon_61009d3b1e7790ce","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_2d3942044e8647a6","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c0ir9np","thanks_reply_id":"c0irj9d","post_score":41,"answer_score":14,"preferred_answer_is_top_level":false}}
{"user_id":"anon_72dca4a8c8dcf717","answerer_user_id":"anon_2116bc2ede454bff","subreddit":"programming","timestamp":"2010-01-18T00:57:44+00:00","post_id":"aqsxq","question":"Does anyone actually use GWT?\n\nJust curious, some of the Java gurus at work are raving about the awesomeness of GWT and how it gets rid of all your cross-browser incompatibilities. After taking a cursory glance, I can only conclude that this is only true if you stay within the GWT box, the second you need to create a non-standard widget, or write a javascript extension, you'll be dealing with cross-browser issues and have an extra layer of abstraction to deal with to boot. Am I wrong?","preferred_answer":"I work on the Wave team.\n\n1. We get static typing, which is a boost to reliability.\n2. We can write unit tests for client code without WebDriver, using GWT's dom simulation\n3. We can use the Java debugger with our code *running inside the browser* using the OOPHM plugin\n4. We can share vast amounts of model code between client and server\n\nThe list of GWT's advantages go on and on","full_conversation":[{"role":"OP","user_id":"anon_72dca4a8c8dcf717","comment_id":"aqsxq","kind":"post","text":"Does anyone actually use GWT?\n\nJust curious, some of the Java gurus at work are raving about the awesomeness of GWT and how it gets rid of all your cross-browser incompatibilities. After taking a cursory glance, I can only conclude that this is only true if you stay within the GWT box, the second you need to create a non-standard widget, or write a javascript extension, you'll be dealing with cross-browser issues and have an extra layer of abstraction to deal with to boot. Am I wrong?","timestamp":"2010-01-18T00:57:44+00:00","score":54},{"role":"answerer","user_id":"anon_2116bc2ede454bff","comment_id":"c0ixt2k","kind":"comment","text":"I work on the Wave team.\n\n1. We get static typing, which is a boost to reliability.\n2. We can write unit tests for client code without WebDriver, using GWT's dom simulation\n3. We can use the Java debugger with our code *running inside the browser* using the OOPHM plugin\n4. We can share vast amounts of model code between client and server\n\nThe list of GWT's advantages go on and on","timestamp":"2010-01-18T05:39:48+00:00","score":54},{"role":"OP","user_id":"anon_72dca4a8c8dcf717","comment_id":"c0ixtjl","kind":"comment","text":"Cool, thanks for replying. I'm very curious as to how or if GWT is embraced by both Google and non-Google companies. Is GWT used heavily internally, or only for a minority of projects? Do you really think it's the future, and why?","timestamp":"2010-01-18T05:48:35+00:00","score":6},{"role":"answerer","user_id":"anon_2116bc2ede454bff","comment_id":"c0iy3vl","kind":"comment","text":"It isn't used heavily internally, mostly used for Wave and wave-related products. The reasoning for this isn't based on its suitability, but because we have numerous older codebases that predate GWT. Wave has seen a significant productivity boost thanks to GWT, and so future projects may consider it as well for their own use.\n\nCertainly the Wave project has helped to make GWT far better.","timestamp":"2010-01-18T10:17:08+00:00","score":11}],"n_turns":4,"n_turns_after_thanks":1,"op_metadata":{"user_id":"anon_72dca4a8c8dcf717","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_2116bc2ede454bff","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c0ixt2k","thanks_reply_id":"c0ixtjl","post_score":54,"answer_score":54,"preferred_answer_is_top_level":true}}
{"user_id":"anon_9c035cbe2d3e5ce4","answerer_user_id":"anon_0fd75e5d4c162c55","subreddit":"programming","timestamp":"2010-01-19T00:28:44+00:00","post_id":"ar84i","question":"How do I convince someone with a technical background to co-found a start up with me?\n\nMy mind is business oriented. I created a business plan for a fashion oriented start up company complete with financial (with assumptions) statements. The idea is very similar to polyvore.com, but with some major differences that wouldn't put us in competition with them.\n\nAccording to my best estimates the website will generate ~$150,000 profit in ~16 months and take ~300 hours to build (estimate given by an industry veteran.) I have real revenue models other than online advertisements.\n\nI am a 22 year old community college student with $5,000. After I find a co-founder with a technical background I want to build a prototype and then present it in front of angel investors. \n\nMy ideal role: I would work on everything that wasnt directly related to the actual program of the website, so this includes paying bills, preparing investor presentations, marketing, taxes, legal matters, trade shows, meetings, attending events, signing clients, etc.\n\nMy question: What do you programmers want to hear? What do you need to know/I need to show you to successfully convince you to take the risk of co-founding a start up? I have met with 2 people but both did not have the time required to commit (kids, divorce, bankruptcy, other projects, custody hearings, etc)\n\n**I am not trying to find a web developer on reddit, I want to know how you guys think so I can improve my chances of convincing a local dev that thinks this project is something they want to work on**","preferred_answer":"I would want to hear a lot of what you said. That you have a plan (a plan I think would work), that you're going to work on all the non-fun stuff (to me), that you're going to be *working* and not sitting around waiting for me to build stuff, that we're going to put in equal amounts of time. \n\nAlso that we're gonna get supa rich and that they're equal partners.\n\nAdvice: got to balsamiq.com and lay out the website. I mean *all* of it. Every page, every link, everything should be defined. If the front page is a big image of one product, categories down the left, categories in images on the front, a login link and 6 links down the bottom (standard privacy, about, etc) - show what the product page looks like, the category page, write all the copy for the privacy/etc pages - create a complete design doc. The entire payment process, the entire registration, every single text box in balsamiq's super easy to use interface. If you get a cofounder it won't go to waste, and if you don't - heck you might be able to go to rent a coder for $5K and get a prototype going.","full_conversation":[{"role":"OP","user_id":"anon_9c035cbe2d3e5ce4","comment_id":"ar84i","kind":"post","text":"How do I convince someone with a technical background to co-found a start up with me?\n\nMy mind is business oriented. I created a business plan for a fashion oriented start up company complete with financial (with assumptions) statements. The idea is very similar to polyvore.com, but with some major differences that wouldn't put us in competition with them.\n\nAccording to my best estimates the website will generate ~$150,000 profit in ~16 months and take ~300 hours to build (estimate given by an industry veteran.) I have real revenue models other than online advertisements.\n\nI am a 22 year old community college student with $5,000. After I find a co-founder with a technical background I want to build a prototype and then present it in front of angel investors. \n\nMy ideal role: I would work on everything that wasnt directly related to the actual program of the website, so this includes paying bills, preparing investor presentations, marketing, taxes, legal matters, trade shows, meetings, attending events, signing clients, etc.\n\nMy question: What do you programmers want to hear? What do you need to know/I need to show you to successfully convince you to take the risk of co-founding a start up? I have met with 2 people but both did not have the time required to commit (kids, divorce, bankruptcy, other projects, custody hearings, etc)\n\n**I am not trying to find a web developer on reddit, I want to know how you guys think so I can improve my chances of convincing a local dev that thinks this project is something they want to work on**","timestamp":"2010-01-19T00:28:44+00:00","score":0},{"role":"answerer","user_id":"anon_0fd75e5d4c162c55","comment_id":"c0izfut","kind":"comment","text":"I would want to hear a lot of what you said. That you have a plan (a plan I think would work), that you're going to work on all the non-fun stuff (to me), that you're going to be *working* and not sitting around waiting for me to build stuff, that we're going to put in equal amounts of time. \n\nAlso that we're gonna get supa rich and that they're equal partners.\n\nAdvice: got to balsamiq.com and lay out the website. I mean *all* of it. Every page, every link, everything should be defined. If the front page is a big image of one product, categories down the left, categories in images on the front, a login link and 6 links down the bottom (standard privacy, about, etc) - show what the product page looks like, the category page, write all the copy for the privacy/etc pages - create a complete design doc. The entire payment process, the entire registration, every single text box in balsamiq's super easy to use interface. If you get a cofounder it won't go to waste, and if you don't - heck you might be able to go to rent a coder for $5K and get a prototype going.","timestamp":"2010-01-19T00:45:01+00:00","score":3},{"role":"OP","user_id":"anon_9c035cbe2d3e5ce4","comment_id":"c0izh0i","kind":"comment","text":"Thanks for the headsup. Just bought the software and will begin playing with it.\n\nDo you have any suggestions for a requirements list template that perhaps works well with the balsamiq software? (ex: linking requirements to specific parts of the mock up?)","timestamp":"2010-01-19T01:02:04+00:00","score":1},{"role":"answerer","user_id":"anon_0fd75e5d4c162c55","comment_id":"c0izi8a","kind":"comment","text":"Balsamiq has a free version with some nagging prompts X-( Ah well.\n\nIf you're got One-Note, you could drop the screens in there with arrows to text boxes, if not, you could use word, or open office. Or come up with a labeling system \"Sec 1. E. iii.\"\n\nOne more bit of advice - don't be married to the design, when you show someone and he questions it and goes \"what about this\", have a back and forth, ideally it'd go something like \n\n\"Why do you require people to have an account to buy stuff from us?\" \n\n\"Don't you need to do that?\" \n\n\"Not really. I mean it's optional, yea, but it doesn't have to be required.\"\n\n\"Oh, okay. But if it's not required, won't be be missing stuff like the ability to mail them promotions?\"\n\n\"Nah, you can still let people opt into the newsletter without an account.\"\n\n\"Oh, okay, then let's make it optional, how do we do that?\"","timestamp":"2010-01-19T01:21:24+00:00","score":2},{"role":"OP","user_id":"anon_9c035cbe2d3e5ce4","comment_id":"c0izjb9","kind":"comment","text":"Good point, and as I am not a tech guy I want to give as much creative control to the dev as possible.","timestamp":"2010-01-19T01:39:06+00:00","score":2}],"n_turns":5,"n_turns_after_thanks":2,"op_metadata":{"user_id":"anon_9c035cbe2d3e5ce4","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_0fd75e5d4c162c55","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c0izfut","thanks_reply_id":"c0izh0i","post_score":0,"answer_score":3,"preferred_answer_is_top_level":true}}
{"user_id":"anon_3115924498807d65","answerer_user_id":"anon_b477753e11ef235b","subreddit":"programming","timestamp":"2010-01-19T21:03:03+00:00","post_id":"arm0t","question":"Why we abandoned the use of Microsoft's WCF on a recent project...\n\nWe had two major issues with WCF. The first issue had to do with performance. The prototype we built worked fine for most of the windows that we had constructed until we got to the window where the user is allowed to upload documents up into the SQL Server database. We essentially created a document warehouse for the users so that they could upload and attach any Microsoft Office documents, PDF files, Email Messages (.MSG files), or images. Just about any kind of file can be uploaded to the SQL Server. Unfortunately, in order to transmit the documents between the client computer and the WCF Application Server, it has to “Marshall” and “Unmarshall” the data. This marshalling and unmarshalling is very intensive and slow, and was causing the application to work slowly while working on the documents window. We abandoned using the default http: protocol, and tried using bare-bones TCP/IP communications, and it did help, but not enough. Furthermore, it takes a lot of custom entries and tweaking of the XML configuration files (on both the client and the WCF App Service) to get the system to be able to accept even medium sized document files (anything bigger than 15KB fails without custom configuration file entries. \r\n\r\nThe folks at Microsoft are proud of the fact that you can take a WCF service application and simply change configuration files to make it run in a completely different environment (hosted inside IIS, in a stand-alone app, or as a windows service), or use completely different protocols (http:, TCP/IP, etc.). However, this relies heavy on what is called “declarative computing” whereby a significant portion of your program’s behavior is coded into XML configuration files instead of executable statements in your actual source code. In my opinion, although it may be more flexible for different deployment scenarios, the introduction of the fragile and complex XML configuration files makes the application much harder to create and more importantly harder to maintain. \r\n\r\nThe second problem was the one that really killed us. WCF is a relatively new technology from Microsoft, and I don’t think they quite have all the kinks worked out. The problem is in the area of the triad of software interaction between Visual Studio 2008, WCF, and Visual SourceSafe, particularly when more than one developer is trying to share WCF project source code with each other using Visual Source Safe. In a typical scenario, Developer A adds a new WCF Service method to the middle-tier application. After recompiling and running the service locally on his/her machine, the developer pulls up the Client application and updates the WCF proxy object in Visual Studio. What this does behind the scenes is dynamically queries the WCF Service running locally using WSDL protocol, and once it gets a list of all the published methods of the service, it updates the bindings within the proxy object. \r\n\r\nUnfortunately, at the same time it also updates (corrupts in my opinion) the local app.config file with what it thinks should be there. What this was doing was blowing away all the custom entries that we had made to the app.config file in order to accommodate the large upload file sizes, and also the multiple endpoint bindings that we had defined for Test, Production, Local, etc. VERY AGGRIVATING!! We had to keep a constant backup of the app.config file and we would have to restore it back to the customized state each time. To add the cherry on the top of this whole cream pie, when developer A would check in both projects (client and WCF Service) into Visual Source Safe (VSS), and then Developer B would pull all the latest code from VSS and compile and run it, a gazillion errors would show up on the client app. Developer B would then have to check out the client project’s code and perform the update operation for the proxy object on their workstation, and then everything would compile once again (after, of course, developer B also manually restored the app.config file back to the customized version). WHAT A PAIN !!! \r\n\r\nAfter this cycle repeated itself 4 or 5 times, we just got mentally exhausted and I had to call a timeout and make the hard decision to abandon the usage of the WCF for the project. We are now the proud owners of a plain Client/Server application that has 3 \"logical\" code layers behind the scenes (UI, business objects, and database access), but has only two physical layers (no middle tier application server). It runs almost 3 times as fast as the WCF version of the same screens. Anyone else experience these same frustrations with WCF?","preferred_answer":"> In my opinion, although it may be more flexible for different deployment scenarios, the introduction of the fragile and complex XML configuration files makes the application much harder to create and more importantly harder to maintain.\r\n\r\nThen don't use it. I have long abandoned XML configuration for WCF in favor of doing it all in code.","full_conversation":[{"role":"OP","user_id":"anon_3115924498807d65","comment_id":"arm0t","kind":"post","text":"Why we abandoned the use of Microsoft's WCF on a recent project...\n\nWe had two major issues with WCF. The first issue had to do with performance. The prototype we built worked fine for most of the windows that we had constructed until we got to the window where the user is allowed to upload documents up into the SQL Server database. We essentially created a document warehouse for the users so that they could upload and attach any Microsoft Office documents, PDF files, Email Messages (.MSG files), or images. Just about any kind of file can be uploaded to the SQL Server. Unfortunately, in order to transmit the documents between the client computer and the WCF Application Server, it has to “Marshall” and “Unmarshall” the data. This marshalling and unmarshalling is very intensive and slow, and was causing the application to work slowly while working on the documents window. We abandoned using the default http: protocol, and tried using bare-bones TCP/IP communications, and it did help, but not enough. Furthermore, it takes a lot of custom entries and tweaking of the XML configuration files (on both the client and the WCF App Service) to get the system to be able to accept even medium sized document files (anything bigger than 15KB fails without custom configuration file entries. \r\n\r\nThe folks at Microsoft are proud of the fact that you can take a WCF service application and simply change configuration files to make it run in a completely different environment (hosted inside IIS, in a stand-alone app, or as a windows service), or use completely different protocols (http:, TCP/IP, etc.). However, this relies heavy on what is called “declarative computing” whereby a significant portion of your program’s behavior is coded into XML configuration files instead of executable statements in your actual source code. In my opinion, although it may be more flexible for different deployment scenarios, the introduction of the fragile and complex XML configuration files makes the application much harder to create and more importantly harder to maintain. \r\n\r\nThe second problem was the one that really killed us. WCF is a relatively new technology from Microsoft, and I don’t think they quite have all the kinks worked out. The problem is in the area of the triad of software interaction between Visual Studio 2008, WCF, and Visual SourceSafe, particularly when more than one developer is trying to share WCF project source code with each other using Visual Source Safe. In a typical scenario, Developer A adds a new WCF Service method to the middle-tier application. After recompiling and running the service locally on his/her machine, the developer pulls up the Client application and updates the WCF proxy object in Visual Studio. What this does behind the scenes is dynamically queries the WCF Service running locally using WSDL protocol, and once it gets a list of all the published methods of the service, it updates the bindings within the proxy object. \r\n\r\nUnfortunately, at the same time it also updates (corrupts in my opinion) the local app.config file with what it thinks should be there. What this was doing was blowing away all the custom entries that we had made to the app.config file in order to accommodate the large upload file sizes, and also the multiple endpoint bindings that we had defined for Test, Production, Local, etc. VERY AGGRIVATING!! We had to keep a constant backup of the app.config file and we would have to restore it back to the customized state each time. To add the cherry on the top of this whole cream pie, when developer A would check in both projects (client and WCF Service) into Visual Source Safe (VSS), and then Developer B would pull all the latest code from VSS and compile and run it, a gazillion errors would show up on the client app. Developer B would then have to check out the client project’s code and perform the update operation for the proxy object on their workstation, and then everything would compile once again (after, of course, developer B also manually restored the app.config file back to the customized version). WHAT A PAIN !!! \r\n\r\nAfter this cycle repeated itself 4 or 5 times, we just got mentally exhausted and I had to call a timeout and make the hard decision to abandon the usage of the WCF for the project. We are now the proud owners of a plain Client/Server application that has 3 \"logical\" code layers behind the scenes (UI, business objects, and database access), but has only two physical layers (no middle tier application server). It runs almost 3 times as fast as the WCF version of the same screens. Anyone else experience these same frustrations with WCF?","timestamp":"2010-01-19T21:03:03+00:00","score":0},{"role":"answerer","user_id":"anon_b477753e11ef235b","comment_id":"c0j1s9z","kind":"comment","text":"> In my opinion, although it may be more flexible for different deployment scenarios, the introduction of the fragile and complex XML configuration files makes the application much harder to create and more importantly harder to maintain.\r\n\r\nThen don't use it. I have long abandoned XML configuration for WCF in favor of doing it all in code.","timestamp":"2010-01-20T02:15:09+00:00","score":6},{"role":"OP","user_id":"anon_3115924498807d65","comment_id":"c0j2kuk","kind":"comment","text":"Thanks. I think I'm heading there as well.","timestamp":"2010-01-20T13:19:39+00:00","score":2},{"role":"answerer","user_id":"anon_b477753e11ef235b","comment_id":"c0j2tfp","kind":"comment","text":"If you need any help feel free to contact me. I'm no master, but I think I've worked through most of the major pain points.","timestamp":"2010-01-20T15:57:08+00:00","score":1},{"role":"OP","user_id":"anon_3115924498807d65","comment_id":"c0j2xng","kind":"comment","text":"Based on all the great tips and feedback, I'm going to...\r\n\r\n1. Trash VSS and get Subversion installed and working.\r\n\r\n2. Re-program my app to completely bypass the app.config file entries and do everything manually in code, so I re-gain control over the situation.\r\n\r\n3. For file uploading and downloading, implement an out-of-band U/D mechanism that doesn't try to shove the files through WCF channels.","timestamp":"2010-01-20T16:56:47+00:00","score":2}],"n_turns":5,"n_turns_after_thanks":2,"op_metadata":{"user_id":"anon_3115924498807d65","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_b477753e11ef235b","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c0j1s9z","thanks_reply_id":"c0j2kuk","post_score":0,"answer_score":6,"preferred_answer_is_top_level":true}}
{"user_id":"anon_7e62b0f2eb650785","answerer_user_id":"anon_42c3093bfb9755f3","subreddit":"programming","timestamp":"2010-01-21T03:29:01+00:00","post_id":"as759","question":"Hey Reddit: Out of these 4 programmers, who would you hire?\n\nI have my own opinion on this, which I will share if we get a good discussion going.\n\n\nTake a hypothetical situation where you interview 4 candidates. They claim to have a good grasp on CS fundamentals, as well as know C#.\n\n\nYou ask them to solve a simple problem:\n\n Create a function that reverses a string.\n\nYou get back 4 unique approaches. All of them work properly:\n\n\n // Candidate 1\n static string Reverse(string input)\n {\n Stack stack = new Stack(input.ToCharArray());\n\n StringBuilder sb = new StringBuilder();\n foreach (char c in stack)\n {\n sb.Append(c);\n }\n\n return sb.ToString();\n }\n\n\n // Candidate 2\n static String Reverse(string input)\n {\n char[] chars = input.ToCharArray();\n int length = chars.Length;\n for (int i = 0; i < length / 2; i++)\n {\n char t = chars[i];\n chars[i] = chars[length - 1 - i];\n chars[length - 1 - i] = t;\n }\n\n return new String(chars);\n }\n\n\n // Candidate 3\n static string Reverse(string input)\n {\n char[] chars = input.ToCharArray();\n Array.Reverse(chars);\n return new String(chars);\n }\n\n\n // Candidate 4\n static string Reverse(string input)\n {\n string result = String.Empty;\n if (input.Length == 1)\n {\n return input;\n }\n else\n {\n result += input.ToCharArray().Last() + Reverse(input.Substring(0, input.Length - 1));\n return result;\n }\n }\n\n\nAssuming you have to pick one of these 4 for the job, and can only pick one. Based on what you see in these answers, who would you pick? Why? (Hypothetically of course, nobody would interview with a single question)\n\n\nI have a fairly strong opinion, but I wanted to see what other professional developers would think.","preferred_answer":"I'm just a javascript newbie and I can understand (only) #3 at the first glance :)","full_conversation":[{"role":"OP","user_id":"anon_7e62b0f2eb650785","comment_id":"as759","kind":"post","text":"Hey Reddit: Out of these 4 programmers, who would you hire?\n\nI have my own opinion on this, which I will share if we get a good discussion going.\n\n\nTake a hypothetical situation where you interview 4 candidates. They claim to have a good grasp on CS fundamentals, as well as know C#.\n\n\nYou ask them to solve a simple problem:\n\n Create a function that reverses a string.\n\nYou get back 4 unique approaches. All of them work properly:\n\n\n // Candidate 1\n static string Reverse(string input)\n {\n Stack stack = new Stack(input.ToCharArray());\n\n StringBuilder sb = new StringBuilder();\n foreach (char c in stack)\n {\n sb.Append(c);\n }\n\n return sb.ToString();\n }\n\n\n // Candidate 2\n static String Reverse(string input)\n {\n char[] chars = input.ToCharArray();\n int length = chars.Length;\n for (int i = 0; i < length / 2; i++)\n {\n char t = chars[i];\n chars[i] = chars[length - 1 - i];\n chars[length - 1 - i] = t;\n }\n\n return new String(chars);\n }\n\n\n // Candidate 3\n static string Reverse(string input)\n {\n char[] chars = input.ToCharArray();\n Array.Reverse(chars);\n return new String(chars);\n }\n\n\n // Candidate 4\n static string Reverse(string input)\n {\n string result = String.Empty;\n if (input.Length == 1)\n {\n return input;\n }\n else\n {\n result += input.ToCharArray().Last() + Reverse(input.Substring(0, input.Length - 1));\n return result;\n }\n }\n\n\nAssuming you have to pick one of these 4 for the job, and can only pick one. Based on what you see in these answers, who would you pick? Why? (Hypothetically of course, nobody would interview with a single question)\n\n\nI have a fairly strong opinion, but I wanted to see what other professional developers would think.","timestamp":"2010-01-21T03:29:01+00:00","score":138},{"role":"answerer","user_id":"anon_42c3093bfb9755f3","comment_id":"c0j4h76","kind":"comment","text":"I'm just a javascript newbie and I can understand (only) #3 at the first glance :)","timestamp":"2010-01-21T04:53:04+00:00","score":1},{"role":"OP","user_id":"anon_7e62b0f2eb650785","comment_id":"c0j4hg5","kind":"comment","text":"Take a hard look at #2, when you get it, you'll really appreciate it.","timestamp":"2010-01-21T04:56:35+00:00","score":4},{"role":"answerer","user_id":"anon_42c3093bfb9755f3","comment_id":"c0j4jnw","kind":"comment","text":"Well, thanks. But I may try this:\n function reverseString ( input ) {\n return input.split('').reverse().join('');\n }","timestamp":"2010-01-21T05:28:50+00:00","score":0}],"n_turns":4,"n_turns_after_thanks":1,"op_metadata":{"user_id":"anon_7e62b0f2eb650785","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_42c3093bfb9755f3","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c0j4h76","thanks_reply_id":"c0j4hg5","post_score":138,"answer_score":1,"preferred_answer_is_top_level":true}}
{"user_id":"anon_5a891afc0182240b","answerer_user_id":"anon_3c3346f240e6b08c","subreddit":"programming","timestamp":"2010-01-24T23:34:32+00:00","post_id":"ato7x","question":"Has any of you successfully transitioned from test to development?\n\nI was a test engineer for about a year before I went back to school for a Master's degree. I got the degree partly to explore if I wanted to work in academia and partly because I thought it'd help me land a good development job (in systems). However, when I graduated I got interview calls mainly for test/QA positions probably because of past experience. So, here I am back in a non-development position which involves testing,automation etc. Has anyone successfully transitioned to being a developer from such positions? Any tips on how I should go about reaching my goal, considering I have at least a couple of years in my current position? Its not like I hate testing, I like development better. And I'm afraid I'm being pigeonholed into testing by adding more and more testing experience on my resume.\n\ntl;dr : I am a test/automation engineer and I would really like to move into development. Any tips?","preferred_answer":"I was in your position at one point. I had a multi-faceted approach that I used to make the transition. The first step is to get into the code. Not much you can do unless you make an effort to understand why something works the way it does. Then, start submitting patches or descriptions of what needs to be done in the code for any trivial bugs that you report. As you get more comfortable, code up solutions to the harder things. Eventually, people's perception of you will change.\n\nAnother good way to show that you have coding chops is to take a problem or an upcoming project and implement some kind of solution in your spare time. Nothing speaks louder than working code. Do enough of these and you will have proven that you are a very valuable developer.\n\nWhile going about this, it helps if you have understanding superiors to whom you have communicated your hopes and intentions (when the time is right for such a conversation).\n\nAnd of course, as the standard disclaimer goes, \"your mileage may vary\"; however, by doing all of this, you should eventually transition into the position you want to be in. The worst thing you can do is get discouraged along the way--this will take some time (on the order of a year for me).","full_conversation":[{"role":"OP","user_id":"anon_5a891afc0182240b","comment_id":"ato7x","kind":"post","text":"Has any of you successfully transitioned from test to development?\n\nI was a test engineer for about a year before I went back to school for a Master's degree. I got the degree partly to explore if I wanted to work in academia and partly because I thought it'd help me land a good development job (in systems). However, when I graduated I got interview calls mainly for test/QA positions probably because of past experience. So, here I am back in a non-development position which involves testing,automation etc. Has anyone successfully transitioned to being a developer from such positions? Any tips on how I should go about reaching my goal, considering I have at least a couple of years in my current position? Its not like I hate testing, I like development better. And I'm afraid I'm being pigeonholed into testing by adding more and more testing experience on my resume.\n\ntl;dr : I am a test/automation engineer and I would really like to move into development. Any tips?","timestamp":"2010-01-24T23:34:32+00:00","score":0},{"role":"answerer","user_id":"anon_3c3346f240e6b08c","comment_id":"c0jcepl","kind":"comment","text":"I was in your position at one point. I had a multi-faceted approach that I used to make the transition. The first step is to get into the code. Not much you can do unless you make an effort to understand why something works the way it does. Then, start submitting patches or descriptions of what needs to be done in the code for any trivial bugs that you report. As you get more comfortable, code up solutions to the harder things. Eventually, people's perception of you will change.\n\nAnother good way to show that you have coding chops is to take a problem or an upcoming project and implement some kind of solution in your spare time. Nothing speaks louder than working code. Do enough of these and you will have proven that you are a very valuable developer.\n\nWhile going about this, it helps if you have understanding superiors to whom you have communicated your hopes and intentions (when the time is right for such a conversation).\n\nAnd of course, as the standard disclaimer goes, \"your mileage may vary\"; however, by doing all of this, you should eventually transition into the position you want to be in. The worst thing you can do is get discouraged along the way--this will take some time (on the order of a year for me).","timestamp":"2010-01-25T02:12:14+00:00","score":4},{"role":"OP","user_id":"anon_5a891afc0182240b","comment_id":"c0jcfqu","kind":"comment","text":"Thanks for the reply, you make some good points. I wonder how much management played a role in allowing you space to code up solutions to bugs? In my previous job, I was told to continue testing for more bugs and not waste valuable time in trying to find solutions. Did you convey your ambitions to your manager pretty much when you started in testing?","timestamp":"2010-01-25T02:28:48+00:00","score":1},{"role":"answerer","user_id":"anon_3c3346f240e6b08c","comment_id":"c0jci0c","kind":"comment","text":"When I first started out, management had no idea. It was at one of those performance reviews (the type where they ask you where you see yourself in 5 years) that I firmly said that I saw no reason that I wouldn't be developing even sooner than that, given how talented I was in that area. An ostentatious comment to be sure, but I intended to follow up on it.\n\nYou have to also understand the type of testing that I was doing, which leaned a lot more on the automation side of things, so it was natural for me to write code and not have too many questions asked about why I was typing in a text editor instead of clicking around in a drone-like fashion.\n\nSounds like management at your previous job was a bit clueless, since coming up with good solutions is probably the best use of time that anyone can come up with. It's basic management theory--business has problem--business needs solution to problem.\n\nIt will do a lot for you if it turns out that your \"superiors\" are understanding and if you do a good job conveying your intentions, both via working code itself as well as telling them directly when the occasion warrants it. I think that this is one of those areas where your personal time becomes very useful.\n\nA good way to get into the code, since you are focused on testing, is doing refactoring to make things more unit-testable and writing unit tests for them. Just another avenue to explore when you're trying to move from testing to development.","timestamp":"2010-01-25T03:04:01+00:00","score":2},{"role":"OP","user_id":"anon_5a891afc0182240b","comment_id":"c0jckbv","kind":"comment","text":"yeah, I do quite a bit of coding for automation too, so typing in a text editor won't raise any flags... I guess this is one of the situations in which the management jargon of 'being proactive' truly helps :)","timestamp":"2010-01-25T03:39:24+00:00","score":1}],"n_turns":5,"n_turns_after_thanks":2,"op_metadata":{"user_id":"anon_5a891afc0182240b","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_3c3346f240e6b08c","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c0jcepl","thanks_reply_id":"c0jcfqu","post_score":0,"answer_score":4,"preferred_answer_is_top_level":true}}
{"user_id":"anon_2cee8a5563d6b972","answerer_user_id":"anon_74d044df0693c70f","subreddit":"programming","timestamp":"2010-01-25T00:01:23+00:00","post_id":"atof3","question":"What are your thoughts on the growing number of young (pre-teen young) iPhone developers?\n\nMy stand? They piss me off. I'm not even legally an adult and I am infuriated by the copy-and-paste mentality taught by 12 year olds giving iPhone coding tutorials on YouTube. \n\nWhat do you think? Is the next generation of developers doomed by these \"noobs\" trying to fit in?\n\nThis is not a hate topic. I just want your opinions.","preferred_answer":"i think he is referring to the snobbyness that some of these kids have.\n\n\"i can mad hax, let me just download other people's sourcecode and click run\"","full_conversation":[{"role":"OP","user_id":"anon_2cee8a5563d6b972","comment_id":"atof3","kind":"post","text":"What are your thoughts on the growing number of young (pre-teen young) iPhone developers?\n\nMy stand? They piss me off. I'm not even legally an adult and I am infuriated by the copy-and-paste mentality taught by 12 year olds giving iPhone coding tutorials on YouTube. \n\nWhat do you think? Is the next generation of developers doomed by these \"noobs\" trying to fit in?\n\nThis is not a hate topic. I just want your opinions.","timestamp":"2010-01-25T00:01:23+00:00","score":0},{"role":"answerer","user_id":"anon_74d044df0693c70f","comment_id":"c0jccyo","kind":"comment","text":"i think he is referring to the snobbyness that some of these kids have.\n\n\"i can mad hax, let me just download other people's sourcecode and click run\"","timestamp":"2010-01-25T01:46:10+00:00","score":1},{"role":"OP","user_id":"anon_2cee8a5563d6b972","comment_id":"c0jcdew","kind":"comment","text":"thank you. finally. :P\n\nbut yeah I totally agree about the teaching thing. luckily, i have a really good comp sci teacher, i've even done research with him.","timestamp":"2010-01-25T01:53:06+00:00","score":0},{"role":"answerer","user_id":"anon_74d044df0693c70f","comment_id":"c0jcdpl","kind":"comment","text":"really? what's his name?","timestamp":"2010-01-25T01:57:21+00:00","score":1},{"role":"OP","user_id":"anon_2cee8a5563d6b972","comment_id":"c0jcdt7","kind":"comment","text":"charles babbage.","timestamp":"2010-01-25T01:58:50+00:00","score":0},{"role":"answerer","user_id":"anon_74d044df0693c70f","comment_id":"c0jcdy5","kind":"comment","text":"same here. small world","timestamp":"2010-01-25T02:01:03+00:00","score":1}],"n_turns":6,"n_turns_after_thanks":3,"op_metadata":{"user_id":"anon_2cee8a5563d6b972","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_74d044df0693c70f","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c0jccyo","thanks_reply_id":"c0jcdew","post_score":0,"answer_score":1,"preferred_answer_is_top_level":false}}
{"user_id":"anon_056cdda4981be15f","answerer_user_id":"anon_bc55dce67c59ffc8","subreddit":"programming","timestamp":"2010-01-25T23:41:03+00:00","post_id":"au3rs","question":"Newbie LGPL compliance questions; any of you OSS license experts out there today?\n\nHey all—we are investigating the use of an open source product (call it FOO) licensed under the LGPL. There are a ton of other projects which use this product, either without modification or with modifications. \n\nIn most cases, those secondary projects are also released open-source and licensed under the LGPL. I've encountered a small handful of projects that:\n- Distribute FOO, including modifications, as source\n- Distribute themselves as static libraries, no source included (but sometimes the header files for the static library). They also usually include make files which allow the whole package (static library+FOO) to be built and used as one.\n\nQuestions:\n\n1.) Are those latter projects actually in compliance with the LGPL? I think so, as they appear to meet the terms of section 6.a:\n\n> Accompany the work with the complete corresponding machine-readable source code for the Library including whatever changes were used in the work (which must be distributed under Sections 1 and 2 above); and, if the work is an executable linked with the Library, with the complete machine-readable \"work that uses the Library\", **as object code** and/or source code, so that the user can modify the Library and then relink to produce a modified executable containing the modified Library.\n\nbut this part is hazy for me.\n\n2.) For projects that distribute their own product as a static library, is it legal for us to link our product to that static library and use functionality from it in our own projects, provided we also distribute our product with FOO's source in compliance with the LGPL, and the static library provided by the other vendor? \n\nThanks for your help. These licenses are often treacherous to navigate.\n\n**Edit:** Formatting, emphasis.","preferred_answer":"Your users must be able to change the code licensed under the LGPL and run your program with that changed code. There's a few ways to do this:\n\n * Distribute the source code to your program. It need not be under the LGPL, or GPL.\n * Distribute your program statically linked against the LGPL library. But also distribute all the object files for your program, along with the object files of the LGPL library.\n * Put the object files of the LGPL library into a dynamic library, and then link your program against that dynamic library.\n\nA \"static library\" is a synonym for \"object files\", in all cases.","full_conversation":[{"role":"OP","user_id":"anon_056cdda4981be15f","comment_id":"au3rs","kind":"post","text":"Newbie LGPL compliance questions; any of you OSS license experts out there today?\n\nHey all—we are investigating the use of an open source product (call it FOO) licensed under the LGPL. There are a ton of other projects which use this product, either without modification or with modifications. \n\nIn most cases, those secondary projects are also released open-source and licensed under the LGPL. I've encountered a small handful of projects that:\n- Distribute FOO, including modifications, as source\n- Distribute themselves as static libraries, no source included (but sometimes the header files for the static library). They also usually include make files which allow the whole package (static library+FOO) to be built and used as one.\n\nQuestions:\n\n1.) Are those latter projects actually in compliance with the LGPL? I think so, as they appear to meet the terms of section 6.a:\n\n> Accompany the work with the complete corresponding machine-readable source code for the Library including whatever changes were used in the work (which must be distributed under Sections 1 and 2 above); and, if the work is an executable linked with the Library, with the complete machine-readable \"work that uses the Library\", **as object code** and/or source code, so that the user can modify the Library and then relink to produce a modified executable containing the modified Library.\n\nbut this part is hazy for me.\n\n2.) For projects that distribute their own product as a static library, is it legal for us to link our product to that static library and use functionality from it in our own projects, provided we also distribute our product with FOO's source in compliance with the LGPL, and the static library provided by the other vendor? \n\nThanks for your help. These licenses are often treacherous to navigate.\n\n**Edit:** Formatting, emphasis.","timestamp":"2010-01-25T23:41:03+00:00","score":0},{"role":"answerer","user_id":"anon_bc55dce67c59ffc8","comment_id":"c0jehne","kind":"comment","text":"Your users must be able to change the code licensed under the LGPL and run your program with that changed code. There's a few ways to do this:\n\n * Distribute the source code to your program. It need not be under the LGPL, or GPL.\n * Distribute your program statically linked against the LGPL library. But also distribute all the object files for your program, along with the object files of the LGPL library.\n * Put the object files of the LGPL library into a dynamic library, and then link your program against that dynamic library.\n\nA \"static library\" is a synonym for \"object files\", in all cases.","timestamp":"2010-01-26T00:02:33+00:00","score":5},{"role":"OP","user_id":"anon_056cdda4981be15f","comment_id":"c0jeizr","kind":"comment","text":"Thanks for the info. Let's take your second bullet point. If another developer distributed their library exactly as you mentioned (as a static library linked to the LGPL library), can WE then use *that* third party's library, link to it, and use its functionality (provided either header files or some reverse-engineering)?","timestamp":"2010-01-26T00:21:30+00:00","score":2},{"role":"answerer","user_id":"anon_bc55dce67c59ffc8","comment_id":"c0jeu6o","kind":"comment","text":"If another developer distributed their library (\"steve\") statically linked against the LGPL library (\"laura\"), then they need to respect the license of \"laura\". This is independent of you respecting the license of laura.\n\nIf they did not distribute steve as per one of my three bullet points, then they're violating the license of \"laura\", in which case you would also do so if you were to link against steve (and thus, indirectly, laura).\n\nIf they distributed steve in the manner of my second bullet point, then you are enabled to distribute your package in such a way that laura can be modified. If both of these are the case, then you are not violating the license of laura. (But, independently, you must also not violate the license of steve.)\n\nIn short: yes, you can indirectly violate the license of an LGPL library.\n\nIn slightly longer: if you link (statically or dynamically) against library A, and A links against library B, you need to respect the license of A and B.\n\nTo be overly pedantic, and this in no way answers your question: If you dynamically link to, but do not distribute, a library, then you cannot violate the library's license. In practice, this is impossible because you still need to use its header files or whatnot.","timestamp":"2010-01-26T03:03:19+00:00","score":1}],"n_turns":4,"n_turns_after_thanks":1,"op_metadata":{"user_id":"anon_056cdda4981be15f","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_bc55dce67c59ffc8","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c0jehne","thanks_reply_id":"c0jeizr","post_score":0,"answer_score":5,"preferred_answer_is_top_level":true}}
{"user_id":"anon_ca283a591ab23ba3","answerer_user_id":"anon_56068fc00a1452ed","subreddit":"programming","timestamp":"2010-01-28T05:32:08+00:00","post_id":"av2ye","question":"Did turning your passion of programming into a career after college kill the passion?\n\nTitle. I'm currently in college for computer science, and I'm worried after working it 9-5 if it will be the same anymore. Any tips/experiences?","preferred_answer":"The instant you get paid for something that you previously enjoyed doing for free, you lose some of the intrinsic joy / motivation you previously had. I don't remember the psychological term for it (Psych majors, we may actually have a use for you... I'm sorry for those mean things I said...) Having said that, it depends upon where you end up working. I enjoyed my work for a long time. Then the company I was working for changed considerably and life went from good to bad quite quickly. It's not easy to find a good company anymore. It seems that, more and more IT is seen as a commodity these days and we've gone from \"magical makers of code\" to \"pesky overhead\". Find a place where you aren't just going to be treated like overhead and life will be better.","full_conversation":[{"role":"OP","user_id":"anon_ca283a591ab23ba3","comment_id":"av2ye","kind":"post","text":"Did turning your passion of programming into a career after college kill the passion?\n\nTitle. I'm currently in college for computer science, and I'm worried after working it 9-5 if it will be the same anymore. Any tips/experiences?","timestamp":"2010-01-28T05:32:08+00:00","score":47},{"role":"answerer","user_id":"anon_56068fc00a1452ed","comment_id":"c0jjxdx","kind":"comment","text":"The instant you get paid for something that you previously enjoyed doing for free, you lose some of the intrinsic joy / motivation you previously had. I don't remember the psychological term for it (Psych majors, we may actually have a use for you... I'm sorry for those mean things I said...) Having said that, it depends upon where you end up working. I enjoyed my work for a long time. Then the company I was working for changed considerably and life went from good to bad quite quickly. It's not easy to find a good company anymore. It seems that, more and more IT is seen as a commodity these days and we've gone from \"magical makers of code\" to \"pesky overhead\". Find a place where you aren't just going to be treated like overhead and life will be better.","timestamp":"2010-01-28T08:09:43+00:00","score":2},{"role":"OP","user_id":"anon_ca283a591ab23ba3","comment_id":"c0jkbsz","kind":"comment","text":"Thanks man; good advice. So don't take shit and spend your time finding where you should be instead of taking it for a decade?","timestamp":"2010-01-28T15:15:03+00:00","score":1},{"role":"answerer","user_id":"anon_56068fc00a1452ed","comment_id":"c0jkmai","kind":"comment","text":"Yeah, JoelOnSoftware and others have dedicated pages to what to look for in a company. Unfortunately, there's only so much you can learn during the interview process. My current company looks great on paper but the reality is that it's not a good place to work. This isn't something you could figure out during an interview. It may take you 6 months to figure it out. Once you bump into it though... life sucks.","timestamp":"2010-01-28T17:35:12+00:00","score":1},{"role":"OP","user_id":"anon_ca283a591ab23ba3","comment_id":"c0jkn5f","kind":"comment","text":"Makes me want to move to glasgow, lol.","timestamp":"2010-01-28T17:44:57+00:00","score":1}],"n_turns":5,"n_turns_after_thanks":2,"op_metadata":{"user_id":"anon_ca283a591ab23ba3","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_56068fc00a1452ed","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c0jjxdx","thanks_reply_id":"c0jkbsz","post_score":47,"answer_score":2,"preferred_answer_is_top_level":true}}
{"user_id":"anon_2c0667268d975832","answerer_user_id":"anon_2da86e604973a6b5","subreddit":"programming","timestamp":"2010-02-01T00:29:03+00:00","post_id":"awgru","question":"I need an app for facebook that allows people to link to their vendors and bridal party. How much should I be paying for this?","preferred_answer":"$5k","full_conversation":[{"role":"OP","user_id":"anon_2c0667268d975832","comment_id":"awgru","kind":"post","text":"I need an app for facebook that allows people to link to their vendors and bridal party. How much should I be paying for this?","timestamp":"2010-02-01T00:29:03+00:00","score":0},{"role":"answerer","user_id":"anon_2da86e604973a6b5","comment_id":"c0jr3zj","kind":"comment","text":"$5k","timestamp":"2010-02-01T00:38:59+00:00","score":1},{"role":"OP","user_id":"anon_2c0667268d975832","comment_id":"c0jr4yv","kind":"comment","text":"May be not then. Thanks.","timestamp":"2010-02-01T00:55:53+00:00","score":1},{"role":"answerer","user_id":"anon_2da86e604973a6b5","comment_id":"c0jt2af","kind":"comment","text":"It may not have to be that expensive. I write Facebook application and that is just the bottom line base price for a project. You have given a one line description of your idea. The main reason most people want to put stuff of Facebook is also to have the viral capability and that takes a lot of effort making it work nicely and fluidly with an app while nicely following Facebook's TOS. If you don't want an application in Facebook, then look to have it offsite. You can probably get it for much cheaper.","timestamp":"2010-02-01T21:39:49+00:00","score":1},{"role":"OP","user_id":"anon_2c0667268d975832","comment_id":"c0jt2mn","kind":"comment","text":"Basically all I want is a little box that will appear on the brides page. It would have a list of roles:groom, best man, maid of honour, photographer etc. If they are on facebook it would link to them if not it would link to their website.","timestamp":"2010-02-01T21:43:21+00:00","score":1}],"n_turns":5,"n_turns_after_thanks":2,"op_metadata":{"user_id":"anon_2c0667268d975832","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_2da86e604973a6b5","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c0jr3zj","thanks_reply_id":"c0jr4yv","post_score":0,"answer_score":1,"preferred_answer_is_top_level":true}}
{"user_id":"anon_de7aefc05b3bfabc","answerer_user_id":"anon_32eced3e82c09164","subreddit":"programming","timestamp":"2010-02-02T03:16:24+00:00","post_id":"awxl9","question":"Help me out Proggit, I want to learn my first language!\n\nBut I don't know which I should learn. I'm not just being lazy, I've tried to do research, but I'd like to hear some advice, preferences, stories and warnings from Reddit!\n\nI know this is a broad question and open to preference and interpretation, but I'd like to get a wide analysis of programmers to see what I can do to make a good pick! I'll try to answer any questions, and my friends and I thank you in advance for your help!!","preferred_answer":"Good for you! Welcome to the club. You're officially a programmer now. :)\n\nPeople will give you a bunch of advice if you ask them for it\u0010. My feeling is: just pick one and run with it. Most mainstream languages are pretty similar, and your first one is always the hardest.\n\nFigure out something you want to do -- an interactive web page, maybe, or a simple interactive text game, or rendering a simple graphics image. _Then_ pick the language. People will be able to give you better advice when you've chosen something specific to implement.\n\nPick a problem domain that you'll love, one that will keep you plugging away even when things get confusing or discouraging, and you're much more likely to be successful and keep after it.\n\nIf you aren't getting it, try a different language! Just don't give up. There are a gazillion people willing to help out at all phases of the learning process.","full_conversation":[{"role":"OP","user_id":"anon_de7aefc05b3bfabc","comment_id":"awxl9","kind":"post","text":"Help me out Proggit, I want to learn my first language!\n\nBut I don't know which I should learn. I'm not just being lazy, I've tried to do research, but I'd like to hear some advice, preferences, stories and warnings from Reddit!\n\nI know this is a broad question and open to preference and interpretation, but I'd like to get a wide analysis of programmers to see what I can do to make a good pick! I'll try to answer any questions, and my friends and I thank you in advance for your help!!","timestamp":"2010-02-02T03:16:24+00:00","score":0},{"role":"answerer","user_id":"anon_32eced3e82c09164","comment_id":"c0jtrxj","kind":"comment","text":"Good for you! Welcome to the club. You're officially a programmer now. :)\n\nPeople will give you a bunch of advice if you ask them for it\u0010. My feeling is: just pick one and run with it. Most mainstream languages are pretty similar, and your first one is always the hardest.\n\nFigure out something you want to do -- an interactive web page, maybe, or a simple interactive text game, or rendering a simple graphics image. _Then_ pick the language. People will be able to give you better advice when you've chosen something specific to implement.\n\nPick a problem domain that you'll love, one that will keep you plugging away even when things get confusing or discouraging, and you're much more likely to be successful and keep after it.\n\nIf you aren't getting it, try a different language! Just don't give up. There are a gazillion people willing to help out at all phases of the learning process.","timestamp":"2010-02-02T03:28:41+00:00","score":2},{"role":"OP","user_id":"anon_de7aefc05b3bfabc","comment_id":"c0jtsy0","kind":"comment","text":"Thanks! So basically, whether it's C++ or Perl or Python, etc, it'll give me what I need to know to move on and find my own groove?","timestamp":"2010-02-02T03:43:02+00:00","score":1},{"role":"answerer","user_id":"anon_32eced3e82c09164","comment_id":"c0jtv06","kind":"comment","text":"I think so. YMMV. But keep in mind my last paragraph -- if you don't like your choice, pick another one. The \"not giving up\" is the important part. It's really not that hard; the problem is that nobody's very good at explaining it. :)","timestamp":"2010-02-02T04:12:32+00:00","score":2}],"n_turns":4,"n_turns_after_thanks":1,"op_metadata":{"user_id":"anon_de7aefc05b3bfabc","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_32eced3e82c09164","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c0jtrxj","thanks_reply_id":"c0jtsy0","post_score":0,"answer_score":2,"preferred_answer_is_top_level":true}}
{"user_id":"anon_939ddfd713186a18","answerer_user_id":"anon_d7e36d5fab365c09","subreddit":"programming","timestamp":"2010-02-03T17:39:10+00:00","post_id":"axncy","question":"Is emacs a useful tool for a CS student to learn?\n\nI'm a CS major and currently enrolled in a C++ course. I've done plenty of Java programming in the past along with assembly, some C and Python, but this is my first swing at C++. I've heard about emacs before, but I'm not really too sure how its useful and if its a necessary tool to learn.\n\nSo I come to you proggit, is it worth it for me to learn emacs as I learn C++? If so, is there a good way to get jumpstarted on learning it? And should I use emacs..xemacs?\n\nFYI: I run Ubuntu and all of my assignments/projects will be compiled with g++ on debian machines","preferred_answer":"Absolutely! Take the time to learn basic emacs usage, and it will only benefit you. Emacs + GNU Make is all you need for projects like this.\n\nDon't ever touch XEmacs though. It was cool once, when it first came out, but now it's just horribly outdated and obsolete.","full_conversation":[{"role":"OP","user_id":"anon_939ddfd713186a18","comment_id":"axncy","kind":"post","text":"Is emacs a useful tool for a CS student to learn?\n\nI'm a CS major and currently enrolled in a C++ course. I've done plenty of Java programming in the past along with assembly, some C and Python, but this is my first swing at C++. I've heard about emacs before, but I'm not really too sure how its useful and if its a necessary tool to learn.\n\nSo I come to you proggit, is it worth it for me to learn emacs as I learn C++? If so, is there a good way to get jumpstarted on learning it? And should I use emacs..xemacs?\n\nFYI: I run Ubuntu and all of my assignments/projects will be compiled with g++ on debian machines","timestamp":"2010-02-03T17:39:10+00:00","score":10},{"role":"answerer","user_id":"anon_d7e36d5fab365c09","comment_id":"c0jx6xs","kind":"comment","text":"Absolutely! Take the time to learn basic emacs usage, and it will only benefit you. Emacs + GNU Make is all you need for projects like this.\n\nDon't ever touch XEmacs though. It was cool once, when it first came out, but now it's just horribly outdated and obsolete.","timestamp":"2010-02-03T17:54:25+00:00","score":7},{"role":"OP","user_id":"anon_939ddfd713186a18","comment_id":"c0jx98v","kind":"comment","text":"Thank you for that, my professor recommended xemacs over emacs and I wasn't really sure why.","timestamp":"2010-02-03T18:23:28+00:00","score":1},{"role":"answerer","user_id":"anon_d7e36d5fab365c09","comment_id":"c0jxaf8","kind":"comment","text":"XEmacs was a solid improvement over GNU Emacs back in like version 18 or thereabouts (whenever the fork happened). Innovation stopped dead after that, though, and GNU Emacs soared past it. Now it has stuff XEmacs can only dream about, so I'm not sure why he would recommend it. Maybe he's just a throwback.","timestamp":"2010-02-03T18:38:55+00:00","score":5}],"n_turns":4,"n_turns_after_thanks":1,"op_metadata":{"user_id":"anon_939ddfd713186a18","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_d7e36d5fab365c09","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c0jx6xs","thanks_reply_id":"c0jx98v","post_score":10,"answer_score":7,"preferred_answer_is_top_level":true}}
{"user_id":"anon_c1c521ed9a3af56b","answerer_user_id":"anon_c3c4043f869493aa","subreddit":"programming","timestamp":"2010-02-03T20:24:24+00:00","post_id":"axplx","question":"What do you guys think of debuggers? Essential tool? Or crutch?\n\nMy boss just implied that he might force me to use a debugger one of these days. Apparently, I take too much time debugging (his convoluted) code. I'm against the idea; not because I dislike debuggers, but I hate the idea of not being able to debug without one. I am will to use one if ever the bug turns out to be complex, but if I didn't rack my brains first, I think it's more of a destructive habit than anything.\n\nDo note that I deal with PHP and javascript 90% of the time. Understanding the code and sprinkling a few print_r/var_dump works in 99% of cases, imho. If I was dealing with a language which isn't as easily introspectable, my use of the debugger would be much more prevalent, but I still think the previous logic applies.\n\nWhat do you guys think?\n\n\n-- EDIT --\nWell, I think we established that debuggers are *awesomely useful* to quote ssylvan. I guess the real question was, what's an appropriate threshold before you fire it up?","preferred_answer":"I think the OP's point was that using a debugger is less likely to bring you to that *gods among men* state. He's probably right to some extent, but not using the debugger is a luxury that should be done on your own time, not your company's.","full_conversation":[{"role":"OP","user_id":"anon_c1c521ed9a3af56b","comment_id":"axplx","kind":"post","text":"What do you guys think of debuggers? Essential tool? Or crutch?\n\nMy boss just implied that he might force me to use a debugger one of these days. Apparently, I take too much time debugging (his convoluted) code. I'm against the idea; not because I dislike debuggers, but I hate the idea of not being able to debug without one. I am will to use one if ever the bug turns out to be complex, but if I didn't rack my brains first, I think it's more of a destructive habit than anything.\n\nDo note that I deal with PHP and javascript 90% of the time. Understanding the code and sprinkling a few print_r/var_dump works in 99% of cases, imho. If I was dealing with a language which isn't as easily introspectable, my use of the debugger would be much more prevalent, but I still think the previous logic applies.\n\nWhat do you guys think?\n\n\n-- EDIT --\nWell, I think we established that debuggers are *awesomely useful* to quote ssylvan. I guess the real question was, what's an appropriate threshold before you fire it up?","timestamp":"2010-02-03T20:24:24+00:00","score":7},{"role":"answerer","user_id":"anon_c3c4043f869493aa","comment_id":"c0jxszw","kind":"comment","text":"I think the OP's point was that using a debugger is less likely to bring you to that *gods among men* state. He's probably right to some extent, but not using the debugger is a luxury that should be done on your own time, not your company's.","timestamp":"2010-02-03T22:19:19+00:00","score":2},{"role":"OP","user_id":"anon_c1c521ed9a3af56b","comment_id":"c0jy0mz","kind":"comment","text":"You understood. Thanks for an objective point of view, from both sides of the fence. I actually agree with you, even though I'd prefer if my employer paid me to not always be as productive as can be.\n\nEdit: So how else does one become *god among men*?\nEdit2: Apart from reading (code and books) and concentrating?","timestamp":"2010-02-03T23:58:58+00:00","score":0},{"role":"answerer","user_id":"anon_c3c4043f869493aa","comment_id":"c0jy42j","kind":"comment","text":"Well, you've really called me out on this one - I'm about as far from a *god among men* as you can get and have basically no experience at progamming. Nevertheless, I'll have a bash at answering this. \n\nI'd say that what defines the *gods among men* is their mindset to approaching problems. This doesn't just apply to programming. Most of the people I've met who are experts in their fields have a knack for breaking problems down into their simplest constituent parts. Coupled with an excellent understanding of the system containing the problem, this process makes their jobs so much easier. Think about Feynman Diagrams. These are awesome, because they show the quantum interaction of particles in simple terms and lose none of the important bits. \n\nSo strive for that mindset - always see things in the simplest terms possible. Concentrating hard on something may be wasted time and energy if you're overcomplicating a problem. Furthermore, lots of practice. Like TomorrowPlusX said, the *gods among men* tend to be older. They didn't just wake up at 40 and say \"oh right, that's what I've been doing wrong\". They spent those years writing lots and lots of code. \n\nSo yeah, do that.","timestamp":"2010-02-04T00:46:20+00:00","score":1}],"n_turns":4,"n_turns_after_thanks":1,"op_metadata":{"user_id":"anon_c1c521ed9a3af56b","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_c3c4043f869493aa","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c0jxszw","thanks_reply_id":"c0jy0mz","post_score":7,"answer_score":2,"preferred_answer_is_top_level":false}}
{"user_id":"anon_fc74283f5165db62","answerer_user_id":"anon_c102ef74e97027dc","subreddit":"programming","timestamp":"2010-02-05T18:21:53+00:00","post_id":"ayjp0","question":"Help plz: cannot find visual c++ 2003 anywhere\n\nSo I bought this book about gamesprogramming and it's got a CD with sample projects, but they've been made in Visual C++ 2003 and conversions constantly fail when using 2005 or 2008 versions. \n\nNow I have intensely googled for the 2003 express version or any version at all, but I can simply not find a thing :( \n\nAny Help appreciated, \n\nLuxpsycho :)","preferred_answer":"Your English is fine, and since it's an E-Book, why not just go with one of the many available fine tutorials available online? (Most of these have solutions for visual studio 2008 or show you easily how to create your own).\n\n(DirectX 9) http://www.directxtutorial.com/Tutorial9/tutorials.aspx\n\n(SDL) http://www.sdltutorials.com/sdl-tutorial-basics/\n\nVisual Studio 2003 is no longer supported by Microsoft, so in order to get it, you either need a MSDN subscription of some sort, or pirate it, maybe there is a copy floating around on ebay, but i would strongly advocate against this. VS2k3 is **obsolete**","full_conversation":[{"role":"OP","user_id":"anon_fc74283f5165db62","comment_id":"ayjp0","kind":"post","text":"Help plz: cannot find visual c++ 2003 anywhere\n\nSo I bought this book about gamesprogramming and it's got a CD with sample projects, but they've been made in Visual C++ 2003 and conversions constantly fail when using 2005 or 2008 versions. \n\nNow I have intensely googled for the 2003 express version or any version at all, but I can simply not find a thing :( \n\nAny Help appreciated, \n\nLuxpsycho :)","timestamp":"2010-02-05T18:21:53+00:00","score":0},{"role":"answerer","user_id":"anon_c102ef74e97027dc","comment_id":"c0k1tai","kind":"comment","text":"Your English is fine, and since it's an E-Book, why not just go with one of the many available fine tutorials available online? (Most of these have solutions for visual studio 2008 or show you easily how to create your own).\n\n(DirectX 9) http://www.directxtutorial.com/Tutorial9/tutorials.aspx\n\n(SDL) http://www.sdltutorials.com/sdl-tutorial-basics/\n\nVisual Studio 2003 is no longer supported by Microsoft, so in order to get it, you either need a MSDN subscription of some sort, or pirate it, maybe there is a copy floating around on ebay, but i would strongly advocate against this. VS2k3 is **obsolete**","timestamp":"2010-02-05T19:28:33+00:00","score":2},{"role":"OP","user_id":"anon_fc74283f5165db62","comment_id":"c0k1u5z","kind":"comment","text":"Thanks \nVS '03 not being supported by microsoft explains it all^^ \nWell, thanks for your help and clarification then, \n\nLuxpsycho \n\n\nP.S. Why did I get so many downvotes for this post? Does it belong to askreddit.com? But it's strongly computing-related... hmm...","timestamp":"2010-02-05T19:39:55+00:00","score":1},{"role":"answerer","user_id":"anon_c102ef74e97027dc","comment_id":"c0k25ab","kind":"comment","text":"try posting LOL cats instead of an honest to goodness question.","timestamp":"2010-02-05T22:10:02+00:00","score":2},{"role":"OP","user_id":"anon_fc74283f5165db62","comment_id":"c0k2h5q","kind":"comment","text":"very helpful indeed...","timestamp":"2010-02-06T01:31:03+00:00","score":1}],"n_turns":5,"n_turns_after_thanks":2,"op_metadata":{"user_id":"anon_fc74283f5165db62","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_c102ef74e97027dc","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c0k1tai","thanks_reply_id":"c0k1u5z","post_score":0,"answer_score":2,"preferred_answer_is_top_level":false}}
{"user_id":"anon_e561ba89cafd587c","answerer_user_id":"anon_a263951b5ef2426f","subreddit":"programming","timestamp":"2010-02-06T17:43:21+00:00","post_id":"ayvr6","question":"Need advice: Live video streaming\n\ni wanna set up a live video stream. I have a accounted hosted by webfaction currently up and running so i am wondering is their a way to upload a video from a webcam and distribute it through the webfaction account ? i want to do this because the place i am broadcasting is from have very limited upload bandwidth (adsl) and the webfaction servers have more than enough bandwidth to deal with the users i am expecting.","preferred_answer":"You won't be able to broadcast from your server unless it has specialized streaming software installed. But this is not a problem. Unless you need specific control, services like ustream.tv or justin.tv should work perfectly well. Just take the embed codes and put them on your web page and that's it.","full_conversation":[{"role":"OP","user_id":"anon_e561ba89cafd587c","comment_id":"ayvr6","kind":"post","text":"Need advice: Live video streaming\n\ni wanna set up a live video stream. I have a accounted hosted by webfaction currently up and running so i am wondering is their a way to upload a video from a webcam and distribute it through the webfaction account ? i want to do this because the place i am broadcasting is from have very limited upload bandwidth (adsl) and the webfaction servers have more than enough bandwidth to deal with the users i am expecting.","timestamp":"2010-02-06T17:43:21+00:00","score":0},{"role":"answerer","user_id":"anon_a263951b5ef2426f","comment_id":"c0k41a2","kind":"comment","text":"You won't be able to broadcast from your server unless it has specialized streaming software installed. But this is not a problem. Unless you need specific control, services like ustream.tv or justin.tv should work perfectly well. Just take the embed codes and put them on your web page and that's it.","timestamp":"2010-02-07T00:38:03+00:00","score":1},{"role":"OP","user_id":"anon_e561ba89cafd587c","comment_id":"c0k4xhy","kind":"comment","text":"hi thanks i used ustream and flash encoder to live cast it :)","timestamp":"2010-02-07T16:12:54+00:00","score":2},{"role":"answerer","user_id":"anon_a263951b5ef2426f","comment_id":"c0k5b5e","kind":"comment","text":"Awesome. Glad to be of help.","timestamp":"2010-02-07T20:06:28+00:00","score":1}],"n_turns":4,"n_turns_after_thanks":1,"op_metadata":{"user_id":"anon_e561ba89cafd587c","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_a263951b5ef2426f","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c0k41a2","thanks_reply_id":"c0k4xhy","post_score":0,"answer_score":1,"preferred_answer_is_top_level":true}}
{"user_id":"anon_7d217629e483adbc","answerer_user_id":"anon_20a74e7714d975ee","subreddit":"programming","timestamp":"2010-02-09T20:10:53+00:00","post_id":"b024x","question":"Creating a simple soundboard app... never read a programming book and I don't have an Mac. Can you help if I have a question?\n\nI'm using online video tutorials for guidance... and I'm not sure if I can connect the dots at the end of my project. I would like to get this app done in a week, at most... does anybody have a little time this week and give me the permission to PM them?","preferred_answer":"Sure.","full_conversation":[{"role":"OP","user_id":"anon_7d217629e483adbc","comment_id":"b024x","kind":"post","text":"Creating a simple soundboard app... never read a programming book and I don't have an Mac. Can you help if I have a question?\n\nI'm using online video tutorials for guidance... and I'm not sure if I can connect the dots at the end of my project. I would like to get this app done in a week, at most... does anybody have a little time this week and give me the permission to PM them?","timestamp":"2010-02-09T20:10:53+00:00","score":0},{"role":"answerer","user_id":"anon_20a74e7714d975ee","comment_id":"c0ka95s","kind":"comment","text":"Sure.","timestamp":"2010-02-10T00:25:54+00:00","score":1},{"role":"OP","user_id":"anon_7d217629e483adbc","comment_id":"c0kacuy","kind":"comment","text":"thank you. I started writing the code in a text doc and will go to school tomorrow to work on a Mac... hopefully they have Xcode and Interface builder on the machine...\n\nI almost lost hope in /programming ...was about to delete and post into /favors lol","timestamp":"2010-02-10T01:20:30+00:00","score":1},{"role":"answerer","user_id":"anon_20a74e7714d975ee","comment_id":"c0kb9l7","kind":"comment","text":"There's an multi-platform, open source implementation of the OPENSTEP API called [GNUstep](http://www.gnustep.org/experience/Startup.html). That OPENSTEP spec consisted of mainly of three components: Foundation Kit, Application Kit and Display PostScript. Those first two should ring a bell.\n\nMac OS X is a continuation of OPENSTEP, and because of this, is source-compatible with GNUstep, as compatibility with OPENSTEP is the one of the goals of the GNUstep project.\n\n*You can write and run code in Windows or whatever that will build and link on a Mac.*\n\nOf course, there are some caveats. A couple of the top of my head:\n\nFirst, it isn't a complete implementation; the amount of the API that *is* implemented is amazing, however. Notably missing are newer technologies like Core Animation and things. From browsing the docs, there is more than enough there to learn Cocoa really well with.\n\nSecond, it's source compatible but dev tool-related stuff may not be. As far as nibs go, Apple's never released a spec for the format, and the xml-based format is relatively new. Since you can't take your UIs back and forth, designing your UIs in code may be a more attractive option than rushing through IB when you're at a Mac. GNUstep's IDE, Project Center, may not produce project files that are compatible with Xcode. This is easy to remedy, though.\n\nIt seems like it might be a bit of work to develop on both GNUstep and a Mac simultaneously - and while learning, but being able to get instant feedback from building on your own machine might be worth it. Here's a link to their [wiki](http://wiki.gnustep.org/index.php/Installation_on_Windows) on Windows installation.\n\nDisclaimer: I have never used GNUstep directly. I write apps in OPENSTEP for fun, and because OPENSTEP is so old, I frequently turn to GNUstep sources to try and implement things I need that didn't exist in its day - like XML.","timestamp":"2010-02-10T13:37:41+00:00","score":1},{"role":"OP","user_id":"anon_7d217629e483adbc","comment_id":"c0kba57","kind":"comment","text":"what great information! I will explore that wiki today and hopefully get a better idea of the similarities in both programs... If I don't start building the code today on my computer I have to wait until tomorrow because my school is having one of their few and far between snow days.\n\nOnce again, thank you..","timestamp":"2010-02-10T13:50:52+00:00","score":1}],"n_turns":5,"n_turns_after_thanks":2,"op_metadata":{"user_id":"anon_7d217629e483adbc","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_20a74e7714d975ee","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c0ka95s","thanks_reply_id":"c0kacuy","post_score":0,"answer_score":1,"preferred_answer_is_top_level":true}}
{"user_id":"anon_5a10c9b28312eed4","answerer_user_id":"anon_ec12adb182f90df9","subreddit":"programming","timestamp":"2010-02-10T16:22:32+00:00","post_id":"b0f7o","question":"HELP Needed diagnosing Google adwords landing page quality score\n\nWe recently hired a local firm to build a Google Adwords compatible landing page. They said, “No problem! We do them all the time!”\nA week behind schedule, the landing page was finally completed and live on our domain. Everything looked great and our Adwords manager turned on the campaigns. The quality score started out at 7/10, and one hour later – I’m assuming after google’s robots scanned the page – it dropped to 1/10 and removed all of our ads. I am relatively web tech savvy. I’ve built a few pages, know html and css, etc so I thought I would give it a shot. I researched possible reasons and fixes, presented them to our “programmer” and he said ok. This was a very faint ok, mind you.\n\nNeedless to say, they stumbled through the issues we addressed, represented what looked like a corrected landing page, and we went live again.\n\nIt happened again, just like the first time.\n\nWe are struggling as it is, and we can’t afford to be wasting this much time on this.\n\nI’m looking for a competent programmer, adwords expert that can take a look at what we have, diagnose and consult or repair the website.\n\n**I’m not asking for free help. I will gladly pay you for your time. I am looking for someone that can help immediately.**\n\nThank you Reddit, I’m confident I came to the right place.","preferred_answer":"Dont use Flash.\n\nMake sure the words in your text ad are mentioned on your website.\n\nMake sure the keywords you are bidding on are mentioned on your website.\n\nHave all the meta tags and all that.\n\nIf you log into the AdWords Campaign on the actual website not Ad Words editor, and mouseover that little speachbubble looking thing under status, it may give you a reason for the quality score.\n\nWhat is the service offered? Is it allowed?\n\nEdit: not a programmer, just familiar with AdWords.","full_conversation":[{"role":"OP","user_id":"anon_5a10c9b28312eed4","comment_id":"b0f7o","kind":"post","text":"HELP Needed diagnosing Google adwords landing page quality score\n\nWe recently hired a local firm to build a Google Adwords compatible landing page. They said, “No problem! We do them all the time!”\nA week behind schedule, the landing page was finally completed and live on our domain. Everything looked great and our Adwords manager turned on the campaigns. The quality score started out at 7/10, and one hour later – I’m assuming after google’s robots scanned the page – it dropped to 1/10 and removed all of our ads. I am relatively web tech savvy. I’ve built a few pages, know html and css, etc so I thought I would give it a shot. I researched possible reasons and fixes, presented them to our “programmer” and he said ok. This was a very faint ok, mind you.\n\nNeedless to say, they stumbled through the issues we addressed, represented what looked like a corrected landing page, and we went live again.\n\nIt happened again, just like the first time.\n\nWe are struggling as it is, and we can’t afford to be wasting this much time on this.\n\nI’m looking for a competent programmer, adwords expert that can take a look at what we have, diagnose and consult or repair the website.\n\n**I’m not asking for free help. I will gladly pay you for your time. I am looking for someone that can help immediately.**\n\nThank you Reddit, I’m confident I came to the right place.","timestamp":"2010-02-10T16:22:32+00:00","score":0},{"role":"answerer","user_id":"anon_ec12adb182f90df9","comment_id":"c0kbkgf","kind":"comment","text":"Dont use Flash.\n\nMake sure the words in your text ad are mentioned on your website.\n\nMake sure the keywords you are bidding on are mentioned on your website.\n\nHave all the meta tags and all that.\n\nIf you log into the AdWords Campaign on the actual website not Ad Words editor, and mouseover that little speachbubble looking thing under status, it may give you a reason for the quality score.\n\nWhat is the service offered? Is it allowed?\n\nEdit: not a programmer, just familiar with AdWords.","timestamp":"2010-02-10T16:34:42+00:00","score":2},{"role":"OP","user_id":"anon_5a10c9b28312eed4","comment_id":"c0kbl69","kind":"comment","text":"Hey, thanks for the info.\n\nI'm not following you on:\n\n>If you log into the AdWords Campaign on the actual website not Ad Words editor\n\nRight now, I'm in adwords.google.com","timestamp":"2010-02-10T16:43:48+00:00","score":1},{"role":"answerer","user_id":"anon_ec12adb182f90df9","comment_id":"c0kbmbp","kind":"comment","text":"Ok. Pull up the keywords tab, and under the status column, there is the little speechbubble thing that you can mouseover to see the Quality Scores. In that little window, it will have three sections:\n\n-Ad Relevancy: How relevant to keywords the text ad is.\n\n-Landing Page quality: How relevant to the keywords and ad the landing page is. Should have the same words on the landing page as the keywords and text ad. Also, quality of the page (no flash, no popups, etc.)\n\n-Landing page load time: self explanatory.\n\nIn that same little mouseover window there is a Displaying ads now?: yes/no. This will tell you what if anything is majorly wrong. This may only work if you are targeting Nationally, as opposed to zipcodes/cities/states/etc.\n\nIn this same mouseover window, there is the Ads diagnostic tool that can provide some other tips/tricks to get your ads online.\n\n\nNot much else I can do without seeing the site/adwords page.\n\nEdit: AdWords Editor is a desktop based program where you can modify AdWords campaigns and then post the changes to Google, rather than at adwords.google.com.","timestamp":"2010-02-10T16:58:40+00:00","score":2},{"role":"OP","user_id":"anon_5a10c9b28312eed4","comment_id":"c0kbnsu","kind":"comment","text":"I've PM'd you the results to the Diagnostic Tool.\n\nAs far as the status bubble is concerned, everything is labeled \"no problem\" except for Landing Page.\n\nWhen I go to the diagnostic tool, it mentions geo-location.\n\nWe are targeting certain states. Could that be an issue?","timestamp":"2010-02-10T17:17:52+00:00","score":1},{"role":"answerer","user_id":"anon_ec12adb182f90df9","comment_id":"c0kbo5x","kind":"comment","text":"An issue, no. It just means the tool wont work in this case.","timestamp":"2010-02-10T17:22:31+00:00","score":1},{"role":"OP","user_id":"anon_5a10c9b28312eed4","comment_id":"c0kbof4","kind":"comment","text":"So if I disable geo-location, will the tool work?","timestamp":"2010-02-10T17:25:45+00:00","score":1},{"role":"answerer","user_id":"anon_ec12adb182f90df9","comment_id":"c0kboxf","kind":"comment","text":"Yes, if you are prepared to target nationally. I would add cities that you work in (and are mentioned on the website) on the end of keywords in that case.","timestamp":"2010-02-10T17:32:17+00:00","score":1}],"n_turns":8,"n_turns_after_thanks":5,"op_metadata":{"user_id":"anon_5a10c9b28312eed4","author_flair_text":null,"author_flair_css_class":null,"author_flair_type":"text","author_flair_background_color":null,"author_flair_text_color":null},"answerer_metadata":{"user_id":"anon_ec12adb182f90df9","author_flair_text":null,"author_flair_css_class":null},"metadata":{"answer_comment_id":"c0kbkgf","thanks_reply_id":"c0kbl69","post_score":0,"answer_score":2,"preferred_answer_is_top_level":true}}
{"user_id":"anon_c7e3be94ef2fa5bb","answerer_user_id":"anon_239c6305b9a881c1","subreddit":"programming","timestamp":"2010-02-11T02:24:43+00:00","post_id":"b0mo6","question":"I'm a PHP web developer who wants to learn objective C for iPhone - any tips?\n\nAs a freshly unemployed web developer I decided it's time to invest in my self-education again. I bought a few iPhone developer books but I'm having trouble staying motivated. I think what I need is a change in the way I think about it, if I could just understand the difference between the way applications are set up and how things work, I feel like I could move forward. Help me reddit!","preferred_answer":">I think what I need is a change in the way I think about it, if I could just understand the difference between the way applications are set up and how things work, I feel like I could move forward. \n\nThere are two important ways in which web programming with PHP is different from traditional GUI programming with Objective-C: the programming model and the execution model.\n\nThe programming model with PHP is pretty simple: you write a .php file, put it in a directory accessible to a webserver, and you browse to the .php file on that server. In the background the server software automatically runs the PHP interpreter which reads and executes the code in your .php file. If you make a change to your .php file, the next time you access it through the web server the new code will be executed.\n\nThe programming model with Objective-C is more complicated, due to being a compiled language. With Objective-C you put your code in .h and .m files (.h for \"interface\" files which describe the contents of a module and provide all the necessary information for using it while .m files actually provide the implementation of a module). The .m files (and the .h files which they include) are then compiled by a compiler (usually gcc) into .o files (binary \"object\" files). Once all the .m files have been compiled the compiler calls another program called the linker to combine all the .o and library files. They can be combined in to three different types of files: executables, static libraries (basically an archive containing all the .o files so they can be used by the linker in the future), and dynamic libraries (.dylib on OS X, like static libraries but are meant to be used by applications *directly* rather than the linker).\n\nOnly once you have completed all of these steps (which all modern IDEs completely automate in to one \"build\" or \"build & run\" command) can you actually use the code you're writing. Every time you update your code you *have* to recompile your application for the changes to take effect (although most of the time you only need to recompile one or a file files and this is also automated by modern IDEs) to try your new code. Understanding this whole process often trips up people who've only ever used interpreted languages but it is not too complicated and it is very important for working with compiled languages.\n\nThe execution model refers to the way your program runs. With PHP your application is actually lots of shorter-lived programs working together. Most PHP applications have several .php files which do different actions, like showthread.php and newreply.php. Although they are part of the same application, they are considered different programs by the interpreter (albeit ones which share lots of code and a backing database). PHP \"programs\" are also very short lived (on the order of milliseconds to seconds). They're basically started and given the information from the HTTP request, do stuff, then write a web page and exit. This (generally) means you don't need to worry too much about resources because each part of your application doesn't stick around long enough for those to become an issue.\n\nIn contrast, interactive compiled programs generally are very long-lived (on the order of minutes to hours). Each executable has to contain all the functions of the application. When the program starts it's given command-line arguments (although obviously there aren't any for the iPhone) and environment variables but then it's responsible for everything else regarding user interaction and it sticks around until the user exits. This also means that it has to manage resources carefully (garbage collection* helps tremendously but it isn't a panacea) because otherwise they'll stick around/build up until the program exits.\n\nWhile that difference is very important, there is also a very important similarity: both execution models are event-driven. This means that functions/subprograms are called/executed in response to events rather than in a pre-programmed/linear fashion. In the case of PHP, every time a user accesses a .php file it is an event, with the HTTP request data (POST/GET) representing the data associated with that event. I'm not familiar with iPhone development, but I assume it works like most GUI development frameworks where you can register event handlers (like functions or objects) with event generators (like GUI widgets).\n\nLets consider an example of a registration form. In PHP you'd write a .php file (or a static .html file) with the form and a submit button. Lets say the