The other day, I noticed during an interview with a company. Perhaps it is a matter of course for engineers in the field, but it was quite a big notice for me who has no practical experience yet, so I hope that someone who sees this will also notice it. I hope to introduce it.
At this stage, I don't know what kind of code is often used, but in Ruby, you can make the process into a method, stock it, copy and paste it as needed, and call the method to finish the process. Feeled very efficient. As a point,
--Describe what you are doing in the comments. ――It feels like a return value is returned by making it a method and passing an argument. (For example, if you pass a number, it will be returned as a character string)
By the way, I wrote a new code every time I solved Paiza's problem, but I wrote the same thing many times ...
In response to this, a new question is
――What kind of processing is frequently used code? ――Is it the work of picking up what is rolling on the net without thinking for yourself in the first place?
about it. If you have any advice ...