Category Archives: Programming
Programming Challenges: 110501 Primary Arithmetic
Primary Arithmetic Not a too tricky a problem here, took two attempts because I forgot to clear the carry flag in the non-carry case.
Programming Challenges Problems – Easiest to Hardest
After completing the The Stern-Brocot Number System problem the other day, I pondered which problem to solve next. So I created a Excel spreadsheet to hold all 112 problems, and then sorted it by number of Users Solved to see … Continue reading
Programming Challenges:110507 The Stern-Brocot Number System
Last night I was bored, and decided to tackle a Programming Challenges problem: 110507 The Stern-Brocot Number System seemed easy, and in the end it was. However it took two attempts, due to messing up the termination logic. ie run … Continue reading
GetTextMetricsW causing memory corruption
I have been converting our ANSI product to UNICODE, and today during testing I was getting “Run-Time Check Failure #2 – Stack around the variable ‘tm’ was corrupted.” error messages. Turned out it was this code: TEXTMETRICW tm; GetTextMetricsW( hDC, … Continue reading
IDA Script: Remove empty auto labels
When working in IDA to reverse games, you can end up with lots of dummy/empty labels, that are auto generated when doing offset work. Here’s my script to remove them. First how it happens. You find a value you are … Continue reading