Tutorials

  • Class Methods in Java

    In object oriented programming, you consider the object which you are programming about, for example, a car. You then consider the attributes about the object, for example, the make, model, color, year built, etc. You also have consider the operations of the object. i.e. What can it do? A car for example could turn on…

  • Static Methods in Java

    Static methods in Java work on the same basic idea of static functions in other languages like C/C++. The idea is that sometimes you have a function that either needs to be shared between instances, instead of tied to a specific instance, or to be used without needing to create an object from the class…

  • Importing a Package

    Importing a package allows me to import a class, or set of classes into my application that I can use. (These will be outside of the package that I create for my own project.) These packages act like libraries in other languages where a lot of work might be done for you already, and you…

  • Java Arrays

    Arrays in Java are similar to C/C++ arrays, however there are some special unique things about them which make Java Arrays a little easier to work with in my opinion. Like in C/C++ you can have single dimensional or multidimensional arrays. Advantages to Arrays Like a C/C++ array, the array in Java is a contiguous…

  • Loops in Java

    Loops in Java work similarly to how you remember loops in C/C++ most likely. You have your counting loop (for), as well as your pretest conditional loop (while), and the conditional post test loop (do-while). Each of these work the same way you would expect them to in C/C++. For Loop The for loop is…

  • Console Output in Java

    Compared to some languages, you might find writing out basic output in Java…well…overly complex. However, once you understand Java, you will see that it is complex, but for a reason. Let’s first consider some languages you might have already seen. Each one of these prints “Hello World” to your console window. So how does Java…