IntelliJ and I
Bare with me while you read through this post, as I animate a lifeless JAVA IDE and present him as my companion:
IntelliJ and I have a love hate relationship. Over the past few weeks, we’ve spent a lot of time getting to know each other. Sometimes, the late night bonding sessions really pay off: he tells me exactly what I want to hear. Other times, he mocks me with his stubbornness and refuses to cooperate no matter how much I beg and plead.
Specifically, the one constant problem IntelliJ and I always disagree on is returning a boolean from a for loop. For example:
All I want to know is if the input color is a primary color, but clearly IntelliJ is not happy with me. I have not done what he wants me to do. The red squiggly line has declared that I have no stated what value I want to return. I must be going crazy though, because I swear I stated what values to return!
Times like this, he reminds me of my first computer user interface nemesis, Clippy. Clippy was a know-it-all who always butted in and read everything I wrote, even when I told him to mind his own business. When I was in fifth grade, I used Microsoft Office to write my diary entries. Clippy never failed to creep me out and offer to help me “write a letter”. No Clippy, I do not need your help, I know how to write a letter.
The difference between Clippy and IntelliJ is, I can’t just ignore IntelliJ. There’s no point in being frustrated at him. Logically speaking, there’s a reason to his madness. He simply does not understand what I’m saying to him. It’s not his fault he’s not as smart as humans. So if IntelliJ is a child with primitive language vocabulary, how do I dumb it down for him?
Google to the rescue!
A quick search for “boolean array loop” gave me hope, and joy, and satisfaction, and excitement, and hunger for more! The Array class has its own methods!
And with that, IntelliJ understood me. He knows what he has to do now. This breakthrough between us has made me love him again. Surprisingly, this one little code has helped me in many other projects. Need to know if a word is a preposition? Create isPreposition. Is the user input entered a legitimate answer you were asking for? Create isChoice. Did I already guess that letter in Hangman? Okay, I’ll stop.
According to Zoltán Hosszú, there are three stages in the circle of learning: Excitement, Struggle, and Solution. I am currently riding that wave of energy you get from Solution back into Excitement. And it feels soooo good.