Skip to main content

Failing At Life

What on earth is going on here? I don’t have any idea of what to think or say. Life is getting in the way to be honest, but I wish it wasn’t. I wish it was being kinder to me. It needs to be kinder to me. Somehow I’m failing at life. I just don’t know what to do about any of it.

KISS

Keep It Simple Stupid (No Really)

From time to time I find it amusing what kind of code can be written and what code actually gets passed through to a production setting. Most of the time it’s something I’ve written myself. Ever look back to a project you worked on a long time ago? That’s a scary thought now isn’t it? You take a look back and go… how did that ever work? You also might think, what in the world was I thinking when I coded that?

Awful Markup

Back when I first started learning HTML it was the standard to have all of your tags in uppercase. Uppercase! I suppose someone wanted to establish content from presentation or structure. Yeah structure. HTML isn’t a presentation layer, that would be CSS. Looking back at that code I cringe. Why would anyone ever even want to code in all uppercase? It didn’t make any sense. Not only does it hurt the eyes to look at it, but it’s also hard to read.

Method Lengths

How long should a method be exactly? I’ve read that methods should be a few lines long. Don’t write hundreds of lines in a single method. You’d go crazy nuts trying to find a bug in there! No really. Be like searching for a needle in a haystack. Don’t try it. You’ll go blind.

Just keep your methods/functions short and simple. I’d rather look at several methods with a few lines of code than a few methods with lots of lines of code in them. What’s going on where? Make it easy and simple to understand.

Comments

Make your code self documenting. Don’t flood it with unneccessary comments. If you want a method to return a string in HTML format, name it like that. Instead of getContent() call it getContentAsHtml(). Makes sense right? Whoever is looking at the source code later on down the line won’t wonder what format the content will be returned as.

Documentation

Provide adequate documenation. Don’t write novels with your documentation. But write what is needed to get someone started. You know how projects have a two minute get started guide? Yep do that. If it’s a Java project, have Javadocs available for it. You don’t want to have your users in the dark about what your project does.

Write Tutorials Smart

If you’re going to write a website that contains tutorials. Um, keep them simple and easy to follow. Also keep with the actual current standards. I should say that again. Keep with the current standards.

An example of this. Years ago, it was typical to have your HTML markup in uppercase. That isn’t the case anymore (no pun intended… or was there?). No realy though. Do not put your HTML in upper case. Don’t! It’s bad. You will be looked down upon so bad. So very very bad. Keep current with whatever language you’re running with and be good at it. Seriously do it. You can deprecate things, that’s just fine. Most languages have a way to do that. Use it!

Comments

Popular posts from this blog

Didn't Sleep

 What's the point of sleep anymore if I can't sleep? I don't think I slept any good last night. I was awake at 3 am wondering to myself, what on earth am I doing awake? Yeah, that happened. It doesn't make any sense. Fortunately, it's the weekend. So, I can catch up on sleep tonight. I don't have to be anywhere tomorrow, so it's a good opportunity to actually sleep for once. Whatever the case, I hope I'll be able to fall asleep and stay asleep. We will see what happens.

Temptation Bible vs Book of Mormon

In the Bible in 1 Corinthians 10:13 we find: There hath no temptation taken you but such as is common to man: but God is faithful, who will not suffer you to be tempted above that ye are able ; but will with the temptation also make a way to escape, that ye may be able to bear it. But what might seem as a contradiction is found in Alma 13:28 But that ye would humble yourselves before the Lord, and call on his holy name, and watch and pray continually, that ye may not be tempted above that which ye can bear , and thus be led by the Holy Spirit, becoming humble, meek, submissive, patient, full of love and all long-suffering; So, which is it? Either God tempts you to a point and stops, or you have to actively pray not to be tempted beyond that no return point. Which is it?

An Opposition In All Things

Long has been the story told about how there must be an opposition in all things. From the pre-existence there was Satan, Lucifer the Son of the Morning. In the beginning we were with God in his presence. We learned all we could while there. Until the moment we couldn’t progress any more, we were unable to become like God. So, we were given the opportunity to come to Earth to gain a body. A Savior would be provided to atone for our sins enabling us to come back to the presence of God. The idea that an opposition must be in all things comes from 2nd Nephi: For it must needs be, that there is an opposition in all things. If not so, my firstborn in the wilderness, righteousness could not be brought to pass, neither wickedness, neither holiness nor misery, neither good nor bad. Wherefore, all things must needs be a compound in one; wherefore, if it should be one body it must needs remain as dead, having no life neither death, nor corruption nor incorruption, happiness nor misery, neither...