Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

Yeah that's the first thing that drew my attention, if you normalise and then remove a component... now you know for sure length whatever you are doing is dependent on the direction of the input vector.

I still find vector programming hard though, so if I was writing anything like this I'd always visualise it as part of my testing. i.e temporarily render out the other beams and possibly the intermediate vector as necessary (pretty much what they did in this video). That makes testing easier to verify and debugging way more intuitive.



Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: