<?xml version="1.0" encoding="UTF-8"?><rss xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:atom="http://www.w3.org/2005/Atom" version="2.0" xmlns:cc="http://cyber.law.harvard.edu/rss/creativeCommonsRssModule.html">
    <channel>
        <title><![CDATA[Stories by Wrath on Medium]]></title>
        <description><![CDATA[Stories by Wrath on Medium]]></description>
        <link>https://medium.com/@praveenelaiyappan?source=rss-544bc0595c18------2</link>
        <image>
            <url>https://cdn-images-1.medium.com/fit/c/150/150/1*ZyO4Tv0tqZDsTzLdkS2hMw.jpeg</url>
            <title>Stories by Wrath on Medium</title>
            <link>https://medium.com/@praveenelaiyappan?source=rss-544bc0595c18------2</link>
        </image>
        <generator>Medium</generator>
        <lastBuildDate>Fri, 20 Nov 2026 10:24:24 GMT</lastBuildDate>
        <atom:link href="https://medium.com/@praveenelaiyappan/feed" rel="self" type="application/rss+xml"/>
        <webMaster><![CDATA[yourfriends@medium.com]]></webMaster>
        <atom:link href="http://medium.superfeedr.com/" rel="hub"/>
        <item>
            <title><![CDATA[Understanding the Difference between nonlocal and global in Python]]></title>
            <link>https://medium.com/@praveenelaiyappan/understanding-the-difference-between-nonlocal-and-global-in-python-e8f6475922d2?source=rss-544bc0595c18------2</link>
            <guid isPermaLink="false">https://medium.com/p/e8f6475922d2</guid>
            <category><![CDATA[non-local-keyword]]></category>
            <category><![CDATA[python]]></category>
            <category><![CDATA[global-keyword]]></category>
            <dc:creator><![CDATA[Wrath]]></dc:creator>
            <pubDate>Sat, 27 May 2023 03:47:00 GMT</pubDate>
            <atom:updated>2023-05-27T03:47:00.702Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*6VA_nWKRfyn70eXiMOvJDQ.png" /></figure><p>Python, being a versatile and powerful programming language, provides two keywords, nonlocal and global, to access variables defined in outer scopes. While these keywords serve a similar purpose, they have distinct behaviours and use cases. In this blog post, we’ll explore the difference between nonlocal and global in Python.</p><h3>The nonlocal Keyword</h3><p>The nonlocal keyword is used to indicate that a variable is defined in an outer function scope, often referred to as a non-local scope. It is particularly useful when working with nested functions. By using the nonlocal keyword, you can access and modify variables from the outer scope within an inner function.</p><p>Let’s take a look at an example to illustrate its usage:</p><pre>def outer_function():<br>    x = 10<br>    def inner_function():<br>        nonlocal x<br>        x = 20<br>        print(x)     # Output: 20<br>    inner_function()<br>    print(x)         # Output: 20<br>outer_function()</pre><p>In the above example, we have an outer function called outer_function(), which defines a variable x with an initial value of 10. Inside outer_function(), we have an inner function called inner_function(), where we declare x as a nonlocal variable using the nonlocal keyword. We then assign a new value of 20 to x and print it, resulting in the output of 20. The change in the value of x persists even after the inner_function() has finished executing, as seen by the subsequent print statement in outer_function().</p><p>The nonlocal keyword allows us to modify variables in the outer scope from within nested functions, providing a way to communicate and share data between the inner and outer functions.</p><h3>The global Keyword</h3><p>On the other hand, the global keyword is used to indicate that a variable is defined in the global scope, outside of any function. When a variable is declared as global, it can be accessed and modified from any part of the program, including within functions.</p><p>Consider the following example:</p><pre>x = 10<br><br>def my_function():<br>    global x<br>    x = 20<br>    print(x)  # Output: 20<br><br>my_function()<br>print(x)      # Output: 20</pre><p>In this example, we have a global variable x with an initial value of 10. Inside the function my_function(), we declare x as a global variable using the global keyword. We then assign a new value of 20 to x and print it, resulting in the output of 20. The change made to the global variable inside the function is reflected throughout the program, as seen by the subsequent print statement outside the function.</p><p>The global keyword enables us to access and modify variables in the global scope from within functions. It provides a way to work with global variables while maintaining their values across different parts of the program.</p><h3>Summary</h3><p>The nonlocal keyword is used to access and modify variables in an outer (non-local) function scope, particularly within nested functions. It allows us to communicate and share data between the inner and outer functions.</p><p>On the other hand, the global keyword is used to access and modify variables in the global scope, outside of any function. It enables us to work with global variables and maintain their values across different parts of the program.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=e8f6475922d2" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[25 SQL tricks for beginners]]></title>
            <link>https://medium.com/@praveenelaiyappan/25-sql-tricks-for-beginners-c78fe9c196a6?source=rss-544bc0595c18------2</link>
            <guid isPermaLink="false">https://medium.com/p/c78fe9c196a6</guid>
            <category><![CDATA[sql]]></category>
            <category><![CDATA[tips-for-beginners]]></category>
            <dc:creator><![CDATA[Wrath]]></dc:creator>
            <pubDate>Fri, 26 May 2023 07:02:07 GMT</pubDate>
            <atom:updated>2023-05-26T07:02:37.652Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*U9QERU9JmtREO8J6Fxd3JQ.png" /></figure><ol><li><strong>SELECT Statement:</strong> Retrieve data from a database table using the SELECT statement.</li><li><strong>WHERE Clause:</strong> Filter data based on specific conditions using the WHERE clause in conjunction with the SELECT statement.</li><li><strong>DISTINCT Keyword:</strong> Retrieve unique values from a column using the DISTINCT keyword.</li><li><strong>ORDER BY Clause: </strong>Sort the result set in ascending or descending order using the ORDER BY clause.</li><li><strong>LIMIT Clause:</strong> Limit the number of rows returned by a query using the LIMIT clause (syntax may vary across different database systems).</li><li><strong>JOIN: </strong>Combine rows from multiple tables based on a related column using JOIN operations such as INNER JOIN, LEFT JOIN, RIGHT JOIN, or FULL JOIN.</li><li><strong>GROUP BY Clause:</strong> Group rows based on a specific column(s) and perform aggregate functions like COUNT, SUM, AVG, MAX, or MIN on grouped data.</li><li><strong>HAVING Clause:</strong> Filter the result set based on conditions applied to the groups created by the GROUP BY clause.</li><li><strong>INSERT Statement:</strong> Insert new data into a table using the INSERT statement.</li><li><strong>UPDATE Statement:</strong> Modify existing data in a table using the UPDATE statement.</li><li><strong>DELETE Statement: </strong>Remove data from a table using the DELETE statement.</li><li><strong>IN Operator: </strong>Check if a value exists within a set of values using the IN operator.</li><li><strong>BETWEEN Operator:</strong> Check if a value falls within a specific range using the BETWEEN operator.</li><li><strong>LIKE Operator:</strong> Perform pattern matching using the LIKE operator with wildcard characters (% and _).</li><li><strong>NULL Values:</strong> Handle NULL values in the database using IS NULL or IS NOT NULL operators.</li><li><strong>COUNT() Function:</strong> Count the number of rows in a table or the number of occurrences of a specific value using the COUNT() function.</li><li><strong>SUM() Function:</strong> Calculate the sum of values in a column using the SUM() function.</li><li><strong>AVG() Function:</strong> Calculate the average of values in a column using the AVG() function.</li><li><strong>MAX() Function: </strong>Retrieve the maximum value from a column using the MAX() function.</li><li><strong>MIN() Function:</strong> Retrieve the minimum value from a column using the MIN() function.</li><li><strong>Alias: </strong>Assign a temporary name to a table or column using the AS keyword to improve readability.</li><li><strong>Subqueries: </strong>Use a query within another query to perform complex operations or retrieve data from multiple tables.</li><li><strong>EXISTS Keyword: </strong>Check the existence of specific data in a subquery using the EXISTS keyword.</li><li><strong>UNION Operator: </strong>Combine the result sets of multiple SELECT statements into a single result set using the UNION operator.</li><li><strong>CASE Statement:</strong> Perform conditional logic within a query using the CASE statement to create custom columns or apply specific operations based on conditions.</li></ol><p><a href="https://structuredquerylanguageforbeginners.quora.com/">https://structuredquerylanguageforbeginners.quora.com</a></p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=c78fe9c196a6" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Array vs ArrayList: Which One Should You Use?]]></title>
            <link>https://medium.com/@praveenelaiyappan/array-vs-arraylist-which-one-should-you-use-1babdc290951?source=rss-544bc0595c18------2</link>
            <guid isPermaLink="false">https://medium.com/p/1babdc290951</guid>
            <category><![CDATA[java]]></category>
            <category><![CDATA[arraylist]]></category>
            <category><![CDATA[arrays]]></category>
            <dc:creator><![CDATA[Wrath]]></dc:creator>
            <pubDate>Fri, 26 May 2023 03:08:12 GMT</pubDate>
            <atom:updated>2023-05-26T03:08:12.380Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*uvdZQEG_p12zuHRwyrvx0w.png" /></figure><p>Arrays and ArrayLists are two of the most commonly used data structures in Java. Although they are similar in some ways, they have some key differences that make them suitable for different use cases. In this article, we will discuss the differences between arrays and ArrayLists in Java.</p><h3>Definition</h3><p>An array is a fixed-length data structure that stores a collection of elements of the same data type in contiguous memory locations. It is a basic functionality provided by Java. On the other hand, an ArrayList is a resizable array that can store elements of different data types. It is part of the Java Collections framework and can be found in the java.util package.</p><h3>Functionality</h3><p>Arrays are static in size, which means that their length cannot be changed once they are created. They can hold both primitives and objects in Java. Array members can be accessed using the [] operator.ArrayLists, on the other hand, are dynamic in size. They can change their length after being created. They can only hold objects, not primitives. ArrayLists can access elements using a set of methods and modify them. They have a set of methods such as add(), remove(), and get() that can be used to manipulate the elements.</p><h3>Performance</h3><p>The performance of arrays and ArrayLists depends on the operation being performed. In general, arrays are faster than ArrayLists for accessing elements because they are stored in contiguous memory locations. However, ArrayLists are faster than arrays for inserting and deleting elements because they do not require shifting of elements.</p><h3>Multi-dimensional</h3><p>Arrays can be multi-dimensional, while ArrayLists are always single-dimensional.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*J8XUofOQ7eB7FCU80aEcow.png" /></figure><h3>Conclusion</h3><p>In summary, arrays and ArrayLists are both useful data structures in Java, but they have different use cases. Arrays are suitable for storing a fixed number of elements of the same data type, while ArrayLists are suitable for storing a variable number of elements of different data types. Arrays are faster for accessing elements, while ArrayLists are faster for inserting and deleting elements. It is important to choose the appropriate data structure based on the specific requirements of the program.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=1babdc290951" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[A Beginner Guide To Java Type Casting and Types of Type Casting]]></title>
            <link>https://medium.com/@praveenelaiyappan/a-beginner-guide-to-java-type-casting-and-types-of-type-casting-4b30cec49f98?source=rss-544bc0595c18------2</link>
            <guid isPermaLink="false">https://medium.com/p/4b30cec49f98</guid>
            <category><![CDATA[type-casting]]></category>
            <category><![CDATA[types-of-type-casting]]></category>
            <category><![CDATA[java]]></category>
            <dc:creator><![CDATA[Wrath]]></dc:creator>
            <pubDate>Thu, 25 May 2023 10:38:09 GMT</pubDate>
            <atom:updated>2023-05-25T10:38:09.092Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*nt5qGLb2c8-PL5FMYaO7EA.png" /></figure><p>Type casting is the process of <strong>converting a value from one data type to another.</strong> It is a common operation in programming languages, including Java and C. Type casting can be done <strong>automatically or manually, </strong>and there are two types of type casting: widening and narrowing. Widening type casting is converting a <strong>lower data type into a higher one,</strong> while narrowing type casting is converting a <strong>higher data type into a lower one. </strong>In this article, we will discuss the types of type casting and provide examples.</p><h4>Types of Type Casting</h4><p>There are two types of type casting operations in programming languages:</p><ol><li>Widening Type Casting</li><li>Narrowing Type Casting</li></ol><h4>Widening Type Casting</h4><p>Widening type casting is converting a lower data type into a higher one. It is also known as implicit conversion or casting down. It is done automatically by the compiler, and it is safe because there is no chance to lose data. Widening type casting takes place when:</p><ul><li>A byte is converted to a short, int, long, float, or double.</li><li>A short is converted to an int, long, float, or double.</li><li>A char is converted to an int, long, float, or double.</li><li>An int is converted to a long, float, or double.</li><li>A long is converted to a float or double.</li><li>A float is converted to a double.</li></ul><p><strong>Example:</strong></p><pre>javaint i = 10;<br>double d = i; // automatic casting</pre><h4>Narrowing Type Casting</h4><p>Narrowing type casting is converting a higher data type into a lower one. It is also known as explicit conversion or casting up. It is done manually by the programmer, and it may result in data loss. Narrowing type casting takes place when:</p><ul><li>A double is converted to a float, long, int, char, or byte.</li><li>A float is converted to a long, int, char, or byte.</li><li>A long is converted to an int, char, or byte.</li><li>An int is converted to a char or byte.</li><li>A char is converted to a byte.</li></ul><p><strong>Example:</strong></p><pre>javadouble d = 10.5;<br>int i = (int) d; // manual casting</pre><h3>Conclusion</h3><p>Type casting is a fundamental concept in Java programming language. It allows us to convert values from one data type to another, which is essential for many operations. There are two types of type casting in Java: widening and narrowing. Widening type casting is converting a lower data type into a higher one, while narrowing type casting is converting a higher data type into a lower one. It is important to understand the types of type casting in Java to use them effectively in programming.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=4b30cec49f98" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Java Programming(Arrays) - Basics for Beginners]]></title>
            <link>https://medium.com/@praveenelaiyappan/java-programming-arrays-basics-for-beginners-17b384907799?source=rss-544bc0595c18------2</link>
            <guid isPermaLink="false">https://medium.com/p/17b384907799</guid>
            <category><![CDATA[arrays]]></category>
            <category><![CDATA[java]]></category>
            <dc:creator><![CDATA[Wrath]]></dc:creator>
            <pubDate>Wed, 24 May 2023 09:06:07 GMT</pubDate>
            <atom:updated>2023-05-24T09:06:07.354Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*-ltTyryor5gY5Re0J4J_SA.png" /></figure><p>An array is a <strong>collection of similar types of data.</strong></p><p>For example, if we want to store the names of 100 people then we can create an array of the string type that can store 100 names.</p><pre>String[] array = new String[100];</pre><p>Here, the above array cannot store more than 100 names. The number of values in a Java array is always fixed.</p><h3>How to declare an array in Java?</h3><p>In Java, here is how we can declare an array.</p><pre>dataType[] arrayName;</pre><ul><li>dataType — it can be <a href="https://www.programiz.com/java-programming/variables-primitive-data-types#data-types">primitive data types</a> like int, char, double, byte, etc. or <a href="https://www.programiz.com/java-programming/class-objects">Java objects</a></li><li>arrayName — it is an <a href="https://www.programiz.com/java-programming/keywords-identifiers#identifiers">identifier</a></li></ul><p>For example,</p><pre>double[] data;</pre><p>Here, data is an array that can hold values of type double.</p><p><strong>But, how many elements can array this hold?</strong></p><p>Good question! To define the number of elements that an array can hold, we have to allocate memory for the array in Java. For example,</p><pre>// declare an array<br>double[] data;</pre><pre>// allocate memory<br>data = new double[10];</pre><p>Here, the array can store <strong>10</strong> elements. We can also say that the <strong>size or length</strong> of the array is 10.</p><p>In Java, we can declare and allocate the memory of an array in one single statement. For example,</p><pre>double[] data = new double[10];</pre><h3>How to Initialize Arrays in Java?</h3><p>In Java, we can initialize arrays during declaration. For example,</p><pre>//declare and initialize and array<br>int[] age = {12, 4, 5, 2, 5};</pre><p>Here, we have created an array named age and initialized it with the values inside the curly brackets.</p><p>Note that we have not provided the size of the array. In this case, the Java compiler automatically specifies the size by counting the number of elements in the array (i.e. 5).</p><p>In the Java array, each memory location is associated with a number. The number is known as an array index. We can also initialize arrays in Java, using the index number. For example,</p><pre>// declare an array<br>int[] age = new int[5];</pre><pre>// initialize array<br>age[0] = 12;<br>age[1] = 4;<br>age[2] = 5;<br>..</pre><figure><img alt="" src="https://cdn-images-1.medium.com/max/380/0*bpTrHwcUijkc3qLV.jpg" /></figure><p><strong>Note</strong>:</p><ul><li>Array indices always start from 0. That is, the first element of an array is at index 0.</li><li>If the size of an array is n, then the last element of the array will be at index n-1.</li></ul><h3>How to Access Elements of an Array in Java?</h3><p>We can access the element of an array using the index number. Here is the syntax for accessing elements of an array,</p><pre>// access array elements<br>array[index]</pre><p>Let’s see an example of accessing array elements using index numbers.</p><h3>Example: Access Array Elements</h3><pre>class Main {<br> public static void main(String[] args) {<br>  <br>   // create an array<br>   int[] age = {12, 4, 5, 2, 5};</pre><pre>   // access each array elements<br>   System.out.println(&quot;Accessing Elements of Array:&quot;);<br>   System.out.println(&quot;First Element: &quot; + age[0]);<br>   System.out.println(&quot;Second Element: &quot; + age[1]);<br>   System.out.println(&quot;Third Element: &quot; + age[2]);<br>   System.out.println(&quot;Fourth Element: &quot; + age[3]);<br>   System.out.println(&quot;Fifth Element: &quot; + age[4]);<br> }<br>}</pre><p><strong>Output</strong></p><pre>Accessing Elements of Array:<br>First Element: 12<br>Second Element: 4<br>Third Element: 5<br>Fourth Element: 2<br>Fifth Element: 5</pre><p>In the above example, notice that we are using the index number to access each element of the array.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=17b384907799" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[6 Best Free Resources for Learning SQL]]></title>
            <link>https://medium.com/@praveenelaiyappan/6-best-free-resources-for-learning-sql-5ff9e2fa1b9e?source=rss-544bc0595c18------2</link>
            <guid isPermaLink="false">https://medium.com/p/5ff9e2fa1b9e</guid>
            <category><![CDATA[sql]]></category>
            <category><![CDATA[free-resources]]></category>
            <dc:creator><![CDATA[Wrath]]></dc:creator>
            <pubDate>Wed, 24 May 2023 07:18:08 GMT</pubDate>
            <atom:updated>2023-05-24T07:18:08.221Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*wGI-e_19OuMPrJQCTZ3vlw.png" /></figure><p>Structured Query Language (SQL) is a popular language for managing and manipulating relational databases. Whether you are new to SQL or want to improve your skills, there are plenty of free resources available online that can help you learn and practice SQL. In this article, we will explore some of the best places to learn SQL from basic to advanced for free.</p><h3>1. SQLCourse.com</h3><p>SQLCourse.com is a free online training course for SQL beginners and advanced SQL programmers. It covers basic SQL commands and syntax, such as how to insert, update, and delete information from tables. You can practice these commands through their free online SQL interpreter, which supports a subset of ANSI SQL.</p><h3>2. Great Learning Academy</h3><p>Great Learning Academy offers a free Advanced SQL course for beginners. The course is self-paced and covers various topics that fall under the advanced SQL category. Upon completion of the course, you can obtain a certificate.</p><h3>3. Udemy</h3><p>Udemy offers a wide range of SQL courses, including both beginner and advanced levels. You can learn from real-world experts with step-by-step video tutorials. Some of the courses are free, while others may require payment.</p><h3>4. Kaggle</h3><p>Kaggle offers a free Advanced SQL course that takes your SQL skills to the next level. The course covers JOINs and UNIONs, among other topics.</p><h3>5. Class Central</h3><p>Class Central is a platform that aggregates free online courses from various providers. They have compiled a list of the 10 best free online SQL courses, which include both basic and advanced SQL concepts. Some of the courses offer free certificates upon completion.</p><h3>6. Skillcrush</h3><p>Skillcrush has compiled a list of 20+ ways to learn SQL online for free. They include resources like Khan Academy, Codecademy, and EdX. Some of the resources offer paid courses, while others are completely free. There are many ways to learn SQL for free online, and the resources listed above are just a few examples. Whether you prefer video tutorials, interactive courses, or reading materials, there is something for everyone. With dedication and practice, you can improve your SQL skills and become proficient in managing and manipulating relational databases.</p><p><strong>Free SQL Space :</strong> <a href="https://structuredquerylanguageforbeginners.quora.com/">https://structuredquerylanguageforbeginners.quora.com</a></p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=5ff9e2fa1b9e" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[A Beginner Guide To Java Variable Types and Their Scopes]]></title>
            <link>https://medium.com/@praveenelaiyappan/a-beginner-guide-to-java-variable-types-and-their-scopes-bf590b5abab9?source=rss-544bc0595c18------2</link>
            <guid isPermaLink="false">https://medium.com/p/bf590b5abab9</guid>
            <category><![CDATA[java]]></category>
            <category><![CDATA[types-of-variable]]></category>
            <dc:creator><![CDATA[Wrath]]></dc:creator>
            <pubDate>Tue, 23 May 2023 02:00:15 GMT</pubDate>
            <atom:updated>2023-05-23T02:00:15.687Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*UErESMzJKCnUYQ6X-B96eA.png" /></figure><p>In Java, the scope of a variable refers to the portion of a program where the variable can be accessed. The scope of a variable can be determined by its location in the source code, as well as by any blocks of code (such as loops or conditional statements) that enclose it. There are three main types of variable scope in Java: local scope, instance scope, and static scope.</p><ol><li><strong>Local Scope:</strong> This refers to variables that are defined within a method or block of code. These variables are only accessible within the method or block where they were declared, and they are not visible to any code outside of that scope. For example:</li></ol><pre>public void myMethod() {<br>  int x = 10; // local variable<br>  System.out.println(x); // prints 10<br>}</pre><p>2.<strong> Instance Scope: </strong>This refers to variables that are defined within a class but outside of any method or block of code. These variables are accessible to all methods within the class and can be accessed using an instance of the class. For example:</p><pre>public class MyClass {<br>  int x = 5; // instance variable<br><br>  public void myMethod() {<br>    System.out.println(x); // prints 5<br>  }<br>}</pre><p>3. <strong>Static Scope:</strong> This refers to variables that are declared with the static keyword within a class but outside of any method or block of code. These variables are accessible to all methods within the class and can be accessed using the class name. For example:</p><pre>public class MyClass {<br>  static int x = 5; // static variable<br><br>  public void myMethod() {<br>    System.out.println(MyClass.x); // prints 5<br>  }<br>}</pre><p>In summary, understanding variable scope is important in Java programming because it helps to prevent naming conflicts and ensures that variables are only accessible where they are needed.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=bf590b5abab9" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[How to Concatenate Strings in Java: Tips and Tricks]]></title>
            <link>https://medium.com/@praveenelaiyappan/how-to-concatenate-strings-in-java-tips-and-tricks-6142316f8e3f?source=rss-544bc0595c18------2</link>
            <guid isPermaLink="false">https://medium.com/p/6142316f8e3f</guid>
            <category><![CDATA[java]]></category>
            <category><![CDATA[string-concatenation]]></category>
            <dc:creator><![CDATA[Wrath]]></dc:creator>
            <pubDate>Sun, 21 May 2023 03:25:31 GMT</pubDate>
            <atom:updated>2023-05-21T03:25:31.114Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*_OQA2u7JPrHIabpDfHbolg.png" /></figure><p>Java is a popular programming language that is widely used for developing web and mobile applications. One of the most common operations in Java is string concatenation, which involves combining two or more strings into a single string. In this article, we will explore different ways to concatenate strings in Java.</p><h3>Using the “+” Operator</h3><p>The simplest way to concatenate two or more strings in Java is to use the “+” operator. This operator can be used to combine two or more strings into a single string. Here’s an example:</p><pre>String firstName = &quot;John&quot;;<br>String lastName = &quot;Doe&quot;;<br>String fullName = firstName + &quot; &quot; + lastName;<br>System.out.println(fullName);</pre><p>In this example, we have created two string variables firstName and lastName, and then concatenated them using the &quot;+&quot; operator. The resulting string is stored in the fullName variable, which is then printed to the console.</p><h3>Using the concat() Method</h3><p>Another way to concatenate strings in Java is to use the concat() method. This method is defined in the String class and can be used to append one string to another. Here&#39;s an example:</p><pre>String firstName = &quot;John &quot;;<br>String lastName = &quot;Doe&quot;;<br>String fullName = firstName.concat(lastName);<br>System.out.println(fullName);</pre><p>In this example, we have used the concat() method to append the lastName string to the end of the firstName string. The resulting string is stored in the fullName variable, which is then printed to the console.</p><h3>Using StringBuilder</h3><p>If you need to concatenate multiple strings together, it’s more efficient to use a StringBuilder object instead of repeatedly concatenating strings using the &quot;+&quot; operator or concat() method. Here&#39;s an example:</p><pre>StringBuilder sb = new StringBuilder();<br>sb.append(&quot;Hello&quot;);<br>sb.append(&quot; &quot;);<br>sb.append(&quot;World&quot;);<br>String message = sb.toString();<br>System.out.println(message);</pre><p>In this example, we have created a StringBuilder object and used its append() method to add two strings (&quot;Hello&quot; and &quot;World&quot;) to it. We then converted the StringBuilder object to a string using its toString() method and stored it in the message variable, which is then printed to the console.</p><h3>Conclusion</h3><p>In this article, we have explored different ways to concatenate strings in Java. The simplest way is to use the “+” operator, but if you need to concatenate multiple strings together, it’s more efficient to use a StringBuilder object instead of repeatedly concatenating strings using the &quot;+&quot; operator or concat() method.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=6142316f8e3f" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[A Beginner’s Guide to Java Data Types]]></title>
            <link>https://medium.com/@praveenelaiyappan/a-beginners-guide-to-java-data-types-d47b8515153c?source=rss-544bc0595c18------2</link>
            <guid isPermaLink="false">https://medium.com/p/d47b8515153c</guid>
            <category><![CDATA[primitive-data-types]]></category>
            <category><![CDATA[non-primitive-datatypes]]></category>
            <category><![CDATA[default-value]]></category>
            <category><![CDATA[java-datatypes]]></category>
            <category><![CDATA[java]]></category>
            <dc:creator><![CDATA[Wrath]]></dc:creator>
            <pubDate>Sun, 21 May 2023 03:02:20 GMT</pubDate>
            <atom:updated>2023-05-21T03:02:20.306Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*2JtIY6gF5SIbMgarT-uZBA.png" /></figure><p>Java is a statically-typed programming language, which means that all variables must be declared before they can be used. This involves stating the variable’s type and name. Java has two categories in which data types are segregated: Primitive Data Type and Non-Primitive Data Type or Object Data type. Here are some details about Java data types:</p><h4>Primitive Data Types</h4><p>Primitive data types are the <strong>building blocks of data manipulation in Java.</strong> They are predefined by the language and named by a reserved keyword. Primitive values do not share state with other primitive values. There are eight primitive data types in Java:</p><ol><li><strong>byte: </strong>The byte data type is an 8-bit signed two’s complement integer. It has a minimum value of -128 and a maximum value of 127 (inclusive).</li><li><strong>short:</strong> The short data type is a 16-bit signed two’s complement integer. It has a minimum value of -32,768 and a maximum value of 32,767 (inclusive).</li><li><strong>int: </strong>The int data type is a 32-bit signed two’s complement integer. It has a minimum value of -2³¹ and a maximum value of 2³¹-1 (inclusive).</li><li><strong>long: </strong>The long data type is a 64-bit signed two’s complement integer. It has a minimum value of -2⁶³ and a maximum value of 2⁶³-1 (inclusive).</li><li><strong>float:</strong> The float data type is a single-precision 32-bit IEEE 754 floating point.</li><li><strong>double:</strong> The double data type is a double-precision 64-bit IEEE 754 floating point.</li><li><strong>char: </strong>The char data type is a single 16-bit Unicode character. It has a minimum value of ‘\u0000’ (or 0) and a maximum value of ‘\uffff’ (or 65,535 inclusive).</li><li><strong>boolean:</strong> The boolean data type has only two possible values: true and false.</li></ol><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*CijCMU8pW2nbMrp3-QXt2Q.png" /></figure><h4>Non-Primitive Data Types</h4><p>Non-primitive data types are also known as reference data types or object data types. They are not predefined by the language but are created by the programmer to define objects in their programs. Some examples of non-primitive data types include String, Arrays, and Classes.</p><p>In conclusion, understanding Java data types is essential for writing efficient and effective code in Java programming language. By knowing the different sizes and values that can be stored in variables, programmers can create programs that are optimized for performance and memory usage.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=d47b8515153c" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Java Variables: Types, Declaration, and Memory Location]]></title>
            <link>https://medium.com/@praveenelaiyappan/java-variables-types-declaration-and-memory-location-14011e678c87?source=rss-544bc0595c18------2</link>
            <guid isPermaLink="false">https://medium.com/p/14011e678c87</guid>
            <category><![CDATA[variable-memory-location]]></category>
            <category><![CDATA[types-of-variable]]></category>
            <category><![CDATA[variable-declaration]]></category>
            <category><![CDATA[java]]></category>
            <dc:creator><![CDATA[Wrath]]></dc:creator>
            <pubDate>Sun, 21 May 2023 02:46:03 GMT</pubDate>
            <atom:updated>2023-05-21T02:46:03.239Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*5nl-zU1UmSKPXH1Jqr7Zng.png" /></figure><p>Java variables are containers that store data values during program execution. In Java, there are different types of variables, including</p><ol><li>Primitive Variables</li><li>Non-primitive Variables</li></ol><p>Primitive types include int, double, float, boolean, char, and byte. These types hold simple values and are stored in the <strong>stack memory</strong>.</p><p>Non-primitive types include classes, arrays, and interfaces. These types hold object references and are stored in the <strong>heap memory.</strong></p><p>To declare a variable in Java, you must specify the type and assign it a value. For example, to create a variable called name of type String and assign it the value &quot;John&quot;, you can use the following code:</p><pre>String name = &quot;John&quot;;</pre><p>You can also declare a variable without assigning a value to it. For example:</p><pre>int myNum;</pre><p>In this case, the variable myNum is declared but not initialized. You can assign a value to it later in the program.</p><p>Java variables have different scopes depending on where they are declared. Local variables are declared inside a method or block and can only be accessed within that method or block. Instance variables are declared inside a class but outside any method or block. They can be accessed by any method or block within the class. Static variables are declared with the static keyword and belong to the class rather than any instance of the class. They can be accessed by any method or block within the class.</p><p>In Java, all variables must be declared before use. This means that you must specify the type of the variable before you can use it in your program.</p><p>Overall, Java variables are an essential part of programming in Java. They allow you to store and manipulate data values during program execution, making your programs more dynamic and flexible.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=14011e678c87" width="1" height="1" alt="">]]></content:encoded>
        </item>
    </channel>
</rss>