Header Ads

java programming tutorials in hindi: keywords in java programming - boolean,byte,if, else,interface,abstract class,public,private,protected hindi me jane

what is keyword in java programming language

keywords वे tokens होते है जिनका java program में एक special meaning होता है और ये programmer के द्वारा variable और method के नाम के लिए उपयोग नही किये जा सकते है .
इनकी संख्या java में fix होती है

  what is keywords in c/c++ hindi में जाने



java 1.1 – 50
java 1.2 – 51
java 1.4 -52
java 1.5 -54

keywords used in java 1.1

boolean : declare a Boolean variable or return type
Byte :- declare a byte variable or return type
Char :-declare a character variable or return type
Double :- declare a double variable or return type
Float :- declare a floating point variable or return type
Short :- declare a short integer variable or return type
Void :-declare that a method does not return a value  
Int :- declares an integer variable or return type
Long :- declares a long integer variable or return type
While :- begins a while loop
For :- begins a for loop
Do :- begins a do while loop
Switch :- tests for the truth of various possible cases
Break :- prematurely exits a loop
Continue :- prematurely retunt to the begging of a loop
Case :- one case in a switch statement
Default :- default action for a switch statement
If :-execute statement if the condition is true
Else :-single the code to be executed if an if statement is not true
Try:- attempt an operation that may throw an exception
Catch :- handle an exception
Class :- singles the beginning of a class definition
Finally :- declares a block of code guaranteed to be executed
Abstract :-declares that a class or method is abstract
Extends :-specifies the class which this class is a subclass of
Final :-declare that a class may not be subclassed or that a field or method may not be overridden
Implements :- declare that this class implements the given interface
Import :- permit access to a class or group of classes in a package
Instanceof :- tests whether an object is an instanceof a class
Interface :- signals the beginning of an interface define
Native :- declare that a method is implemented in native code
New :- allocates a new object
Package :- defines the package in which this source code file belongs
Private :- declares a method or member variable to be private
Protected: -declares a class , method or member variable to be protected
Public: :- declares a class , method or member variable to be public
Return :- return a value from a method
Static :-declares that a field or method belongs to a class rather than an object
Super :- a reference to the parent of the current object
Synchronized :- includes that a section of code is not thread – safe
This :- a reference to the current object
Throw :- throw an exception
Throws :-declares the exception thrown by a method
Transient :- this field should not be serialized
Volatile :- warns the compiler that a variable change asynchronously.


ये सभी keyword पहले से ही defined है इनके नाम से कोई  variable या फिर किसी function का नाम नही रख सकते है
                            
                                 thanks

    

No comments

Powered by Blogger.