Y
HN Search
Hacker News Search
new
|
comments
|
top
|
jobs
irahul
searching PlanetScale…
1.
▲
2.
▲
3.
▲
4.
▲
5.
▲
6.
▲
92 ms
·
751.
▲
by
irahul
15y ago
Oh. I should have guessed "practical ai programming" was actually PAIP(Paradigms...). I haven't read PAIP, but have read AIMA, and the topic under discussion occurs in AIMA; so I assumed OP meant AIMA.
752.
▲
by
irahul
15y ago
My bad. Written communication is confusing - your comment sounded incredulous. EDIT: In retrospect, you did mention you find it interesting - don't know how it jumped out as incredulous.
753.
▲
by
irahul
15y ago
In case someone runs into this comment and is interested in checking out the book, the book is called AIMA(Artificial Intelligence: A modern approach), and here is the relevant code. http://aima-python.googlecode.com/svn/trunk/search.py I
754.
▲
by
irahul
15y ago
> DFS and BFS can be expressed by a single algorithm that differs only in the behavior of the "queue." Correct me if I am wrong, but the naive non-recursive DFS and BFS differ only in the implementation of queue. https://gist.github.co
755.
▲
by
irahul
15y ago
> I'm pretty sure that's a BFS, not a DFS. A DFS uses a stack, not a queue. In the gist, queue.push adds element to the tail end, and queue.pop removes from the tail end. For it to be behave as BFS, you will have to change queue.pop to
756.
▲
by
irahul
15y ago
> Try to parse this with it, <html>hello</lol>world</html>. Parsing invalid xml with a xml parser throws an error like it should. I am using cElementTree for parsing and this is what will happen with your input.
757.
▲
by
irahul
15y ago
I see where you are coming from. I was arguing more on the side of "familiarity with algorithms" is like "hitting the gym" irrespective of what game/sport you play. It either helps you directly, or gives you general skill. I was mostly tak
758.
▲
by
irahul
15y ago
I don't know. If you are struggling with A* search, and claiming to be a great programmer, it sound contradictory. I am assuming poster was familiar with graphs and graph searches before he stumbled onto A* search. Recursive/Non-recursive
759.
▲
by
irahul
15y ago
Try any of the vim keybinding plugins if you like keyboard navigation. I use vimium with Chrome.
760.
▲
by
irahul
15y ago
> I can't figure out what you're trying to say, but if you think there are enough programmers as smart as Bram to staff an entire company, you're a fool I am saying Bram Cohen isn't going to work at a place where grade school teachers t
761.
▲
by
irahul
15y ago
> clearly Mr Cohen isn't working with superstar engineers, I can't find where he works(wikipedia, his blog doesn't mention anything). But considering he is the inventor of BitTorrent protocol and wrote the first client, I assume he won'
762.
▲
by
irahul
15y ago
The Ruby and Python communities are just now, many years after the hype has faded, learning that stuff like dependency injection and proper modularization are actually good things that help you maintain code over time. This remark is off
763.
▲
by
irahul
15y ago
> I seem to recall VimClojure having some kind of completion, but don't hold me to that. VimClojure has completion, but it works only when nailgun server is running. Same goes for repl, evaluation and documentation lookup.
764.
▲
by
irahul
15y ago
No, there isn't a typo. 1 lakh * 1, 00, 000 * is delimited as such.
765.
▲
by
irahul
15y ago
> This is demonstrably true, at least in the U.S. Demonstrably true here in India as well. True that I can't speak for all of India, or you can't speak for all of US; but I believe I have enough data points for the extrapolation to be v
766.
▲
by
irahul
15y ago
> A graduate course that ended with a review would feel really weird to me. Also, I don't think most of the courses can be summarized in a review lecture.
767.
▲
by
irahul
15y ago
Thanks for your hard work. Not everyone knows how to mess with gdb and ruby C api, and even when you do, it's a bit unpleasant. As far as active dev work goes, IMO this is the kind of software which should implement the bare minimum correct
768.
▲
by
irahul
15y ago
Very cool. Does it share the address space i.e redefining methods affect the running code?
769.
▲
by
irahul
15y ago
> 1) Quick console start. As rails developers, we spend way too much time waiting for consoles to start. This could save at least an hour out of my month. Won't a better idea be to leave the console running?
770.
▲
by
irahul
15y ago
Remote repl can be done in Python/Ruby in hackish ways. It's the transparent hot code swap which hasn't been done yet. I haven't investigated it much, but Armin Ronacher(flask lead developer) has said reliable code reloading when a module c
771.
▲
by
irahul
15y ago
I didn't find much information concerning ruby. Basically, the approach to hot code reloading is: 1. Find a way to attach to a running process. Either leave a socket open, as done in twisted manhole; or directly attach to running process. 2
772.
▲
by
irahul
15y ago
I found hijack on your blog: http://www.rubyinside.com/hijack-get-a-live-irb-prompt-for-a... This ranks higher than the github repo while searching for "ruby attach running process." hnsearch showed the same article being submitted about
773.
▲
by
irahul
15y ago
This has been submitted before, but it didn't get much attention. I stumbled onto it while researching hot code reloading in ruby.
774.
▲
IRB session to existing ruby process.
(github.com)
73 points
by
irahul
15y ago
|
21 comments
775.
▲
by
irahul
15y ago
> Has rachelbythebay ever written a post that is not about bashing Google as evil or all engineers as sexist? Suppose Hitler said exercising is good for health. Now Hitler was one sick son of a bitch, but that has nothing to do with whe
776.
▲
by
irahul
15y ago
> This post is so deeply antisocial it makes me sad The post is describing what works for him. While in the midst of something, mails, random greetings, IM pings are extremely irritating. When I was at my day job, I always had my headph
777.
▲
by
irahul
15y ago
> Why does it warrant a pattern all to itself and an entire chapter of a book? And more to the point, why should I care about it, other than to try and decipher legacy ex-Java code like this? I think we started discussing different thi
778.
▲
by
irahul
15y ago
> In Ruby or Python everything is an object, every method or function call returns an object, hence everything is a factory, and the term loses its meaning. I don't think factory is defined as anything that returns an object. I am n
779.
▲
by
irahul
15y ago
> Do we really need factory pattern in Python? Yes. from PIL import Image im = Image.open("bride.jpg") Image.open here is a factory, and im will be an object of a different class, depending on the filename you pass to it(jp
780.
▲
by
irahul
15y ago
I looked at couple of them. Some of the patterns has a note mentioning it is a port of C#/Java/C++ implementation in the Wikipedia article. Python is drastically different from C#/Java/C++, and a direct port of classical patterns won't make
More ›