Probably not the most entertaining post, but there are a couple of cool things about programming in Objective-C that I found interesting and thought I would share.
So basically the language was created in the early 1980s when a couple of people decided that reusability in code would be a good idea. If you don't know that much about programming (not that I know that much either) reusability in code basically means some kind of object orientated language. Now lets try to explain why objective programming languages are useful. . .
The very basic idea is that, lets say you wanted to draw five different boxes, each one a different color. But to draw a box you had to type four lines of code to define the location, size, rotation, and color. That means these five boxes would take 20 lines of code, which seems like a lot especially since the only thing that changes is the color. Well here comes object orientated programming to save the day. In objective languages you can create an object ( so that's where it gets its name) that has different properties that correspond to the different variables of your box. For example it would have a location property, a color property, etc. Now all you have to do is assign those properties a value which is a simple as saying
box.color = red.
In addition to that, if you ever need to make a box in a different program you have an object to do that. BAM! Reusability!
So basically these two guys thought this would be a good idea but also wanted it to be back compatible with the C language to make it more usable. So they did their thing and came up with a pretty good product. Then in 1988 NeXT (which is the computer company Steve Jobs started after being fired from Apple) bought Objective-C from the two guys and began writing a bunch of libraries which the NeXTstep operating system was built on. Because of this, objects in objective-C carry the prefix NS for NeXTstep. Once Apple realized they were doomed with out Steve Jobs, they brought him and NeXT back to Apple and Mac OS X (which is the operating system still being used by Macs, just on version 10.8 or whatever it is now) is built on the NeXTstep operating system.
So, long story short, if you've ever programmed in objective C and had to type "NSString" or "NSLog" now you know where that NS is coming from.
There are lots of other cool things about Objective-C, but this post got a little longer than I wanted so I won't really go into that. I just thought it was kinda cool that even today, programming stuff for iPhone 6s and iOS 7, the prefix is from a computer company that doesn't even exist anymore.
So yeah, I hope you enjoyed that and maybe you even learned something.
As always, Thanks for reading
[Full disclaimer: I'm not a Computer Science major and may not have a clue what I'm taking about when describing what an object orientated programming language is. My example may be better suited to describe the physics behind the flight of elephants (although being a mechanical engineer, I can say with some certainty that it probably isn't describing that either)]