This course of study builds on the skills gained by students in Java Fundamentals or Java Foundations to help advance Java programming skills. Students will design object-oriented applications with Java and will create Java programs using hands-on, engaging activities.
Step 1: Decide your Mind ...
Java Tutorial for Beginners
Programming with Srihari
I am Srihari, and I am currently pursuing Computer Science and
Engineering at Sona College of Technology. I am excited to
prepare and present the course notes on "Java Tutorial for
Beginners" to help students gain a fundamental understanding
of Java programming. During my initial years in college, I fell in
love with programming languages, and after exploring various
languages, I found that Java was quite fascinating. Not only
that, understanding and working in Java has numerous career
opportunities in software development. Through this course, I
intend to introduce the basics of Java programming, including
but not limited to its history, syntax, writing and running basic
programs, and popular development tools like Eclipse and
NetBeans. The course aims to provide a strong base for
beginners to work on more complex projects in the future.
The Anatomy of a Java Program
In this Java tutorial, we'll be looking at the basics of a Java
program. The smallest building block in Java programs are
functions. If a function is a block of code that performs a task,
think of the buttons on the remote control of your TV. Every
Java program should have at least one function and that
function is called main .
Writing Java Code
After the parentheses, we have a pair of curly braces and
inside these braces, we write the actual Java code. Every Java
program should have at least one function and that function is
called main . So, main is the entry point to our programs.
Whenever we execute a Java program, the main function gets
called and the code inside this function gets executed.
Downloading IntelliJ IDEA
IntelliJ IDEA is absolutely free and it's more than enough for
this course, so download it now.
Download IntelliJ IDEA
, A class is a container for related methods, so we use classes
to organize our code. By the same token, we have a concept
called package, and we use a package to group related
classes.
As our applications grow, we're going to end up with hundreds
or even thousands of classes, so we should properly organize
these classes into packages. The base package for a Java
project is the domain name of your company in reverse.
The code editor might look a little bit intimidating at first, but
trust me it's really easy and you're going to learn about it
throughout this course. For now, just type a base package for
your project; it can be your name or whatever, it doesn't really
matter.
Marsh has put together a comprehensive cheat sheet with
summary notes that you can download below this video.
IntelliJ is building our application and we can see the result in
this little terminal window. So, here's our "Hello World"
message. That was our first Java program.
Next, I'm going to explain how Java code gets executed under
the hood.
IntelliJ uses the Java compiler to compile our code into a
different format called Java bytecode. This Java code is
platform-independent, meaning it can run on Windows, Mac,
Linux, or any operating system that has a Java Runtime
Environment. Java applications are portable, or platform-
independent.
Java was developed by James Gosling in 1995 at Sun
Microsystems, which was later acquired by Oracle in 2010.
Currently, close to 9 million developers worldwide use Java.
About 3 billion mobile phones run Java, as well as 120 million
TV sets and every Blu-ray player. The average salary of a Java
developer is just over $100,000 per year in the US.
This course is the first part of my complete four-part Java
series. Each part is about three to four hours long, so you can
easily complete it in a day or two. The first part will give you a
solid foundation on how to start programming in Java. In the
The benefits of buying summaries with Stuvia:
Guaranteed quality through customer reviews
Stuvia customers have reviewed more than 700,000 summaries. This how you know that you are buying the best documents.
Quick and easy check-out
You can quickly pay through credit card or Stuvia-credit for the summaries. There is no membership needed.
Focus on what matters
Your fellow students write the study notes themselves, which is why the documents are always reliable and up-to-date. This ensures you quickly get to the core!
Frequently asked questions
What do I get when I buy this document?
You get a PDF, available immediately after your purchase. The purchased document is accessible anytime, anywhere and indefinitely through your profile.
Satisfaction guarantee: how does it work?
Our satisfaction guarantee ensures that you always find a study document that suits you well. You fill out a form, and our customer service team takes care of the rest.
Who am I buying these notes from?
Stuvia is a marketplace, so you are not buying this document from us, but from seller srihariharan1. Stuvia facilitates payment to the seller.
Will I be stuck with a subscription?
No, you only buy these notes for $8.39. You're not tied to anything after your purchase.