Skip to main content

Posts

Showing posts from July, 2017

Variables and Data Types in Java

#Topic-5 Previous topic (4) we have discussed about how to start coding! , we have gone through our first Java Program line by line. If you have not gone through that topic, click this link  Your First Java Program: Hello World In this section we will discuss about variable , Data types , Literals and many more! Variable Variable is name of reserved area allocated in memory . In other words, it is a name of memory location . It is a combination of "vary + able" that means its value can be changed.   Example:   int value= 10 ; //Here value is variable float a= 10.50 ; //Here a is variable   There are three major types of variables in java: local variable instance variable static variable 1) Local Variable : A variable which is declared inside the method is called local variable. 2) Instance Variable : A variable which is declared inside the class but outside the method, is called instance variable . It is not declare...

Your First Java Program: Hello World

#Topic4 Previous Topic (2&3) we have discussed about how to get started with Java Programming with different tools or techniques. If you have not gone through that topic, click this link What is the software’s needed to start JAVA programming Or How to Install Eclipse and Get Started with Java Programming. In this section we will discuss about coding part! .Whether you are an experienced programmer or not, this topic is intended for everyone who wishes to learn the Java programming language from ground level. Let's go over the Hello world program, which we have already written and executed in our previous topic using notepad as well as eclipse, it’s just display the message "Hello, World!" on the screen. public class HelloWorld { public static void main(String[] args) { System.out.println("Hello, World!");   } }   We break the process of programming in Java into three steps, we have already covered these are all...