Here is an opinionated presentation on how to clean up some code. It’s based on my own take on the Clean Code principles. In particular, I think code can often get a bit detaily. In other words, the detail is taking a higher status than the overall approach. Baked into that is unnecessary detail where something that’s optional is put in – for example, the final keyword or fully qualified paths to method names.
When you remove the extraneous low-level stuff from a function and either ditch it completely, or delegate it to a lower level function, then you express your intent clearly and more manageably. Similarly, if you know how to refine your code and don’t spend the time applying those refinements then though you might save a few seconds right now, you’re wasting minutes and hours of everyone later as they revisit your code.
Here’s my Google slides presentation showing an illustrative refactor.