<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:dc="http://purl.org/dc/elements/1.1/">
  <channel>
    <title>DEV Community: Ranjith Ranjith</title>
    <description>The latest articles on DEV Community by Ranjith Ranjith (@ranjith_ranjith_).</description>
    <link>https://dev.to/ranjith_ranjith_</link>
    <image>
      <url>https://media2.dev.to/dynamic/image/width=90,height=90,fit=cover,gravity=auto,format=auto/https:%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Fuser%2Fprofile_image%2F3186683%2F1cc58982-6450-484f-9d79-6e29483a9112.jpeg</url>
      <title>DEV Community: Ranjith Ranjith</title>
      <link>https://dev.to/ranjith_ranjith_</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://dev.to/feed/ranjith_ranjith_"/>
    <language>en</language>
    <item>
      <title>this and super</title>
      <dc:creator>Ranjith Ranjith</dc:creator>
      <pubDate>Wed, 04 Jun 2025 13:01:31 +0000</pubDate>
      <link>https://dev.to/ranjith_ranjith_/this-and-super-392c</link>
      <guid>https://dev.to/ranjith_ranjith_/this-and-super-392c</guid>
      <description>&lt;p&gt;this&lt;br&gt;
this refers to a reference of the current class.&lt;br&gt;
    Java Object-Oriented Pr&lt;br&gt;
this Keyword in Java&lt;br&gt;
The this keyword in Java is a reference variable that refers to the current object.&lt;br&gt;
     It is used within an instance method  to access members of the current object such as instance variables, methods, .&lt;/p&gt;

&lt;p&gt;Usage&lt;br&gt;
The this keyword is primarily used in the following scenarios:&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt; *To refer to the current class instance variable.
  *
    *To pass the current object as a parameter to a method.
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;

&lt;p&gt;To return the current object from a method.&lt;br&gt;
Ex &lt;br&gt;
public class ThisExample {&lt;br&gt;
    int a;&lt;br&gt;
    int b;&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;ThisExample(int a, int b) {
    this.a = a;
    this.b = b;
}

void display() {
    System.out.println("a: " + this.a + ", b: " + this.b);
}

public static void main(String[] args) {
    ThisExample obj = new ThisExample(10, 20);
    obj.display();
}
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;

&lt;p&gt;Super ::&lt;br&gt;
super Keyword in Java&lt;br&gt;
The super keyword in Java is used to refer to the immediate parent class object. &lt;br&gt;
     It is commonly used to access parent class methods and constructors, enabling a subclass to inherit and reuse the functionality of its superclass.&lt;/p&gt;

&lt;p&gt;Usage&lt;br&gt;
       *To access a method from the superclass that has been overridden in the subclass&lt;/p&gt;

&lt;p&gt;To be discus ::To &lt;em&gt;invoke&lt;/em&gt; the current class method.&lt;/p&gt;

&lt;p&gt;Reffer ::&lt;a href="https://www.datacamp.com/doc/java/this" rel="noopener noreferrer"&gt;https://www.datacamp.com/doc/java/this&lt;/a&gt;&lt;/p&gt;

</description>
    </item>
    <item>
      <title>typecasting</title>
      <dc:creator>Ranjith Ranjith</dc:creator>
      <pubDate>Sun, 01 Jun 2025 15:20:55 +0000</pubDate>
      <link>https://dev.to/ranjith_ranjith_/typecasting-28f9</link>
      <guid>https://dev.to/ranjith_ranjith_/typecasting-28f9</guid>
      <description>&lt;p&gt;1)  norowning  (long-&amp;gt;byte)&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;  1) arrowing in Java, also known as explicit type casting or downcasting, involves converting a value from a larger data type to a smaller one. 
  2)This process requires explicit syntax because it can potentially lead to data loss or precision reduction.
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;

&lt;p&gt;Why is it needed in arrowing?&lt;br&gt;
Memory Management:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;When dealing with , using smaller data types can optimize memory usage.
Specific Operations:

&lt;ul&gt;
&lt;li&gt;some operations might require specific data types, necessitating a conversion even if it's a narrowing one. 
Data Loss:

&lt;ul&gt;
&lt;li&gt;Narrowing can result in loss of precision (e.g., decimal part truncation) or unexpected values due to overflow.
*Careful Usage:
Use narrowing conversions with caution, ensuring that the potential loss of data is acceptable for your specific use case.
ex:
double d = 123.45;
int i = (int) d; // i will be 123 (decimal part is truncated)&lt;/li&gt;
&lt;/ul&gt;


&lt;/li&gt;

&lt;/ul&gt;

&lt;/li&gt;

&lt;/ul&gt;

&lt;p&gt;broadning (int-&amp;gt;long)&lt;/p&gt;

&lt;p&gt;also known as implicit conversion or upcasting, in Java refers to the automatic conversion of a smaller data type to longer date type &lt;/p&gt;

&lt;p&gt;Ex &lt;br&gt;
    int myInt = 10;&lt;br&gt;
    long myLong = myInt; // Implicit conversion from int to long&lt;br&gt;
    double myDouble = myInt; // Implicit conversion from int to double&lt;br&gt;
Access modifiers &lt;br&gt;
    access modifiers are essential tools that define how the members of a class, like variables, methods, and even the class itself can be accessed from other parts of our program.&lt;/p&gt;

&lt;p&gt;Types of Access Modifiers&lt;br&gt;
    There are 4 types of access modifiers available in Java: &lt;/p&gt;

&lt;p&gt;Default &lt;br&gt;
Private&lt;br&gt;
Protected&lt;br&gt;
Public&lt;/p&gt;

&lt;p&gt;Default &lt;br&gt;
     *declarations are visible only within the package (package private)&lt;br&gt;
 Private&lt;br&gt;&lt;br&gt;
    * declarations are visible within the class only&lt;br&gt;
Protected&lt;br&gt;&lt;br&gt;
      *declarations are visible within the package or all subclasses&lt;br&gt;
Public&lt;br&gt;&lt;br&gt;
      * declarations are visible everywhere&lt;/p&gt;

&lt;p&gt;Refffer tha webset&lt;br&gt;
&lt;a href="https://www.geeksforgeeks.org/strings-in-java/" rel="noopener noreferrer"&gt;https://www.geeksforgeeks.org/strings-in-java/&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;&lt;a href="https://www.w3schools.com/java/java_modifiers.asp" rel="noopener noreferrer"&gt;https://www.w3schools.com/java/java_modifiers.asp&lt;/a&gt;&lt;/p&gt;

</description>
    </item>
    <item>
      <title>Differents between float &amp; double</title>
      <dc:creator>Ranjith Ranjith</dc:creator>
      <pubDate>Sat, 31 May 2025 07:25:20 +0000</pubDate>
      <link>https://dev.to/ranjith_ranjith_/differents-between-float-double-3b3g</link>
      <guid>https://dev.to/ranjith_ranjith_/differents-between-float-double-3b3g</guid>
      <description>&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;float 
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;

&lt;p&gt;Purpose: float is designed to store fractional numbers or numbers with decimal points.&lt;br&gt;
       Size: It occupies 4 bytes (32 bits) of memory.&lt;br&gt;
        Precision: float offers approximately 6 to 7 decimal digits of precision. This means that after a certain number of decimal places, the value may become less accurate due to the limitations of its 32-bit representation.&lt;br&gt;
       Range: The approximate range for float is from 1.4E-45 to 3.4E+38. &lt;br&gt;
Literal Suffix: When assigning a literal value to a float variable, it is necessary to append the letter f or F to the number. &lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;    double 
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;

&lt;p&gt;Purpose: It is primarily used for storing decimal numbers that require a high degree of precision and a wide range of values.&lt;br&gt;
        This makes it suitable for scientific calculations, financial applications, and complex mathematical computations.&lt;br&gt;
    Size: A double occupies 8 bytes (64 bits) of memory.&lt;br&gt;
      Precision: It offers higher precision compared to the float data type, which is a single-precision 32-bit floating-point number.&lt;br&gt;
      Range: The approximate range for double values is from 4.9e-324 to 1.7e+308. &lt;br&gt;
      Default Choice: For most decimal values in Java, double is the generally recommended and default choice due to its balance of precision and range.&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;  Primitive data types are the fundamental building blocks for storing and manipulating data in the Java programming language. They are predefined by the language itself and represent basic values like numbers, characters, and true/false statements. Unlike non-primitive data types, they are not objects and don’t have any associated methods.
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;

&lt;p&gt;primitive data types offer a set of predefined, immutable building blocks for storing and manipulating fundamental values.&lt;br&gt;
   These simple and efficient types have fixed sizes, reside directly in memory for faster access, and avoid object overhead for memory efficiency.&lt;br&gt;
   However, their limited functionality and lack of inheritance capabilities mean they are well-suited for basic data operations but may not be ideal for complex data structures or advanced functionalities, which are better handled by non-primitive data types like classes and interfaces.&lt;/p&gt;

&lt;p&gt;Primitive data types in Java excel in performance and memory efficiency. &lt;br&gt;
      Their direct memory access, lack of object overhead, and smaller sizes allow for faster operations, comparisons, and manipulations by the CPU. Additionally, their efficient caching contributes to quicker retrieval. &lt;br&gt;
    Furthermore, since they don’t require object-related memory allocations, they consume less memory compared to non-primitive data types. &lt;br&gt;
   However, it’s essential to remember that choosing the right data type involves a balance between performance and memory usage.&lt;br&gt;
     While primitive types offer these advantages, their capabilities and range may be limited compared to non-primitive types like String. &lt;br&gt;
    Therefore, selecting the appropriate data type requires careful consideration of both performance requirements and memory constraints.&lt;/p&gt;

&lt;p&gt;Primitive Data Types &lt;/p&gt;

&lt;p&gt;byte: Stores small whole numbers (8 bits) ranging from -128 to 127.&lt;br&gt;
   short: Stores whole numbers (16 bits) ranging from -32,768 to 32,767.&lt;br&gt;
   int: The most commonly used integer type (32 bits) with a range of -2,147,483,648 to 2,147,483,647.&lt;br&gt;
  long: Stores larger whole numbers (64 bits) ranging from -9,223,372,036,854,775,808 to 9,223,372,036,854,775,807.&lt;br&gt;
   float: Stores single-precision floating-point numbers (32 bits) for decimal values, offering less precision than double.&lt;br&gt;
   double: Stores double-precision floating-point numbers (64 bits) for decimal values, offering more precision than float.&lt;br&gt;
  char: Stores single characters using Unicode (16 bits).&lt;br&gt;
boolean: Represents true or false (1 bit).&lt;/p&gt;

&lt;p&gt;Float and double are two primitive data types in Java that are used to store floating-point numbers. Floating-point numbers are numbers that can have a decimal point, such as 3.14159 or 1.23456789e10.&lt;/p&gt;

&lt;p&gt;Float is a 32-bit floating-point number, which means that it can store up to 7 decimal digits accurately. &lt;br&gt;
   Double is a 64-bit floating-point number, which means that it can store up to 15 decimal digits accurately.&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;Float
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;

&lt;p&gt;The float keyword in Java is a primitive data type, and its size limit is 4 byte or 32 bits (1 byte = 8 bits) single-precision IEEE 754 (Standard for Floating-Point Arithmetic) floating-point number, that is it can allow up to 6 digits precision after the decimal. &lt;br&gt;
 We use this float keyword to declare the variable and methods. It usually stores the value in decimals or fractions. &lt;br&gt;
  We use this Float data type, if we want to use the memory efficiently, or if the number is in the small range. As the Float consumes less memory in comparison to the Double data type. By default, Java treats any decimal or float numbers as double type, so in case, if we want to define any value as float, we need to manually typecast it using the 'f' or 'F' keyword in the suffix of the number.&lt;/p&gt;

&lt;p&gt;For example, if we define a float number as:&lt;/p&gt;

&lt;p&gt;float weight = 70.645;&lt;/p&gt;

&lt;p&gt;In the above code in Java, the declaration of the float variable will throw a compilation error of possible lossy conversion from double to float, but we can fix the error by adding the character 'f' or 'F' in the suffix of the number.&lt;/p&gt;

&lt;p&gt;float weight = 70.645f;&lt;br&gt;
or&lt;br&gt;
float weight = 70.645F;&lt;/p&gt;

&lt;p&gt;double&lt;br&gt;
The double keyword in Java is also a primitive data type, and its size limit is 8 byte or 64 bits double-precision IEEE 754 floating-point number, that is it can allow up to 15 digits precision after the decimal. . We often use this keyword when we have a larger floating value and if we want a more precise and accurate value. As the Double data type consumes more memory in comparison to the Float data type, but it gives more accurate values of up to 15 digits of precision than the float data type. By default, Java considers any decimal or float values of double type, so we do not need to typecast any decimal value to double manually. Hence, adding the suffix 'd' or 'D' in the number is optional in the case of Double data type values.&lt;/p&gt;

&lt;p&gt;For example, we define a double number as:&lt;/p&gt;

&lt;p&gt;double weight = 70.6458763;&lt;br&gt;
or&lt;br&gt;
double weight = 70.6458763d;&lt;br&gt;
or&lt;br&gt;
double weight = 70.6458763D;&lt;/p&gt;

&lt;p&gt;Key Difference Between Float and Double in Java&lt;br&gt;
The main difference between Java Float and Double is their precision and range.&lt;/p&gt;

&lt;p&gt;Float is a 32-bit floating-point number, which means that it can store up to 7 decimal digits accurately while Double is a 64-bit floating-point number, which means that it can store up to 15 decimal digits accurately.&lt;/p&gt;

&lt;p&gt;Second major difference lies in their memory usage. Double variables take up twice as much memory as float variables.&lt;/p&gt;

&lt;p&gt;Difference Between Float and Double in Java&lt;br&gt;
Now let us look at the Float vs Double comparison table.&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;BASIS FOR COMPARISON Floatand   Double 
 Definition The float keyword in Java is a primitive data type, single-precision 32-bit.    
The double keyword in Java is a primitive data type, double-precision 64-bit
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;

&lt;p&gt;Usage   The float data type is less precise, that is, it is used where accuracy is not a big factor, and storage is limited.&lt;br&gt;&lt;br&gt;
    The double data type is more precise, that is, it is used where accuracy is a big factor, and we want to avoid data compression or bit loss.&lt;br&gt;
      Storage:  The float data type consumes 4 byte or 32 bits for storing a variable&lt;br&gt;&lt;br&gt;
The double data type consumes 8 byte or 64 bits for storing a variable&lt;br&gt;
Benefits&lt;br&gt;&lt;br&gt;
      The float data type have ample support libraries. Open source and community development.  The double data type has more uses for web development, and is more web focused&lt;br&gt;
Academics   The float data type is a 32-bit IEEE 754 floating point A double is a 64-bit IEEE 754 floating point.&lt;br&gt;
Precision   The float data type precision is up to 6 to 7 decimal digits.   The double data type can provide precision up to 15 to 16 decimal digits.&lt;br&gt;
Range   The float data type range lies between 3.4e-038 to 3.4e+038, and it has a lower range as compared to the double data type.  The double data type range lies between 1.7e-308 to 1.7e+308, and it has a higher range as compared to the float data type.&lt;br&gt;
      Keyword Used  To define a number as float, we mention the float keyword.  To define a number as double, we mention the double keyword.&lt;br&gt;
Wrapper Class   The float data type wrapper class is java.lang.Float.   The double data type wrapper class is java.lang.Double.&lt;br&gt;
   Default Data Type    Java does not use float as the default data type for floating point numbers.    Java use the double as the default data type for floating point numbers.&lt;br&gt;
Data Loss   If we convert any float type value from float to double, there will be no data loss.    If we convert any double type value from double to float, there will be data loss.&lt;br&gt;
       Suffix   The float data type uses 'f' or 'F' as a suffix. It is mandatory to mention the suffix if we want the number to be of float type.   The double data type uses 'd' or 'D' as a suffix. It is not mandatory to mention the suffix if we want the number to be of double type.&lt;br&gt;
Representation  28.96f or 28.96F    12.5 or 12.5D or&lt;/p&gt;

&lt;p&gt;Reffer&lt;br&gt;
Www.Scaler.com&lt;/p&gt;

&lt;p&gt;Float vs Double —  Explanation:&lt;br&gt;
Size :4 bytes   8 bytes.&lt;br&gt;
Accuracy: 7 digits approx ,15 digits approx.&lt;br&gt;
  Speed: Faster (uses less memory)  Little slower (more memory used)&lt;/p&gt;

&lt;p&gt;Example:&lt;/p&gt;

&lt;p&gt;float a = 3.1415926f;    &lt;/p&gt;

&lt;p&gt;double b = 3.141592653589793;&lt;/p&gt;

</description>
    </item>
    <item>
      <title>Day 7 (instance variable,local variable,static variable ,static method )</title>
      <dc:creator>Ranjith Ranjith</dc:creator>
      <pubDate>Fri, 30 May 2025 07:50:00 +0000</pubDate>
      <link>https://dev.to/ranjith_ranjith_/day-5-abstract--g2b</link>
      <guid>https://dev.to/ranjith_ranjith_/day-5-abstract--g2b</guid>
      <description>&lt;p&gt;1) What is an instance variable&lt;br&gt;
Instance variable is a variable declared inside a class, but outside methods, and it belongs to each object (instance) of that class.&lt;/p&gt;

&lt;p&gt;Every time you create a new object, a new copy of instance variable is created.&lt;/p&gt;

&lt;p&gt;2) Where is an instance variable declared&lt;br&gt;
Instance variable is declared inside the class, but outside any method.&lt;/p&gt;

&lt;p&gt;class Student {&lt;br&gt;
    String name;  // instance variable&lt;br&gt;
    int age;      // instance variable&lt;br&gt;
}&lt;br&gt;
3) Use of instance variable (Why useful)?&lt;br&gt;
To store object-specific data.&lt;/p&gt;

&lt;p&gt;Every object will have its own values.&lt;/p&gt;

&lt;p&gt;Example: Different students have different names and ages.&lt;/p&gt;

&lt;p&gt;Example:&lt;/p&gt;

&lt;p&gt;class Student {&lt;br&gt;
    String name;  // instance variable&lt;br&gt;
    int age;      // instance variable&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;// Constructor to initialize instance variables
Student(String n, int a) {
    name = n;
    age = a;
}

void display() {
    System.out.println("Name: " + name);
    System.out.println("Age: " + age);
}

public static void main(String[] args) {
    Student s1 = new Student("Arun", 20);
    Student s2 = new Student("Divya", 22);

    s1.display();
    s2.display();
}
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;

&lt;p&gt;}&lt;br&gt;
Output:&lt;/p&gt;

&lt;p&gt;Name: Arun&lt;br&gt;
Age: 20&lt;br&gt;
Name: divya&lt;br&gt;
Age:22&lt;/p&gt;

&lt;p&gt;Instance variable is a variable that is specific to an object (instance) of a class.&lt;br&gt;
Each object will have its own copy of that variable.&lt;/p&gt;

&lt;p&gt;Class is like a blueprint.&lt;br&gt;
  Object is something created using that blueprint.&lt;br&gt;
    Instance variable is the data stored inside each object.&lt;/p&gt;




&lt;p&gt;2) Where is an instance variable&lt;/p&gt;

&lt;p&gt;Instance variable is defined inside a class, but inside methods using self.&lt;/p&gt;

&lt;p&gt;class Student:&lt;br&gt;
    def &lt;strong&gt;init&lt;/strong&gt;(self, name, age):&lt;br&gt;
        self.name = name      # instance variable&lt;br&gt;
        self.age = age        # instance variable&lt;/p&gt;

&lt;p&gt;self.name and self.age are instance variables.&lt;/p&gt;

&lt;p&gt;They belong to a particular object of the Student class.&lt;/p&gt;

&lt;p&gt;3) Use of instance variable (Why it's useful)?&lt;/p&gt;

&lt;p&gt;To store data unique to each object.&lt;/p&gt;

&lt;p&gt;Example: Every student has different name and age — so you store them as instance variables.&lt;/p&gt;

&lt;p&gt;Example:&lt;/p&gt;

&lt;p&gt;class Student:&lt;br&gt;
    def &lt;strong&gt;init&lt;/strong&gt;(self, name, age):&lt;br&gt;
        self.name = name      # instance variable&lt;br&gt;
        self.age = age        # instance variable&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;def display(self):
    print("Name:", self.name)
    print("Age:", self.age)
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;
&lt;h1&gt;
  
  
  Creating objects (instances)
&lt;/h1&gt;

&lt;p&gt;student1 = Student("Arun", 20)&lt;br&gt;
student2 = Student("Divya", 22)&lt;/p&gt;

&lt;p&gt;student1.display()&lt;br&gt;
student2.display()&lt;/p&gt;

&lt;p&gt;Output:&lt;br&gt;
Name: Arun&lt;br&gt;
Age: 20&lt;br&gt;
Name: Divya&lt;br&gt;
Age:22&lt;/p&gt;
&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;  2] Local variable 
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;

&lt;p&gt;1) What is a Local Variable&lt;br&gt;
A local variable is a variable that is declared inside a method, constructor, or block, and it can be used only inside that method or block.&lt;/p&gt;

&lt;p&gt;2) Where is Local Variable&lt;br&gt;
Local variables are created inside methods and disappear when the method finishes. They are not accessible outside the method.&lt;/p&gt;

&lt;p&gt;3) Use of Local Variable &lt;/p&gt;

&lt;p&gt;Example &lt;/p&gt;

&lt;p&gt;public class Main {&lt;br&gt;
    public static void main(String[] args) {&lt;br&gt;
        int number = 10; // local variable&lt;br&gt;
        System.out.println("Number is: " + number);&lt;br&gt;
    }&lt;br&gt;
}&lt;br&gt;
        3] Static variable &lt;/p&gt;

&lt;p&gt;1) What is a static variable&lt;/p&gt;

&lt;p&gt;Tamil Explanation:&lt;br&gt;
static variable ஒரு class level variable. Object-ஓட property இல்ல. Class-ஓட common variable.&lt;/p&gt;

&lt;p&gt;class Example {&lt;br&gt;
    static int count = 0; // This is a static variable&lt;br&gt;
}&lt;/p&gt;

&lt;p&gt;3) Use of static variable&lt;br&gt;
     Static variable useful when you want to share common data between all objects.&lt;/p&gt;

&lt;p&gt;Ex.&lt;/p&gt;

&lt;p&gt;class Student {&lt;br&gt;
    int id;&lt;br&gt;
    String name;&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;// Static variable
static String college = "ABC College";

// Constructor
Student(int i, String n) {
    id = i;
    name = n;
}

void display() {
    System.out.println(id + " " + name + " " + college);
}
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;

&lt;p&gt;}&lt;/p&gt;

&lt;p&gt;public class TestStaticVariable {&lt;br&gt;
    public static void main(String[] args) {&lt;br&gt;
        Student s1 = new Student(1, "Ravi");&lt;br&gt;
        Student s2 = new Student(2, "Priya");&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;    s1.display();
    s2.display();
}
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;

&lt;p&gt;}&lt;/p&gt;

&lt;p&gt;Output:&lt;/p&gt;

&lt;p&gt;1 Ravi ABC College&lt;br&gt;
2 Priya ABC College&lt;/p&gt;

&lt;p&gt;college is a static variable&lt;/p&gt;

&lt;p&gt;Learn to Code, Prepare for Interviews, and Get Hired&lt;br&gt;
By DotNetTricks&lt;br&gt;
Learn to Code, Prepare for Interviews, and Get Hired&lt;br&gt;
By DotNetTricks&lt;br&gt;
Live Training&lt;br&gt;
Job Oriented Training&lt;br&gt;
DSA Problems&lt;br&gt;
Free Courses&lt;br&gt;
Free Books&lt;br&gt;
Membership Plans&lt;br&gt;
Explore&lt;br&gt;
Tutorials&lt;br&gt;
Cart&lt;/p&gt;

&lt;p&gt;Summer Sale is Live! Unlock 40% OFF on All Job-Oriented Training Programs – Limited Time Only! Offer Ending in00 D05 H30 M54 S Get Now&lt;br&gt;
Home&lt;br&gt;
Tutorials&lt;br&gt;
Java&lt;br&gt;
Types Of Variables In Jav..&lt;br&gt;
Types of variables in Java with examples: Local, Instance &amp;amp; Static&lt;br&gt;
Types of variables in Java with examples: Local, Instance &amp;amp; Static&lt;br&gt;
 27 May 2025&lt;br&gt;
 Beginner&lt;br&gt;
 15.3K Views&lt;br&gt;
 18 min read&lt;/p&gt;

&lt;p&gt;Learn with an interactive course and practical hands-on labs&lt;br&gt;
Free Java Course With Certificate&lt;br&gt;
A variable in Java is like a container or box that stores some values, such as numbers, text, or any data. You give the box a name, and you can use and change the value stored inside it during a program.&lt;/p&gt;

&lt;p&gt;In this Java tutorial, we'll get into the details of Java variables. Java Online Training is a convenient option for gaining expertise in Java and harnessing its power for various applications.&lt;/p&gt;

&lt;p&gt;Start coding with confidence—join our Java Certification Course for Free and gain hands-on experience.&lt;/p&gt;

&lt;p&gt;Read More - Top 50 Java Interview Questions For Freshers&lt;/p&gt;

&lt;p&gt;What is a Variable in Java?&lt;br&gt;
A variable in Java is a name for a memory location used to store data. It must be declared with a data type like int, String, or float. A variable in Java can hold only one type of data, and its value can be changed during the program. You should always initialize the variable before using it. Overall, variable in Java helps in storing, changing, and reusing data throughout the program.&lt;/p&gt;

&lt;p&gt;Declaration of Variable in Java&lt;br&gt;
A variable in Java is used to store different types of data like numbers, text, or true/false values. Based on the type of data, there are different ways to declare a variable in Java.&lt;/p&gt;

&lt;p&gt;String is used to store text, like "Hello World".&lt;br&gt;
int is used to store whole numbers without decimals, like 10 or 100.&lt;br&gt;
float is used to store numbers with decimal points, like 3.14 or 5.75.&lt;br&gt;
char is used to store single characters, like 'x' or 'y', and is always written in single quotes.&lt;br&gt;
boolean is used to store only two values: true or false.&lt;br&gt;
To declare a variable in Java, programmers must follow two main parts:&lt;/p&gt;

&lt;p&gt;Data type: This tells what kind of data the variable will store, such as int, float, or String.&lt;br&gt;
Variable name: This is the name you give to the variable, so you can use it later in your code.&lt;br&gt;
In short, declaring a variable in Java helps you store data in a proper format and use it again when needed.&lt;/p&gt;

&lt;p&gt;Rules for Declaring Variables in Java&lt;br&gt;
When you declare a variable in Java, you need to follow some simple rules to avoid errors. Let’s look at them one by one.&lt;/p&gt;

&lt;p&gt;A variable in Java must start with a letter (like a or B), a dollar sign ($), or an underscore (_). You cannot start it with other special characters like @ or #. int $count = 5; or int _total = 10; are valid.&lt;br&gt;
A variable in Java cannot have more than 64 characters in its name.int studentMarksInMathAndScience = 90; is okay, but avoid names that are too long.&lt;br&gt;
You are not allowed to use blank spaces in the name of a variable in Java.int student age = 20; is wrong. You should write it as studentAge.&lt;br&gt;
You cannot use Java's reserved keywords (like class, public, static) as variable names. int class = 10; is not allowed because class is a keyword.&lt;br&gt;
The name of the variable must come before the assignment operator (=). int age = 25; is correct, but 25 = age; is incorrect.&lt;br&gt;
Let's look at the variable declaration in our Java Playground.&lt;/p&gt;

&lt;p&gt;Example&lt;br&gt;
class Example&lt;br&gt;
{&lt;br&gt;
 public static void main ( String[] args )&lt;br&gt;
 {&lt;br&gt;
  long payAmount = 184; //the declaration of the variable&lt;/p&gt;

&lt;p&gt;System.out.println("The variable contains: " + payAmount );&lt;br&gt;
 }&lt;br&gt;
}&lt;br&gt;
Run Code &amp;gt;&amp;gt;&lt;br&gt;
Output&lt;br&gt;
Long payAmount = 184;&lt;br&gt;
Variable Initialization&lt;br&gt;
To initialize a variable in Java, there are three main components:&lt;/p&gt;

&lt;p&gt;Data type: It defines the type of data that will be stored, such as int, float, String, etc.&lt;br&gt;
Variable name: This is the specific name given to the variable so you can use it in the program.&lt;br&gt;
Value: This is the actual data that you assign to the variable when initializing it.&lt;/p&gt;

&lt;p&gt;Read More - Java Web Developer Salary&lt;/p&gt;

&lt;p&gt;Types of Variables in Java&lt;br&gt;
There are three main types of variables in Java: local variables, instance variables, and static variables, each used in different parts of a program&lt;/p&gt;

&lt;p&gt;Types of Variables in Java&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;Local Variables in Java
A local variable in Java can be declared inside a method, a constructor, or a block, and can be used within the method, constructor, or block.&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;Scope: A local variable is only accessible within the method, constructor, or block where it is declared. You cannot use it outside that block.&lt;br&gt;
Lifetime: The lifetime of a local variable is limited to the time the method or block is running. Once the block finishes, the variable is destroyed.&lt;br&gt;
Default Value: Local variables do not have a default value. You must initialize them before using, or it will cause a compile-time error.&lt;br&gt;
Example&lt;br&gt;
import java.io.*;&lt;br&gt;
class DNT&lt;br&gt;
{&lt;br&gt;
 public static void main(String[] args)&lt;br&gt;
 {&lt;br&gt;
  int var = 89; // Declared a Local Variable&lt;br&gt;
  // This variable is local to this main method only&lt;br&gt;
  System.out.println("Local Variable: " + var);&lt;br&gt;
 }}&lt;br&gt;
Run Code &amp;gt;&amp;gt;&lt;br&gt;
This demonstration in our Java Compiler illustrates the concept of local variables with a scope that is only the main method by declaring and initializing a local variable "var" with the value 89.&lt;/p&gt;

&lt;p&gt;Output&lt;br&gt;
Local Variable: 89&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;Instance Variables in Java
An instance variable in Java is a non-static variable declared inside a class but outside any method, and it is associated with an object. An instance variable is created when an object class is generated.&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;Scope: An instance variable is accessible in all non-static methods of the class. It belongs to a specific object, so each object has its own copy.&lt;br&gt;
Lifetime: The lifetime of an instance variable lasts as long as the object exists. When the object is destroyed, the variable is also destroyed.&lt;br&gt;
Default Value: Instance variables do have default values. For example, int is 0, boolean is false, and object types are null if not initialized.&lt;br&gt;
Example&lt;br&gt;
import java.io.*;&lt;br&gt;
class DNT&lt;br&gt;
{&lt;br&gt;
 public String student; // Declared Instance Variable&lt;br&gt;
 public DNT()&lt;br&gt;
 { // Default Constructor&lt;br&gt;
  this.student= "Urmi Bose"; // initializing Instance Variable&lt;br&gt;
 }&lt;br&gt;
//Main Method&lt;br&gt;
 public static void main(String[] args)&lt;br&gt;
 {&lt;br&gt;
  // Object Creation&lt;br&gt;
  DNT name = new DNT();&lt;br&gt;
  System.out.println("Student name is: " + name.student);&lt;br&gt;
 }&lt;br&gt;
}&lt;br&gt;
Run Code &amp;gt;&amp;gt;&lt;br&gt;
In this Java example, the class "DNT" contains a declaration for an instance variable named "student" that is initialized in the default constructor to demonstrate the use of instance variables. An object of the class is then constructed to allow access to and printing of the student's name.&lt;/p&gt;

&lt;p&gt;Output&lt;br&gt;
Student name is : Urmi Bose&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;Static Variables in Java
A static variable in Java belongs to the class itself, not to any specific object. This means all class objects share the same static variable.&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;Shared Value: A static variable is shared among all class objects. If one object changes its value, it affects all others.&lt;br&gt;
Declared with the static keyword: You must use the static keyword while declaring it. Example: static int count;&lt;br&gt;
Scope: It can be accessed by all methods in the class, including static methods.&lt;br&gt;
Lifetime: The static variable exists as long as the program runs, and it is created when the class is loaded.&lt;br&gt;
Default Value: Static variables have default values, such as 0 for int, false for boolean, and null for objects.&lt;br&gt;
Accessing: You can access it using the class name like ClassName.variableName.&lt;br&gt;
Example&lt;br&gt;
import java.io.*;&lt;br&gt;
class DNT&lt;br&gt;
{&lt;br&gt;
public static String student= "Urmi Bose"; //Declared static variable&lt;/p&gt;

&lt;p&gt;public static void main (String[] args) {&lt;/p&gt;

&lt;p&gt;//student variable can be accessed without object creation&lt;br&gt;
  System.out.println("Student Name is : "+DNT.student);&lt;br&gt;
 }&lt;br&gt;
}&lt;br&gt;
Run Code &amp;gt;&amp;gt;&lt;br&gt;
This Java example prints the value "Urmi Bose" from a static variable named "student" that is declared inside the class "DNT," enabling access by class name simply without creating an object.&lt;/p&gt;

&lt;p&gt;Output&lt;br&gt;
Student Name is: Urmi Bose&lt;br&gt;
Difference between Instance and Static Variable in Java&lt;br&gt;
Understanding the differences between instance variables and static variables in Java is crucial. So, let's look at the differences in the following table.&lt;/p&gt;

&lt;p&gt;Features    Instance Variable in Java   Static Variable in Java&lt;br&gt;
Belongs To  Belongs to one object   Belongs to the class, not any one object&lt;br&gt;
Keyword Used    No special keyword needed   Uses the static keyword&lt;br&gt;
Memory  Each object gets its own copy   One copy is shared by all objects&lt;br&gt;
How to Use  Use it with the object name Use it with the class name&lt;br&gt;
When Created    Created when you make a new object  Created when the class is loaded into memory&lt;br&gt;
Lifetime    Lives as long as the object is in use   Lives as long as the program is running&lt;br&gt;
Default Value   Gets the default value, like 0, false, or null  Also gets a default value like 0, false, or null&lt;br&gt;
Used for    When you need different values for each object  When you want a common value for all objects&lt;br&gt;
This makes it easy to remember that an instance variable is personal to each object, and a static variable in Java is shared by everyone.&lt;/p&gt;

</description>
    </item>
    <item>
      <title>Day 6 (interface )</title>
      <dc:creator>Ranjith Ranjith</dc:creator>
      <pubDate>Thu, 29 May 2025 03:22:42 +0000</pubDate>
      <link>https://dev.to/ranjith_ranjith_/day-5-interface--4inl</link>
      <guid>https://dev.to/ranjith_ranjith_/day-5-interface--4inl</guid>
      <description>&lt;p&gt;1] what is Interfaces:&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt; 1)Like abstract classes, interfaces cannot be used to create objects
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;

&lt;p&gt;(in examabove, it is not possible to create an "Animal" object in the MyMainClass)&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt; 2) Interface methods do not have a body - the body is provided by the "implement" class

  3)On implementation of an interface, you must override all of its methods
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;

&lt;p&gt;Interface methods are by default abstract and public&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;  4)Interface attributes are by default public, static and final
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;

&lt;p&gt;An interface cannot contain a constructor (as it cannot be used to create objects)&lt;/p&gt;

&lt;p&gt;2] Why use interface :&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;  1)interfaces are used to define contracts for classes, enabling abstraction, polymorphism, and multiple inheritance. 
  2) They specify a set of methods that a class must implement, ensuring that all implementing classes share a common behavior.
   3)This allows for loose coupling and flexible code design. 


3] Where do we use an interface : 

  interface keyword in Java is used to declare a special type of class that only contains abstract methods, default methods, static methods, and final variables
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;

</description>
      <category>programming</category>
      <category>softwaredevelopment</category>
      <category>howto</category>
      <category>tutorial</category>
    </item>
    <item>
      <title>Day 6 (interface and implement ) task .</title>
      <dc:creator>Ranjith Ranjith</dc:creator>
      <pubDate>Thu, 29 May 2025 01:59:13 +0000</pubDate>
      <link>https://dev.to/ranjith_ranjith_/day-6-interface-and-implement-task--3ejb</link>
      <guid>https://dev.to/ranjith_ranjith_/day-6-interface-and-implement-task--3ejb</guid>
      <description>&lt;p&gt;1) Interface&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt; First right for a content
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;

&lt;p&gt;Car =start, stop, accelerate, break &lt;/p&gt;

&lt;p&gt;Governmenttransportdepartment &lt;br&gt;
  Followrules, payTak, insurance, passpulltionchick&lt;/p&gt;

&lt;p&gt;publicinterfaceCar {&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;    void start();
    void stop();
    void accelerate();
    void break();
   }
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;

&lt;p&gt;}&lt;/p&gt;

&lt;p&gt;public interface Governmenttransportdepartment{&lt;br&gt;
         void followrules();&lt;br&gt;
         void paytax();&lt;br&gt;
         void insurance();&lt;br&gt;
         void passpullictioncheck();&lt;br&gt;
       }&lt;br&gt;
 }&lt;/p&gt;

&lt;p&gt;Next wright tha implement &lt;br&gt;
     1) Maruthisuzuki =swift &lt;br&gt;
     2)benz &lt;/p&gt;

&lt;p&gt;public maruthisuzuki implement car,governmenttransportdeparment&lt;/p&gt;

&lt;p&gt;public void start();&lt;br&gt;
   System.out.println("swift is start"){&lt;br&gt;
  }&lt;br&gt;
    public void stop();&lt;br&gt;
   System.out.println("swift is stop"){&lt;br&gt;
}&lt;br&gt;
    public void accelerate();&lt;br&gt;
    System.out.println("swift is accelerate"){&lt;br&gt;
  }&lt;br&gt;
   public void break();&lt;br&gt;
     System.out.println("swift is break"){&lt;br&gt;
   }&lt;br&gt;&lt;br&gt;
     public void paytak();&lt;br&gt;
     System.out.println("swift is paytax "){&lt;br&gt;
  }&lt;br&gt;
   public void followrules();&lt;br&gt;
      System.out.println("swift is followeules"){&lt;br&gt;
}&lt;br&gt;
   public void passpullictioncheck();&lt;br&gt;
       System.out.println("swift passpullictioncheck"){&lt;br&gt;
    }&lt;br&gt;
    public void insurance();&lt;br&gt;
       System.out.println("swift is pay insurance"){&lt;/p&gt;

&lt;p&gt;Public static void main(String[]args)&lt;br&gt;
  Maruthisuzuki swift=new maruthisuzuki();&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;    Swift.start();
    Swift.stop();
    Swift.accelerate();
    Swift.break();
    Swift.paytax();
    Swift.insurance();
    Swift.passpullictioncheck();
    Swift.followrules();
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;

&lt;p&gt;public class Benz implements Car, GovernmentTransportDepartment {&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;public void start() {
    System.out.println("Benz is starting");
}
    public void stop() {
    System.out.println("Benz is stopping");
}

public void accelerate() {
    System.out.println("Benz is accelerating");
}

public void brake() {
    System.out.println("Benz is braking");
}

public void followRules() {
    System.out.println("Benz follows traffic rules.");
}

public void payTax() {
    System.out.println("Benz road tax is paid.");
}

public void getInsurance() {
    System.out.println("Benz has insurance.");
}

public void passPollutionCheck() {
    System.out.println("Benz passed pollution check.");
}

public static void main(String[] args) {
    Benz benz = new Benz();
    benz.start();
    benz.accelerate();
    benz .brake();
    benz.stop();
    benz.followRules();
    benz.payTax();
    benz.getInsurance();
    benz.passPollutionCheck();
}
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;

&lt;p&gt;}&lt;/p&gt;

</description>
    </item>
    <item>
      <title>Day 5 (abstract )</title>
      <dc:creator>Ranjith Ranjith</dc:creator>
      <pubDate>Tue, 27 May 2025 17:26:34 +0000</pubDate>
      <link>https://dev.to/ranjith_ranjith_/day-5-abstract--24d1</link>
      <guid>https://dev.to/ranjith_ranjith_/day-5-abstract--24d1</guid>
      <description>&lt;p&gt;What is abstract: class or method is complete and much be __finished later &lt;br&gt;
 Ex&lt;/p&gt;

&lt;p&gt;abstract class student{&lt;br&gt;
          Void study();&lt;br&gt;
Class physics student extends student&lt;br&gt;
           Void study();&lt;br&gt;
        System.out.println("studying in physics subject ")&lt;/p&gt;

&lt;p&gt;What is Dynamic bonding :(method call is detarmind at run based actual object not tha reference type. &lt;/p&gt;

&lt;p&gt;ex:&lt;br&gt;
class Teacher {&lt;br&gt;
    void answerQuestion() {&lt;br&gt;
        System.out.println("Teacher check and answer.");&lt;br&gt;
    }&lt;/p&gt;

&lt;p&gt;class MathTeacher extends Teacher {&lt;br&gt;
    void answerQuestion() {&lt;br&gt;
        System.out.println("Math Teacher: The answer in algebra!");&lt;br&gt;
    }&lt;/p&gt;

&lt;p&gt;class EnglishTeacher extends Teacher{&lt;br&gt;
    void answerQuestion() {&lt;br&gt;
        System.out.println("English Teacher: Let's answer the poem.");&lt;br&gt;
    }&lt;br&gt;
}&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;public static void main(String[] args) {
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;

&lt;p&gt;Teacher t=newEnglishTeacher();  &lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;t.answerQuestion();  
System.out.println(english teacher check answer tha poem)      
t.answerQuestion();
 System.out.println(maths teacher answer tha algebra)
}
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;

&lt;p&gt;}&lt;/p&gt;

&lt;p&gt;Dynamic binding is also referred to as a run-time polymorphism. In this type of binding, the functionality of the method call is not decided at compile-time. In other words, it is not possible to decide which piece of code will be executed as a result of a method call at compile-time&lt;/p&gt;

&lt;p&gt;Binding is a mechanism creating link between method call and method actual implementation. As per the polymorphism concept in Java, object can have many different forms. Object forms can be resolved at compile time and run time.&lt;/p&gt;

</description>
      <category>programming</category>
      <category>education</category>
      <category>oop</category>
      <category>beginners</category>
    </item>
    <item>
      <title>Day 4 (overloding and overriding)</title>
      <dc:creator>Ranjith Ranjith</dc:creator>
      <pubDate>Mon, 26 May 2025 17:41:58 +0000</pubDate>
      <link>https://dev.to/ranjith_ranjith_/day-4-3fj</link>
      <guid>https://dev.to/ranjith_ranjith_/day-4-3fj</guid>
      <description>&lt;p&gt;Overloading =same method name different parameter s is called overloading&lt;br&gt;
Ex &lt;br&gt;
     class Calculator {&lt;br&gt;
    int add(int a, int b) {&lt;br&gt;
        return a + b;&lt;br&gt;
    }&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;double add(double a, double b) {
    return a + b;
}
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;

&lt;p&gt;}&lt;br&gt;
  Explain :1) add name same &lt;br&gt;
            2)different parameters &lt;/p&gt;

&lt;p&gt;Overriding = same parameters same method and different classes is called overriding &lt;br&gt;
 Ex &lt;br&gt;
       class Animal {&lt;br&gt;
    void sound() {&lt;br&gt;
        System.out.println("Animal sound");&lt;br&gt;
    }&lt;br&gt;
}&lt;/p&gt;

&lt;p&gt;class Dog extends Animal {&lt;br&gt;
    void sound() {&lt;br&gt;
        System.out.println("Dog barks");&lt;br&gt;
    }&lt;br&gt;
}&lt;br&gt;
     Explain :dog barks,animal sound&lt;br&gt;
   This Overriding &lt;/p&gt;

</description>
    </item>
    <item>
      <title>Day 3 (return type )</title>
      <dc:creator>Ranjith Ranjith</dc:creator>
      <pubDate>Sun, 25 May 2025 14:16:22 +0000</pubDate>
      <link>https://dev.to/ranjith_ranjith_/day-3-return-type--33ch</link>
      <guid>https://dev.to/ranjith_ranjith_/day-3-return-type--33ch</guid>
      <description>&lt;ol&gt;
&lt;li&gt;With return type(Value returnதரும்)&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;With return type tel as tha what kind of value function give bake after it&lt;br&gt;
Runs &lt;br&gt;
  Example. a=5 ,b=2&lt;br&gt;
         int add(int a,int b){&lt;br&gt;
         System.out.println(a+b); &lt;br&gt;
         return (5+2);&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;without return type=(value return தராது)&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;kind of value function does not give bake any value &lt;br&gt;
   Example&lt;br&gt;
        public void hello(){&lt;br&gt;
        System.out.println("Hello")&lt;/p&gt;

</description>
      <category>code</category>
      <category>programming</category>
      <category>beginners</category>
      <category>tutorial</category>
    </item>
    <item>
      <title>[Boost]</title>
      <dc:creator>Ranjith Ranjith</dc:creator>
      <pubDate>Sun, 25 May 2025 13:49:20 +0000</pubDate>
      <link>https://dev.to/ranjith_ranjith_/-397a</link>
      <guid>https://dev.to/ranjith_ranjith_/-397a</guid>
      <description></description>
      <category>productivity</category>
    </item>
    <item>
      <title>[Boost]</title>
      <dc:creator>Ranjith Ranjith</dc:creator>
      <pubDate>Sun, 25 May 2025 13:30:21 +0000</pubDate>
      <link>https://dev.to/ranjith_ranjith_/-2p9d</link>
      <guid>https://dev.to/ranjith_ranjith_/-2p9d</guid>
      <description></description>
      <category>productivity</category>
      <category>career</category>
      <category>discuss</category>
    </item>
    <item>
      <title>[Boost]</title>
      <dc:creator>Ranjith Ranjith</dc:creator>
      <pubDate>Sun, 25 May 2025 13:18:15 +0000</pubDate>
      <link>https://dev.to/ranjith_ranjith_/-398</link>
      <guid>https://dev.to/ranjith_ranjith_/-398</guid>
      <description></description>
      <category>opensource</category>
      <category>boost</category>
      <category>cpp</category>
    </item>
  </channel>
</rss>
