Welcome!

By registering with us, you'll be able to discuss, share and private message with other members of our community.

SignUp Now!
  • Guest, before posting your code please take these rules into consideration:
    • It is required to use our BBCode feature to display your code. While within the editor click < / > or >_ and place your code within the BB Code prompt. This helps others with finding a solution by making it easier to read and easier to copy.
    • You can also use markdown to share your code. When using markdown your code will be automatically converted to BBCode. For help with markdown check out the markdown guide.
    • Don't share a wall of code. All we want is the problem area, the code related to your issue.


    To learn more about how to use our BBCode feature, please click here.

    Thank you, Code Forum.

Java An Explanation Of Java

Mathematical

Silver Coder
What Is Java?
Invented by James Gosling and a few other amazing programmers in at Sun Microsystems back in 1995/1996, Java is a multi-paradigm, object-oriented programming-language.

As stated, Java is a multi-paradigm language, but it's core paradigm is object-oriented. So, all of your "objects" store both data and methods. The data is of course, data. Integer values, strings, and all other types of variables and forms of data. But, the responsibility of your methods, is to manipulate(Change) this data(Commonly known as "Setters") or perhaps give access to the data(Commonly known as "Getters"). That's a simple way of putting things in OOP(Object-Oriented-Programming). Of course, OOP in itself, is a much larger topic waiting to be discussed at some point in the future. Keep an eye out on an explanation of that. Anyway, back to Java.

Just like many other languages, Java takes after the syntax of C. But due it being an object-oriented language, it also borrows some of its syntax from C++. So, C and C++ programmers rejoice, for you'll have a language similar to the ones that you currently know.

Java is one of the world's most popular programming-languages nowadays and has expanded from it's roots in being a language originally designed for the web.

History Of Java
The Java(Originally called "Oak" all thanks to a tree outside of James Gosling's office - This was later changed due to another piece of technology going by the same name) project was officially started back in June 1991 by Sun Microsystems enginners: James Gosling; Mike Sheridan; and Patrick Naughton. The language was originally designed to be used on television but Java at the time, was unfortunately too advanced for television at the time. Gosling designed the language with a syntax similar to that of C and C++, as many programmers at the time would find Java a familiar language.

The Java-Development-Kit(JDK) version 1.0 was officially released in 1996, with the promise that programmers could "Write once, run anywhere(WORA - This has become a signature trademark of Java)". After the release of Java, the JDK, and the JRE(Java-Runtime-Environment), many web-browsers such as NetScape and Internet-Explorer began implementing Java functionality into their browsers, allowing Java Applets(Java programs that could run in your browser) to be ran in the browser, which lead to Java becoming more popular for web-developers and Internet users at the time. Note that as of the release of JDK 9.0, Applets have since been deprecated and as of JDK 11.0, they've been removed completely. This was because Applets posed a threat to security, which also tarnished the reputation of Java. Java was released in several editions: Java SE(Standard-Edition) for developers writing and releasing code for desktop-applications and servers; Java ME(Micro-Edition) for developers working with limited resources; and Java EE(Enterprise-Edition), targeting large corporations and enterprises working with Java.

At some point in time, Java went to a couple of different standardising-bodies, but withdrew from both. Later on in 2006, Java began the process to becoming free-software(Free as in freedom, not free beer), being licensed under the GNU GPL, and releasing most of it's source-code to the public. This was finished sometime in 2007, aside from a small portion of code to which Sun Microsystems did not own the rights to. A free-variant of the proprietary JDK, is OpenJDK( ). Then between 2009 and 2010, Oracle Corporation acquired Sun Microsystems, acquiring Java, the JDK, and the JRE with it. A lawsuit against Google LLC. was filed not long after the acquisition all because of Google using Java in it's Android operating-system. This lawsuit is still going on till this very day.

Ever since it's acquisition by Oracle Corporation, Java has dramatically changed. Applets were dropped; Oracle adopted a rapid-release schedule for Java, releasing a new version every six months, and an LTS(Long-Term-Support) version every so often; and the world's view and usage of Java has changed dramatically too. While many hate it and many love it, Java has now become one of the world's dominant language, and will more than likely hold that throne for years to come.

Where Is Java Used?
Java is used in many applications of software and computing.

Many banks use Java to power it's systems, deal with it's calculations of transferring money into your account, and dealing with the transferring of money from one account to another. Many Android apps use Java, although this is changing due to Google adopting Kotlin and continuously pushing for its adoption among Android developers. Many desktop and web-applications are written in Java too: GMail's back-end is written in Java; the kid's block-based, building-game, Minecraft, is written in Java(Except for it's console and mobile-versions, which are in C++); and the now-defunct P2P service, LimeWire, was also written in Java.

How Can I Learn Java?
There are many ways of learning Java.

Of course, there is the web at your disposal. Sites like Codecademy offer courses in which you can learn the fundamentals of Java, but these won't go into too much detail of what goes on under the hood, or even explain the concepts of OOP. You may have to pay for some courses too. Some websites offer free tutorials, but these generally don't explain Java in a good enough sense for you to truly understand the language and what's going on.

Due to its popularity, Java is being taught to many CS students across the world. If you pick or have picked CS as your course for college or university, there is no doubt that you will have been taught Java, are soon to begin learning it, or are already in the process of learning it.

Last but not least, is another good way to learn Java(And any other language), and that's books. Books are a great way to learn things, as you may not have a teacher to teach you Java, you need to catch up on something, your teacher doesn't teach you or explain things well enough, or you just so happen to be teaching yourself Java with just the aid of a book and the Internet. Books explain Java in great detail, as they not only go over the syntax, good practices, and the ways of doing things in Java, but also explain how things work under the hood, and even the concepts of OOP, which is what you want.

My recommendation for books are: Java - A Beginner's Guide by Herbert Schildt and Core Java Volume 1 - Fundamentals by Cay S. Horstmann. Make sure to pick a version as recent as 2017, anything older than that, will probably be outdated and useless. The two books I've listed above are great from my experiences. Schildt in my opinion, does a good job of providing examples and explaining how to do things, and even explains things in a manner that is suitable for beginners to Java. Horstmann, goes more in-depth with Java, not only teaching you the ways of doing things, but also teaches you what goes on under the hood, and even the concepts of OOP - Thus' some may be a bit confused when reading his book on Java. If you're ever stuck in one book, go look in the other one to see if that can help. That is what I do and it does work. You can also receive help from others here on CF or any other programming site such as StackOverflow.

To begin working with Java, you'll need the JDK. I'm not going to go over how one does install the JDK and/or the JRE, but the books that I've listed above, and many online tutorials, provide guides on how to download the JDK and/or JRE for your operating-system. For GNU/Linux users, you'll more than likely have the OpenJDK packages installed. If not, it will probably be available in your distribution's repositories.

Thank you for reading this detailed explanation of Java. If you have any questions about the language, don't be afraid to ask, and I and many others will be able to help you.

In the meantime, while waiting for a response to your question, feel free to read through my explanations of other languages:
 
Last edited:

New Threads

Latest posts

Buy us a coffee!

Back
Top Bottom