That time I wrote a query with chained ruby methods weighing in at 41 lines and 2844 chars

14-Sep-2017 2846
First things first, I REFACTORED THIS NASTY MESS! And this is focused on how I got into the mess and some of the first things I did to addressed it.In my opinion Ruby is great and Rails is amazing. They make me a happy programmer and pretty productive. But I find keeping some solid rules in mind when coding is always good. I’ve started trying to hold myself to things like “more classes are better then fewer” and “keep methods short” - when I hit 10 lines really think about how to break it out.
Use coupon code:

RUBYONRAILS

to get 30% discount on our bundle!
Prepare for your next tech interview with our comprehensive collection of programming interview guides. Covering JavaScript, Ruby on Rails, React, and Python, these highly-rated books offer thousands of essential questions and answers to boost your interview success. Buy our 'Ultimate Job Interview Preparation eBook Bundle' featuring 2200+ questions across multiple languages. Ultimate Job Interview Preparation eBook Bundle