Connect with us

Published

on

Java – Hello guys am here to teach you about the basics of java (programming language) and am 100% sure you will understand this because it has been broken down to an easy definition..

What is java
Java is a programming language that produces software for multiple platforms

Basics of java programming
              WHAT IS A CLASS
A class is the blueprint of a system where everything you are building is storedy
              WHAT IS AN OBJECT
An object is an instance of a class eg
Classname          Objectname=      Newclass Name
e.g House Dapo = new House();
             ACCESS MODIFIER
Public
private
protected
A class must not have the below fault:
A lower case
A symbol
           TYPES OF DATA TYPE
Int
String
Double
Float
Boolean
Char
We have two types of data type:
Primitive data type
Reference data type
Primitive data type: Int, double, float, Boolean, charReferrence data type: String
               WHAT IS A METHOD
A method is formally known as function
               TYPES OF METHOD
Built In method
Custom method
A class includes data members and methods
methods can include expressions that evaluate the value, you can declare a class without data variables and methods.
You can access data members outside the class through class object
+ means congatination(simply means adding
   
Types of access modifiers
Static
final
abstracts
native
synchronize
                What is a modifier
Modifier determines how the data methods and members are used in classes an d object. the main difference between access specifiers and modifiers is that is that access specifiers defines the accessibility of data members in a class while the modifiers  determines how the methods are used and modified by other classes




What is a static
it is used with methods variables and inner classes
The static keyword is used to define class variables and methods that belongs to the class and not to any particular instance to the class
                             
What is Final
the final keywords indicates that the data member cannot be modified s.it is used with methods, variables classes
                                         
What is abstract
an abstract class cannot be instanciated
Native keyword
the native keyword is used only with methods, it is used to to inform the compiler that the method has been coded in programming language other than java
Sychronised keywords
sychronised keywords is used for methods, the schychronised keyword controls the access to a block of codes in a multi trendend programming environment.
Methods
Methods are used to access the variables that are defined in  the class….you can use some methods that needs some extra informations for execution
What is oop
oop simply mean object oriented programming, it is a programming style which is associated with the concept like class object and inheritance
There are three major things that happen in  programming which are output, input and process
Forms of oop
inheritance
polymophysm
abstraction
encapsulation
                                                     
Types of inheritance
Single
multilevel
heirachical
hybrid

 What is encapsulation
Encapsulation is a mechanism where you bind your data and code together as a single unit…it simply means hiding your data and code in a safe place
Abstract class
it refers to the quantity of dealing with ideas rather than events. it deals with hiding details
Polymorphism
 polymorphism is the ability of an object to take on many forms

Types of polymorphism
Runtime polymorphism: it a process in which a call to an overridden method is resolved at runtime rather than at the time of compile
Compile time polymorphism: is a process in which a call to an  overloading methods..
Thank for reading the basics we will update you  with more tutorial as soon as possible

Click to comment

Leave a Reply