Search This Blog

Read Your Language

Showing posts with label JAVA. Show all posts
Showing posts with label JAVA. Show all posts

JAVA से जुड़ी कुछ बेसिक जानकारी


JAVA  से जुड़ी कुछ बेसिक जानकारी जिसे आप जानकर हैरान रह  जाएेंगे की Java  लैंग्वेज का नाम किस प्रकार पड़ा  तो चलिए दोस्तों  शुरु  करते  है।  आज के अध्ययन में हम JAVA के महत्त्वपूर्ण बात को जानेगे | 

JAVA का नाम एक  आइसलैंड पड़ा जो की इंडोनिशिया में स्थित है | आप यह  भी कह सकते है जावा (JAVA) एक कॉफ़ी का प्रकार (Type ) है |

जावा को सबसे पहले  डेवलप्ड (Developed )  James  Gosling  ने 1991 में अपने Professional Team के साथ  Sun  Microsystems  में की | जावा को सबसे पहले ओक (Oak ) नाम दिया गया था जोकि जेम्स गोसलिंग के ऑफिस के बहार एक Oak  Tree  के नाम पर था जोकि कुछ सफ्ताह बाद इसका नाम  बदल कर ग्रीन  कर  दिया गया था |  फिर कुछ समय बाद इसका नाम बदल फिर जावा रखा दिया  गया | अंत में इसका नाम जावा पड़ा जो जावा का नाम एक क्रमबद्ध सूचि में से लिया गया था |




Control Statement in JAVA



          आज हम Control  Statement  सीखने जा रहे है आखिर  Control  Statement   होता क्या है आखिर जावा के अंदर control  Statement कैसे प्रयोग करते है   और इसका क्या काम होता है जावा  अंदर  तो चलिए दोस्तों शुरू  करते है आज का अध्याय जिमसे हम सीखेंगे की Control  Statement के बारे में  | 

Control Statement 

कण्ट्रोल स्टेटमेंट जो की यह डिफाइंड करता है हमारे द्वारा गए स्टेमेंट या तो True  होगा या False  होगा | 
हम True  के  लिए if  स्टेटमेंट का प्रयोग करते है और False  के लिए   else का प्रयोग करते है | 
अपने C & C ++ के अंदर if   & else   स्टेटमेंट (Statement ) का प्रयोग किया होगा | 

For example :



Control Statement in Java 
C in  the progrom of Control Statement

#include<stdio.h>
main(){

int a, b;
printf(" Enter the any two numbers" );
scanf(" %d%d",&a,&b);
if (a<b)
{
printf(" b greater than a");
}
else 
{
printf(" a greater than b" );
}

}

Output:

Enter the any two numbers
3 5
b greater than a

तो चलिए  शुरू करते है जावा के अंदर Control  Statement  का एक प्रोग्राम जिसमे हम यह सीखेंगे की आखिर जावा के अंदर कण्ट्रोल स्टेटमेंट  का प्रोग्राम कैसे लिखते है |  
प्रोग्राम आपको निचे दिए गया है :-

public class ControlStatement 
{
public static void main(String[] args) 
        {
     int a=5;
     int b=41 ;
    if( a<b)
    {
        System.out.println("b greater than a. ");
    }
    
    else
    {
        System.out.println("a greater than b.");
 
    }
    
}
}

Output:

b greater than a. 

Arthemetic Operation in JAVA



                    Arthemetic Operation in JAVA (+,-,*,/)

       आज अध्याय में हम सीखेंगे की आखिर जावा के Program के अंदर हम कैसे Arithmetic  Operation करते है  तो चलिए दोस्तों शुरू  करते आज का यह अध्याय | 


1. Addition 


class  Addition{
public static void main (String args  [] )
{
     int a=5;
     int b=9;
     int c= a+b;
     System.out.println(" Addition is =" + c);

}
}


Output:
 Addition is = 14

 नोट : आपको प्रोग्राम के आउटपुट निकलने से पहले आप यह Confirm  कर ले हमारे फाइल का नाम हमारे Class के नाम के जैसा ही है |
उदहारण के लिए ,
File name : Addition.java
Class  name : Addition
हम आपको यह बता दे की आप फाइल  Name  से अलग क्लास (Class ) का नाम का बन सकता है | लेकिन  आपको इससे complie  करते समय क्लास का नाम याद रखना पड़ेगा |


2 . Subtraction 

class  Subtraction {
public static void main (String args  [] )
{
     int a=9 ;
     int b=5 ;
     int c= a-b;
     System.out.println("Subtraction  is =" + c);

}
}

Output:
Subtraction  is = 4

3. Multipication


class  Multipication{
public static void main (String args  [] )
{
     int a=5;
     int b=9;
     int c= a*b;
     System.out.println(" Multipication is =" + c);

}
}

Output:
Multipication is = 45

4. Division 


class  Division  {
public static void main (String args  [] )
{
     int a=9;
     int b=3;
     int c= a/b;
     System.out.println(" Division is = " + c);

}
}

Output:
Division is = 3



INTRODUCTION OF JAVA


INTRODUCTION OF JAVA 
            
 JAVA is   a  programming  Language .It developed by language is Sun Microsystem . It initiated  by James Gosling in 1995. 

Benefit of work Java : Write Once, Run Anywhere. 

Famose Text editors of  Java :

  1. Eclipse
  2. MS Notepad
  3. Netbeans
  4. Notepad++
  5. Java JDK 8

 MY FIRST JAVA PROGRAM

public class  java_program //   java_program is class name
{

public static void main (string args[])
{
  
System.out.println("my first java program in Java.");

}

Output:

my first java program in Java.




L-1. OBJECT ORIENTED METHODOLOGY

 OBJECT ORIENTED METHODOLOGY

PARADIGMS OF PROGRAMMING LANGUAGES:

The term paradigm describes :-

  1.   A set of techniques, 
  2.   Methods,
  3.   Theories and
  4.   Standards that together represent a way of thinking for problem solving. 
According to [Wegner, 1988], paradigms are “patterns of thought for problem solving”.
Paradigms has two kings of programming language :
  1. Imperative Paradigms: Imepartive means "expressing a command or order".Thererfore this  programming languages in this category specify the step-by-step explanation of command. Imperative programming defined  the  how to program obtain the result.
         There are two kinds of impartive Paradigms :
  • Procedural                         :  e.g-Pascal,C
  • Object Oriented                :  e.g-C++, Simula,Java

   2. Decalrative  Paradigms:  Decalrative  programming defined  that  what  should be  required  of the program because you  easily find the result.

       There are two kinds of Declarative Paradigms :
  • Functional                            :  e.g-Lisp
  • Logical                                  :  e.g-Prolog





Contact Form

Name

Email *

Message *

Followers