Since my boyfriend is a Computer Science major, he recommended that I take an introduction class in his field of study. Thus, I registered for CSE 110 this semester as a related elective to my Health Science major. At first, I thought it was the most useless course I have ever taken. But as the months went on, I found myself actually gaining useful knowledge about computers and basic programming.
As an extra credit project for this course, I had to write a program in Java (with the free program Eclipse) that randomly generated insults, using words from the infamous Shakespeare Insult Kit. In order to accomplish this, I had to utilize several types of code that I learned over the course of this semester. My final draft is as follows:
Here’s an example of what the program will look like when you run it, the green text being the user’s input. I basically put the majority of my code inside a While Loop, instructing the computer to run the program from the beginning as long as x=0 (which is terminated by typing “y”).
Writing this project was actually really enjoyable. It’s a shame that I can’t take any more computer science classes – it’s not required for my major. :'( Despite getting frustrated (often) when programming in Java, seeing the finished product of my hard work is so satisfying. :D