<?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 Dilka Sithari on Medium]]></title>
        <description><![CDATA[Stories by Dilka Sithari on Medium]]></description>
        <link>https://medium.com/@sitharihmd-19?source=rss-12d302bdc56b------2</link>
        <image>
            <url>https://cdn-images-1.medium.com/fit/c/150/150/1*nUnPMPpwdK2HPt7_BjsjcA.jpeg</url>
            <title>Stories by Dilka Sithari on Medium</title>
            <link>https://medium.com/@sitharihmd-19?source=rss-12d302bdc56b------2</link>
        </image>
        <generator>Medium</generator>
        <lastBuildDate>Tue, 24 Nov 2026 17:31:20 GMT</lastBuildDate>
        <atom:link href="https://medium.com/@sitharihmd-19/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[GitLab Cherry-Pick: A Developer’s Guide to Selective Commits]]></title>
            <link>https://sitharihmd-19.medium.com/gitlab-cherry-pick-a-developers-guide-to-selective-commits-01adb5cac577?source=rss-12d302bdc56b------2</link>
            <guid isPermaLink="false">https://medium.com/p/01adb5cac577</guid>
            <category><![CDATA[gitlab]]></category>
            <category><![CDATA[version-control]]></category>
            <category><![CDATA[cherrypick]]></category>
            <category><![CDATA[git]]></category>
            <category><![CDATA[coding]]></category>
            <dc:creator><![CDATA[Dilka Sithari]]></dc:creator>
            <pubDate>Mon, 10 Mar 2025 08:43:12 GMT</pubDate>
            <atom:updated>2025-03-24T09:09:23.433Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*10w1Rl085BACdXf0xvUDqA.jpeg" /><figcaption>Photo by <a href="https://unsplash.com/@ikukevk?utm_content=creditCopyText&amp;utm_medium=referral&amp;utm_source=unsplash">Kevin Ku</a> on <a href="https://unsplash.com/photos/closeup-photo-of-eyeglasses-w7ZyuGYNpRQ?utm_content=creditCopyText&amp;utm_medium=referral&amp;utm_source=unsplash">Unsplash</a></figcaption></figure><p><strong>Introduction</strong></p><p>In software development, you may need to apply a specific commit from one branch to another without merging the entire branch. This is where <strong>cherry-pick</strong> comes in. Cherry-pick allows you to apply individual commits to another branch selectively. In this article, I will explore how to cherry-pick commits using both GitLab UI and Git CLI.</p><p><strong>What is cherry-pick in Git ?</strong></p><p>Cherry-pick in Git means picking a specific commit/commits from one branch and applying it to another branch. Unlike merging or rebasing, which involve entire branches, cherry-pick lets you choose only the necessary changes.</p><p><strong>Cherry-pick using Git-CLI</strong></p><p>Here are the steps that should be followed when cherry-pick commits using Git CLI.</p><p>Use your preferred IDE and open your project in the IDE to cherry-pick commits using CLI. I am using <strong>IntelliJ IDEA</strong>.</p><p>1. Open Your Project in IntelliJ IDEA</p><ul><li>Launch <strong>IntelliJ IDEA</strong>.</li><li>Open your Git repository project.</li><li>Open the terminal in IntelliJ IDEA (<strong>View &gt; Tool Windows &gt; Terminal</strong>).</li></ul><ol><li>Switch to the target branch</li></ol><pre>git checkout uat</pre><p>Here, my target branch is uat. I want to get selected commits from the dev branch.</p><p>Then, ensure that your target branch is up to date.</p><pre> git pull origin uat </pre><p>2. cherry-pick the commit</p><p>If you have one commit to cherry-pick use this.</p><pre>git cherry-pick &lt;commit-hash&gt;</pre><p>The commit hash can be obtained by opening your repository in GitLab. Then, select the branch where the commit exists and go to commits. Then find the commit you want to cherry-pick, on the right side of the commit message. The commit hash exists, and then copy the commit hash from there.</p><p>If you have multiple commits to cherry-pick use this.</p><pre>git cherry-pick &lt;commit-hash-1&gt; &lt;commit-hash-2&gt;</pre><p>If you have a range of commits, use this. This will cherry-pick the commits from A to B.</p><pre>git cherry-pick A^..B</pre><p>3. Resolve merge conflicts (If any)</p><p>If merge conflicts occur, cherry-pick will pause. We need to resolve them to continue. To do that, use this to identify conflicting files.</p><pre>git status</pre><p>Then, open the conflicting files and manually resolve the conflicts.</p><p>Then we need to add the resolved files to git. For that, use this command.</p><pre>git add .</pre><p>Next, to continue cherry-pick, use command.</p><pre>git cherry-pick --continue</pre><p>If you want to abort the cherry-pick, use this command.</p><pre>git cherry-pick --abort</pre><p>4. Push the changes</p><p>Once cherry-pick is successful, push the changes to the target branch:</p><pre>git push origin uat</pre><p>5. Create a merge request</p><p>If you require to review the changes before merging, create a merge request in Git Lab.</p><p><strong>Cherry-pick using Git Lab UI</strong></p><p>GitLab provides an easy way to cherry-pick a commit directly from its interface. Here are the steps:</p><p>1. Navigate to Your Repository</p><ul><li>Open your project in GitLab.</li><li>Go to <strong>Repository &gt; Commits</strong>.</li></ul><p>2. Select the Commit to Cherry-Pick</p><ul><li>Use the branch selector to switch to the branch where the commit is exit (in my case, the dev branch).</li><li>Find the commit you want to cherry-pick.</li><li>Click on the commit message to open the commit details.</li></ul><p>3. Perform Cherry-Pick</p><ul><li>Click the <strong>Cherry-pick</strong> button at the top-right corner.</li><li>Select the <strong>target branch</strong> (In my case, the target branch is uat).</li><li>(Optional) Check <strong>Start a new merge request</strong> if you want to create an MR.</li><li>Click on <strong>Cherry-pick</strong>.</li></ul><p>GitLab will apply the commit to the selected branch. If conflicts occur, they must be resolved manually.</p><p><strong>Conclusion</strong></p><p>Cherry-pick is a powerful feature in Git that allows you to apply selected changes without merging entire branches. Whether using GitLab’s UI or the command line, understanding how to cherry-pick efficiently can help you manage changes effectively in your development workflow.</p><p>By following this article, you can easily cherry-pick commits and integrate necessary changes into your target branches without unnecessary modifications.</p><p>Happy coding!</p><p>References</p><p><a href="https://www.geeksforgeeks.org/git-cherry-pick/">Git - Cherry Pick - GeeksforGeeks</a></p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=01adb5cac577" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Efficient String Concatenation in Java using StringBuilder]]></title>
            <link>https://sitharihmd-19.medium.com/efficient-string-concatenation-in-java-using-stringbuilder-a7d8bc61b978?source=rss-12d302bdc56b------2</link>
            <guid isPermaLink="false">https://medium.com/p/a7d8bc61b978</guid>
            <category><![CDATA[java]]></category>
            <category><![CDATA[concatenation]]></category>
            <category><![CDATA[coding]]></category>
            <category><![CDATA[string-vs-stringbuilder]]></category>
            <category><![CDATA[string-builder]]></category>
            <dc:creator><![CDATA[Dilka Sithari]]></dc:creator>
            <pubDate>Sun, 15 Dec 2024 03:30:19 GMT</pubDate>
            <atom:updated>2025-01-05T00:04:00.595Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*p4o7aLd448T-khoZ4xCT2w.jpeg" /><figcaption>Photo by <a href="https://unsplash.com/@growtika?utm_content=creditCopyText&amp;utm_medium=referral&amp;utm_source=unsplash">Growtika</a> on <a href="https://unsplash.com/photos/a-red-and-black-circular-object-with-white-text-USzXVPP4Mqs?utm_content=creditCopyText&amp;utm_medium=referral&amp;utm_source=unsplash">Unsplash</a></figcaption></figure><p>String manipulation is a frequent task in Java programming that often hides subtle performance pitfalls. Whether you’re building dynamic messages, logging outputs, or constructing complex data, the way you concatenate strings can significantly improve your application’s efficiency.</p><p>While concatenating a few strings may seem trivial, scaling up can reveal performance bottlenecks, especially in high-throughput systems. In this article, we’ll explore the different approaches to string concatenation in Java, their performance characteristics, and how to choose the most efficient method for your needs.</p><p>By the end of this read, you’ll clearly understand when to use StringBuilder, the risks of + concatenation, and how compiler optimizations can sometimes save time. Let&#39;s dive in!</p><p>When working with strings in Java, performance challenges arise during string concatenation. Although the string class provides easy-to-use syntax, its immutable nature may lead to inefficiencies. StringBuilder is more suitable for efficient solutions when scenarios require multiple modifications or concatenations.</p><p>The String class in Java is immutable, meaning that any modification creates a new object rather than altering the existing object. Here is a small example that shows string concatenation using the String class.</p><pre>String str = &quot;Hello&quot;;<br>str += &quot; World&quot;;</pre><p>Each concatenation creates a new object which can lead to increasing memory usage. Every new object consumes memory. By creating new objects it reduces the performance with garbage collection. For small operations like this, it is noticeable, but when it comes to loops or large-scale concatenations it creates a significant bottleneck.</p><p>Let’s see how to avoid that bottleneck using the StringBuilder class.</p><pre>public static void main(String[] args) {<br>    StringBuilder builder = new StringBuilder();<br><br>    for (int i = 1; i &lt;= 5; i++) {<br>       builder.append(&quot;Hello World &quot;);<br>       builder.append(i);<br>       builder.append(&quot;\n&quot;);<br>    }<br><br>    String result = builder.toString();<br>    System.out.println(result);<br>}</pre><p>When using += for string concatenation in a loop, Java creates a new String object every time because strings are immutable, meaning the old string cannot be modified. Each operation involves copying the existing characters and the new addition into a completely new object, which leads to high memory usage, frequent garbage collection, and significant performance degradation as the loop scales. In contrast, StringBuilder is designed for efficient string manipulation by maintaining a mutable internal buffer that grows dynamically as needed. It modifies the buffer in place, avoiding unnecessary object creation and reducing memory overhead, making it the preferred choice for concatenating strings in loops or large-scale operations</p><p>StringBuilder class</p><p>StringBuilder class provides a mutable sequence of characters and it allows efficient string manipulation without creating new objects. StringBuilder is a perfect choice for scenarios involving frequent modifications. Let’s consider some features of StringBuilder.</p><ol><li>Mutable — Reduce memory overhead by allowing in-place modifications.</li><li>Fast — Designed for single-threaded applications where synchronization is unnecessary.</li><li>Rich API — Provides various methods for appending, inserting, replacing, deleting, and reversing strings.</li></ol><p>Next, we’ll look at the most commonly used methods of the StringBuilder class.</p><ol><li>append()</li></ol><p>Appends the specified string or value to the existing sequence.</p><pre>StringBuilder sb = new StringBuilder(&quot;Hello&quot;); <br>sb.append(&quot; World&quot;);<br>System.out.println(sb);</pre><p>Output — Hello World</p><p>2. insert()</p><p>Allows adding a string at a specific position.</p><pre>StringBuilder sb = new StringBuilder(&quot;Hello&quot;); <br>sb.insert(6, &quot; Java&quot;);<br>System.out.println(sb);</pre><p>Output — Hello Java</p><p>3. replace()</p><p>Replace a portion of the string with a new substring.</p><pre>StringBuilder sb = new StringBuilder(&quot;Hello Java&quot;);<br>sb.replace(6, 10, &quot;Hi&quot;);<br>System.out.println(sb);</pre><p>Output — Hello Hi</p><p>4. delete()</p><p>Removes characters within a specified range</p><pre>StringBuilder sb = new StringBuilder(&quot;Hello Java&quot;);<br>sb.delete(6, 10);<br>System.out.println(sb);</pre><p>Output — Hello</p><p>5. reverse()</p><p>Reverses the entire string sequence.</p><pre>StringBuilder sb = new StringBuilder(&quot;Hello World&quot;);<br>sb.reverse();<br>System.out.println(sb);</pre><p>Output — dlroW olleH</p><p>Let’s compare the performance of String vs StringBuilder</p><p>Using String</p><pre>public class StringConcatenation {<br>    public static void main(String[] args) {<br>        String result = &quot;&quot;;<br>        for (int i = 0; i &lt; 1000; i++) {<br>            result += i;<br>        }<br>        System.out.println(result);<br>    }<br>}</pre><p>In here using String creates a new String object in each iteration leading to significant performance degradation for large iterations.</p><p>Using StringBuilder</p><pre>public class StringBuilderConcatenation {<br>    public static void main(String[] args) {<br>        StringBuilder sb = new StringBuilder();<br>        for (int i = 0; i &lt; 1000; i++) {<br>            sb.append(i);<br>        }<br>        System.out.println(sb.toString());<br>    }<br>}</pre><p>By using StringBuilder modifies the same StringBuilder object resulting in faster execution and lower memory usage.</p><p>StringBuilder is used when frequent modifications are needed such as building SQL queries, generating reports, or processing text files. StringBuilder is used when dealing with large strings that grow dynamically and is especially useful for concatenating strings inside loops.</p><p>Best Practices with StringBuilder</p><ol><li><strong>Preallocate Capacity:</strong> If the final size of the string is known, use the StringBuilder(int capacity) constructor to avoid frequent resizing.</li></ol><pre>StringBuilder sb = new StringBuilder(1000);</pre><p>2. <strong>Avoid Multithreaded Scenarios:</strong> For thread-safe operations, use StringBuffer, which is synchronized but slightly slower.</p><p>3. <strong>Convert to String when needed: </strong>Use toString() to obtain the final String representation.</p><pre>String result = sb.toString();</pre><p>StringBuilder class is a powerful tool for efficient string concatenation and manipulation in Java. It eliminates the inefficiencies of string’s immutability and is a perfect choice for operations involving frequent string modifications. By using StringBuilder in appropriate places of the codes developers can write faster, more memory-efficient code.</p><p>Embrace StringBuilder for your next Java project and experience the performance.</p><p>References</p><p><a href="https://www.geeksforgeeks.org/stringbuilder-class-in-java-with-examples/">StringBuilder Class in Java with Examples - GeeksforGeeks</a></p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=a7d8bc61b978" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Encoding, Encryption, and Hashing in Java]]></title>
            <link>https://sitharihmd-19.medium.com/encoding-encryption-and-hashing-in-java-0b7debfc90da?source=rss-12d302bdc56b------2</link>
            <guid isPermaLink="false">https://medium.com/p/0b7debfc90da</guid>
            <category><![CDATA[hashing]]></category>
            <category><![CDATA[encoding]]></category>
            <category><![CDATA[security]]></category>
            <category><![CDATA[java]]></category>
            <category><![CDATA[encryption]]></category>
            <dc:creator><![CDATA[Dilka Sithari]]></dc:creator>
            <pubDate>Sun, 01 Dec 2024 14:49:31 GMT</pubDate>
            <atom:updated>2024-12-08T06:47:55.780Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/807/1*_07BnJuUXZDPyBwyWI0EuA.png" /></figure><p>In the digital age, managing data effectively and securely is a necessity. Encoding, Encryption, and Hashing are three essential techniques that are the backbone of data handling. While their purposes overlap in some scenarios, they are distinct, and understanding their differences is necessary for applying them appropriately in software development.</p><p>In this article, I will provide an in-depth look at these concepts with practical Java examples to help you implement them effectively.</p><p><strong>1. Encoding:</strong></p><p><strong>Encoding</strong> is the process of converting data into a different format to ensure compatibility during storage or transmission. It is not designed to be secure, as the encoded data can easily be decoded.</p><p>Key Characteristics</p><ul><li><strong>Purpose:</strong> Ensures various systems, protocols, or applications can process data.</li><li><strong>Reversibility:</strong> Fully reversible, meaning the original data can be retrieved.</li><li><strong>Security:</strong> Encoding itself does not provide any security; it’s meant for usability.</li></ul><p>Common Encording Formats</p><ul><li><strong>Base64:</strong> Encodes binary data as text for easier transmission.</li><li><strong>URL Encoding:</strong> Ensures special characters in URLs are properly represented.</li><li><strong>Character Encoding:</strong> Converts text into formats like UTF-8 for system compatibility.</li></ul><p><em>Java example for Base64 Encoding and Decoding</em></p><pre>import java.util.Base64;<br><br>public class Encoding {<br>    public static void main(String[] args) {<br>        String sampleText = &quot;Hello World&quot;;<br><br>        // Encoding<br>        String encodedText = Base64.getEncoder().encodeToString(sampleText.getBytes());<br>        System.out.println(&quot;Encoded Text: &quot; + encodedText);<br><br>        // Decoding<br>        String decodedText = new String(Base64.getDecoder().decode(encodedText));<br>        System.out.println(&quot;Decoded Text: &quot; + decodedText);<br>    }<br>}</pre><pre>Output<br><br>Encoded Text: SGVsbG8gV29ybGQ=<br>Decoded Text: Hello World</pre><p>Applications of Encoding:</p><ul><li><strong>Data Transmission:</strong> Encodes binary data for protocols like HTTP and SMTP.</li><li><strong>Embeddings:</strong> Stores images and media as encoded strings in HTML or XML.</li><li><strong>File Names:</strong> Encodes special characters in file names to ensure compatibility.</li></ul><p><strong>2. Encryption</strong></p><p><strong>Encryption</strong> secures data by converting it into an unreadable format, called ciphertext, using a cryptographic key. The ciphertext can only be decrypted back into the original plaintext with the correct key.</p><p>Types of Encryption</p><ol><li><strong>Symmetric Encryption:</strong> Uses the same key for both encryption and decryption.</li></ol><ul><li>Example: AES (Advanced Encryption Standard).</li></ul><ol><li><strong>Asymmetric Encryption:</strong> Uses a pair of keys, a public key for encryption, and a private key for decryption.</li></ol><ul><li>Example: RSA (Rivest-Shamir-Adleman).</li></ul><p>Key Characteristics</p><ul><li><strong>Purpose:</strong> Protects sensitive data during storage or transmission.</li><li><strong>Reversibility:</strong> Fully reversible with the correct decryption key.</li></ul><p><em>Java example for AES Encryption and Decryption</em></p><pre>import javax.crypto.Cipher;<br>import javax.crypto.KeyGenerator;<br>import javax.crypto.SecretKey;<br>import java.util.Base64;<br><br>public class Encryption {<br>    public static void main(String[] args) throws Exception {<br>        String sampleText = &quot;Sensitive Data&quot;;<br><br>        // Generate key<br>        KeyGenerator keyGen = KeyGenerator.getInstance(&quot;AES&quot;);<br>        keyGen.init(128);<br>        SecretKey secretKey = keyGen.generateKey();<br><br>        // Encrypt<br>        Cipher encryptCipher = Cipher.getInstance(&quot;AES&quot;);<br>        encryptCipher.init(Cipher.ENCRYPT_MODE, secretKey);<br>        byte[] encryptedBytes = encryptCipher.doFinal(sampleText.getBytes());<br>        String encryptedText = Base64.getEncoder().encodeToString(encryptedBytes);<br>        System.out.println(&quot;Encrypted: &quot; + encryptedText);<br><br>        // Decrypt<br>        Cipher decryptCipher = Cipher.getInstance(&quot;AES&quot;);<br>        decryptCipher.init(Cipher.DECRYPT_MODE, secretKey);<br>        byte[] decryptedBytes = decryptCipher.doFinal(Base64.getDecoder().decode(encryptedText));<br>        String decryptedText = new String(decryptedBytes);<br>        System.out.println(&quot;Decrypted: &quot; + decryptedText);<br>    }<br>}<br></pre><pre>Output<br><br>Encrypted: IKywwxdf5XVWvl0IvyXiGw==<br>Decrypted: Sensitive Data<br></pre><p>Applications of Encryption</p><ul><li><strong>Data Security:</strong> Secures communication over the internet (e.g., HTTPS).</li><li><strong>Data Storage:</strong> Encrypts files to prevent unauthorized access.</li><li><strong>Authentication:</strong> Ensures secure login credentials in systems.</li></ul><p><strong>3. Hashing</strong></p><p><strong>Hashing</strong> is a one-way process that transforms data into a fixed-length representation, known as a hash. Unlike encoding or encryption, hashing is irreversible, making it ideal for data integrity scenarios.</p><p>Key Characteristics</p><ul><li><strong>Purpose:</strong> Verifies the integrity of data.</li><li><strong>Reversibility:</strong> Irreversible, as the original data, cannot be derived from the hash.</li><li><strong>Security:</strong> Highly secure, especially for passwords and sensitive data.</li></ul><p>Common Hashing Algorithms</p><ul><li><strong>MD5:</strong> Provides a 128-bit hash</li><li><strong>SHA-256:</strong> Part of the SHA-2 family, provides a 256-bit hash.</li></ul><p><em>Java example for SHA-256 Hashing</em></p><pre>import java.security.MessageDigest;<br>import java.security.NoSuchAlgorithmException;<br><br>public class Hashing {<br>    public static void main(String[] args) throws NoSuchAlgorithmException {<br>        String password = &quot;Password@123&quot;;<br><br>        // Hashing<br>        MessageDigest digest = MessageDigest.getInstance(&quot;SHA-256&quot;);<br>        byte[] hash = digest.digest(password.getBytes());<br><br>        // Convert bytes to hex<br>        StringBuilder hexString = new StringBuilder();<br>        for (byte b : hash) {<br>            String hex = Integer.toHexString(0xff &amp; b);<br>            if (hex.length() == 1) hexString.append(&#39;0&#39;);<br>            hexString.append(hex);<br>        }<br>        System.out.println(&quot;Hashed Password: &quot; + hexString.toString());<br>    }<br>}<br></pre><pre>Output<br><br>Hashed Password: ff7bd97b1a7789ddd2775122fd6817f3173672da9f802ceec57f284325bf589f</pre><p>Applications of Hashing</p><ul><li><strong>Password Storage:</strong> Stores passwords securely in hashed form.</li><li><strong>Data Integrity:</strong> Verifies the integrity of files and transmitted data.</li><li><strong>Digital Signatures:</strong> Ensures the authenticity of digital messages and documents.</li></ul><p>Encoding, encryption, and hashing are powerful tools for data handling in modern applications.</p><ul><li>Use <strong>encoding</strong> to make data compatible across systems.</li><li>Use <strong>encryption</strong> to protect sensitive information.</li><li>Apply <strong>hashing</strong> to verify data integrity and securely store passwords.</li></ul><p>With Java’s rich libraries, we can easily implement these techniques to enhance the functionality and security of your applications. Always adhere to industry best practices to maintain high security and reliability standards.</p><p>Thank you for taking the time to read this article on <strong>encoding</strong>, <strong>encryption</strong>, and <strong>hashing in Java</strong>. It will provide valuable insights into these essential data-handling techniques and their practical implementations. By applying these concepts effectively, you can create secure, efficient, and reliable applications.</p><p>References</p><p><a href="https://www.geeksforgeeks.org/encryption-encoding-hashing/">Encryption vs Encoding vs Hashing - GeeksforGeeks</a></p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=0b7debfc90da" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[How to Resolve the “‘mvn’ is not recognized as an internal or external command, operable program or…]]></title>
            <link>https://sitharihmd-19.medium.com/how-to-resolve-the-mvn-is-not-recognized-as-an-internal-or-external-command-operable-program-or-145914fcaaab?source=rss-12d302bdc56b------2</link>
            <guid isPermaLink="false">https://medium.com/p/145914fcaaab</guid>
            <category><![CDATA[java]]></category>
            <category><![CDATA[resolve]]></category>
            <category><![CDATA[not-recognized]]></category>
            <category><![CDATA[error]]></category>
            <category><![CDATA[mvn]]></category>
            <dc:creator><![CDATA[Dilka Sithari]]></dc:creator>
            <pubDate>Mon, 07 Oct 2024 07:51:43 GMT</pubDate>
            <atom:updated>2024-10-13T02:42:36.576Z</atom:updated>
            <content:encoded><![CDATA[<h3>How to Resolve the “‘mvn’ is not recognized as an internal or external command, operable program or batch file.” Error on Windows</h3><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*3AR53yJnrCPLj2Rr6GqLsQ.jpeg" /><figcaption>Photo by Ron Lach : <a href="https://www.pexels.com/photo/person-facing-a-big-screen-with-numbers-9783346/">https://www.pexels.com/photo/person-facing-a-big-screen-with-numbers-9783346/</a></figcaption></figure><p>Maven (mvn) commands are widely used to automate tasks such as managing dependencies, building, packaging, testing, and deploying Java projects. However, sometimes you may encounter the following error when trying to run Maven commands:</p><pre>&#39;mvn&#39; is not recognized as an internal or external command, operable program or batch file.</pre><p>This error can occur due to several reasons. It usually indicates that Maven is not installed on your machine, or the environment variable MAVEN_HOME is not properly set. Let’s walk through the steps to resolve this issue.</p><h4>Step 1: Check if Maven is Installed</h4><p>The first step is to check if Maven is installed correctly. You can do this by opening the command prompt and running the following command:</p><pre>mvn -v</pre><p>If Maven is installed, this command should return version details. However, if you see an error like below, Let’s see how to resolve it.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/953/1*9ALkfMGOTy6tLI-2k0P17Q.png" /><figcaption>Figure 01</figcaption></figure><h4>Step 2: Check for Apache Maven Installation</h4><p>Before proceeding, verify if the <strong>apache-maven-3.9.9</strong> folder is present inside the C:\Program Files path. To do this:</p><ol><li>Open <strong>File Explorer</strong>.</li><li>Navigate to C:\Program Files.</li><li>Look for the folder named apache-maven-3.9.9.</li></ol><h4>Step 3: Download and Install Apache Maven (if not installed)</h4><p>If the folder is not present, you need to download and install Maven manually. Follow these steps:</p><ol><li>Visit the <a href="https://maven.apache.org/download.cgi">official Apache Maven download page</a>.</li><li>Under the <strong>Files</strong> section, you will find a link for the <strong>Binary zip archive</strong>, as shown below:</li></ol><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*cdiDqdRNnTZ2oYhGGe_Gag.png" /><figcaption>Figure 02</figcaption></figure><p>3. Click the link to download the archive file.</p><h4>Step 4: Extract and Install Maven</h4><p>Once the <strong>Binary zip archive</strong> is downloaded, follow these steps:</p><ol><li><strong>Extract the Zip File:</strong></li></ol><p>2. Right-click the downloaded file (apache-maven-3.9.9-bin.zip) and select <strong>Extract All</strong>. Extract it to the following path in your machine: C:\Program Files.</p><p>3. This will create a folder named apache-maven-3.9.9 inside the C:\Program Files directory.</p><h4>Step 5: Set Up Environment Variables</h4><p>To make Maven accessible from the command line, you need to configure the environment variables. For that, we need to open Environmental Variables Settings.</p><ul><li>Press Windows + S keys and type <strong>Environment variables</strong> in the search bar.</li><li>Click on <strong>Edit the system environment variables</strong>.</li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/540/1*Uy9xJnXLxgfGWrPkmFaTrg.png" /><figcaption>Figure 03</figcaption></figure><p>Once you click on <strong>Edit the system environment variables</strong>, the <strong>System Properties</strong> window will open like below. Click on the <strong>Environment Variables</strong> button at the bottom.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/595/1*jzBmYkfiU9BF0tnBuif8MA.png" /><figcaption>Figure 04</figcaption></figure><p>Once the <strong>Environment Variables</strong> window opens, under the <strong>System Variables</strong> section, click the <strong>New</strong> button.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/633/1*rJP7-V8zx3qL3LhXrLcwuw.png" /><figcaption>Figure 05</figcaption></figure><h4>Step 6: Set MAVEN_HOME Variable</h4><p>In the <strong>New System Variable</strong> window, for the <strong>Variable name</strong>, enter: MAVEN_HOME, For the <strong>Variable value</strong>, provide the path to where you extracted the Maven folder. On most systems, this will be:</p><ul><li>C:\Program Files\apache-maven-3.9.9</li></ul><p><em>(If you extracted it to a different location, enter the corresponding path.)</em></p><p>Click <strong>OK</strong> to save the new variable.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*SnP6NC-n45WTSG-I0F8k5A.png" /><figcaption>Figure 06</figcaption></figure><h4>Step 7: Update the PATH Variable</h4><ol><li>Under the <strong>System Variables</strong> section in the <strong>Environment Variables</strong> window, scroll down and find the variable named <strong>Path</strong>.</li><li>Select <strong>Path</strong> and click the <strong>Edit</strong> button.</li></ol><p>This will open the <strong>Edit Environment Variable</strong> window, where you can modify the system’s path settings.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/833/1*0Q8jJMmiNN2rCtEq3QGMuQ.png" /><figcaption>Figure 07</figcaption></figure><h4>Step 8: Add Maven to PATH</h4><ol><li>In the <strong>Edit Environment Variable</strong> window that opens, click on the <strong>New</strong> button.</li><li>Paste the path to the Maven bin folder, which is usually:</li></ol><p>C:\Program Files\apache-maven-3.9.9\bin</p><p>Once you’ve added the path, click <strong>OK</strong> to save the changes.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/545/1*7g5yCbRtbndq9pxsZN7qAQ.png" /><figcaption>Figure 08</figcaption></figure><p>Finally, click <strong>OK</strong> on all the other windows to close them and apply the changes.</p><h4>Step 9: Verify Maven Installation</h4><p>To confirm that Maven has been installed successfully, open the <strong>Command Prompt</strong> <strong>t</strong>ype the following command, and press <strong>Enter</strong>:</p><ul><li>mvn -v</li></ul><p>If the installation is successful, you should see output that includes the Maven version, Java version, and other related information, similar to the example below:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/975/1*Vdq-9luZeqboNMJZwM2pHw.png" /><figcaption>Figure 09</figcaption></figure><p>Setting up Maven on your machine might seem tricky at first, but by following the steps outlined above, you can easily resolve the common errors and configure Maven successfully. Once Maven is installed and working correctly, you can leverage its powerful capabilities to manage your Java projects efficiently. Whether it’s handling dependencies, building, or deploying projects, Maven will save you time and effort, allowing you to focus on coding and project development.</p><p>Happy coding with Maven!</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=145914fcaaab" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Fibonacci Series in Java: A Complete Guide for Coding Interviews]]></title>
            <link>https://sitharihmd-19.medium.com/fibonacci-series-in-java-a-complete-guide-for-coding-interviews-257558f158c1?source=rss-12d302bdc56b------2</link>
            <guid isPermaLink="false">https://medium.com/p/257558f158c1</guid>
            <category><![CDATA[coding-interviews]]></category>
            <category><![CDATA[java]]></category>
            <category><![CDATA[coding]]></category>
            <category><![CDATA[fibonacci-series]]></category>
            <dc:creator><![CDATA[Dilka Sithari]]></dc:creator>
            <pubDate>Wed, 25 Sep 2024 04:59:25 GMT</pubDate>
            <atom:updated>2024-09-29T03:46:05.143Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*Cyk054IW7RkdLz0kvULlLg.jpeg" /><figcaption>Photo by <a href="https://unsplash.com/@davidclode?utm_content=creditCopyText&amp;utm_medium=referral&amp;utm_source=unsplash">David Clode</a> on <a href="https://unsplash.com/photos/a-close-up-of-a-shell-on-a-black-background-MNEGikPGkAM?utm_content=creditCopyText&amp;utm_medium=referral&amp;utm_source=unsplash">Unsplash</a></figcaption></figure><p>Welcome, everyone, to my next article!</p><p>When facing software engineering interviews, especially in Java, you’re likely to be asked to write simple programs. One popular question is writing code for the <strong>Fibonacci series</strong>. Let’s get ready for this common coding challenge!</p><p>Have you ever heard of the Fibonacci series? I think many of you have. But if not, don’t worry — I’ll walk you through it in this article.</p><p>The Fibonacci series is a sequence of numbers where each number is the sum of the previous two numbers. The first two numbers of the Fibonacci series are 0 and 1.</p><p>Mathematically, the Fibonacci sequence can be represented as:</p><p>F(n) = F(n-1) + F(n-2)</p><p>Where,</p><p>F(0)=0;</p><p>F(1)=1;</p><p>And for all n&gt;1, F(n) = F(n-1) + F(n-2)</p><p>Here are the first few numbers in the Fibonacci series:</p><p>0, 1, 1, 2, 3, 5, 8, 13, 21, 34, 55, 89, …</p><p>In this article, I will guide you through writing a simple Java program to print the Fibonacci series.</p><p><strong>Step 1: Creating the Java Class</strong></p><p>First, we need to create a Java class. Here, I will create a class named FibonacciSeries. Then, we need to define the main method, which is the program&#39;s entry point.</p><pre>public class FibonacciSeries {<br>    public static void main(String[] args) {<br>        <br>    }<br>}</pre><h4>Step 2: Reading User Input</h4><p>Next, we create an Scanner object to read input from the user. We will also create a variable count to store the number of terms users want to generate in the Fibonacci series.</p><pre>import java.util.Scanner;<br><br>public class FibonacciSeries {<br>    public static void main(String[] args) {<br>        Scanner scanner = new Scanner(System.in);<br>        System.out.print(&quot;Enter the number of terms for the Fibonacci Series: &quot;);<br>        int count = scanner.nextInt();<br>    }<br>}</pre><h4>Step 3: Initializing Variables</h4><p>We now create variables n1 and n2 to store the first two terms of the Fibonacci series. Additionally, we create a variable n3 to store the next term in the sequence.</p><pre>int n1 = 0, n2 = 1, n3;</pre><h4>Step 4: Printing the First Two Terms</h4><p>The first two numbers are always 0 and 1 in the Fibonacci series, so we print them first.</p><pre>System.out.print(n1 + &quot;,&quot; + n2);</pre><h4>Step 5: Generating the Series Using a Loop</h4><p>To generate the remaining terms in the series, we use a for loop. The loop starts at i = 2 because the first two terms are already printed. The loop continues until the desired number of terms is generated. Each iteration calculates the next term by summing the previous two terms (n1 and n2).</p><pre>for (int i = 2; i &lt; count; i++) {<br>    n3 = n1 + n2;<br>    System.out.print(&quot;,&quot; + n3);<br>    n1 = n2;<br>    n2 = n3;<br>}</pre><h4>Step 6: Full Code Example</h4><p>Here is the complete Java program to print the Fibonacci series based on the user’s input:</p><pre>import java.util.Scanner;<br><br>public class FibonacciSeries {<br>    public static void main(String[] args) {<br>        Scanner scanner = new Scanner(System.in);<br>        System.out.print(&quot;Enter the number of terms for the Fibonacci Series: &quot;);<br>        int count = scanner.nextInt();<br>        int n1 = 0, n2 = 1, n3;<br>        System.out.print(n1 + &quot;,&quot; + n2);<br>        for (int i = 2; i &lt; count; i++) {<br>            n3 = n1 + n2;<br>            System.out.print(&quot;,&quot; + n3);<br>            n1 = n2;<br>            n2 = n3;<br>        }<br>        scanner.close(); <br>    }<br>}</pre><h3>Explanation of the For Loop</h3><ul><li>The loop starts from i = 2 because the first two terms (0 and 1) have already been printed.</li><li>The loop runs until i &lt; count, ensuring that the desired number of terms is printed.</li><li>n3 holds the sum of the previous two terms (n1 and n2).</li><li>After each iteration, n1 and n2 are updated with the values of the next terms to continue generating the series.</li></ul><p>This article demonstrated how to write a simple Java program to generate the Fibonacci series, from reading user input to printing the series. The Fibonacci sequence is an essential concept, and this program provides a great way for beginners to understand loops and basic arithmetic operations in Java.</p><p>The Fibonacci series is a mathematical concept and a fundamental pattern observed in nature and various fields. From the arrangement of leaves and petals in plants to the branching of trees and the proportions in human anatomy, the sequence manifests in countless natural phenomena. It also finds applications in art, architecture, computer algorithms, and even financial markets, showcasing the profound connections between mathematics and the world around us. Understanding Fibonacci enriches our knowledge of mathematics and deepens our appreciation for the beauty of nature and human creativity.</p><h3>Coding Challenge: Fibonacci Series Using Recursion</h3><p>Now that you’ve learned how to generate the Fibonacci series using loops, let’s take it a step further! For this coding challenge, I want you to implement the Fibonacci series using <strong>recursion</strong> in Java.</p><h4>Challenge Description:</h4><p>Write a Java program to print the Fibonacci series up to n terms using a recursive function. In this approach, the function will call itself to calculate the next Fibonacci number.</p><h4>Hints:</h4><ul><li>Create a recursive method that takes an integer n as input.</li><li>The base cases for the recursion should be when n == 0 and n == 1.</li><li>For other values, the method should return the sum of the previous two Fibonacci numbers (F(n-1) and F(n-2)).</li></ul><p>Thank you for reading. I look forward to sharing more insights with you in my next article.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=257558f158c1" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Installing Tailwind CSS with Angular for Streamlined Web Development]]></title>
            <link>https://sitharihmd-19.medium.com/installing-tailwind-css-with-angular-for-streamlined-web-development-c74a75eb7e1c?source=rss-12d302bdc56b------2</link>
            <guid isPermaLink="false">https://medium.com/p/c74a75eb7e1c</guid>
            <category><![CDATA[angular]]></category>
            <category><![CDATA[tailwind-css]]></category>
            <dc:creator><![CDATA[Dilka Sithari]]></dc:creator>
            <pubDate>Sat, 16 Mar 2024 04:52:42 GMT</pubDate>
            <atom:updated>2024-03-16T04:52:42.903Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*cTkxbbw7LzjthWiIpbFPxQ.png" /></figure><p>Hi Everyone ……..</p><p>Welcome to my next article. Here I am going to discuss how to install Tailwind CSS with Angular. If you are a beginner to Angular check out my article about creating an Angular project.</p><p><a href="https://medium.com/nerd-for-tech/creating-and-initiating-your-first-angular-project-on-github-8f7611dc1bc5">Creating and Initiating Your First Angular Project on GitHub</a></p><p>Open your angular project on a preferred IDE. Then run the project using the below command.</p><pre>ng serve --open</pre><p>Then your Angular project started in default port 4200.</p><p>Let’s start to install Tailwind CSS to our Angular project. For that first, you need to go to tailwindcss.com&#39;s official website. I’ll paste the link below for your ease.</p><p><a href="https://tailwindcss.com/">Tailwind CSS - Rapidly build modern websites without ever leaving your HTML.</a></p><p>There you will see an interface like this. Click on the <em>Get started</em> button.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*wR2AXBP2o4XtnOda75ewIQ.png" /><figcaption>Figure 01</figcaption></figure><p>Next, click on <em>Framework Guides</em>.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*2_Lrmfj8LJYDCD1Hq_pSDA.png" /><figcaption>Figure 02</figcaption></figure><p>Then scroll down the page and click on <em>Angular</em>.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/777/1*9vTECGwucUVcxaSrW4Ewjg.png" /><figcaption>Figure 03</figcaption></figure><p>Then you will see a set of steps you have to follow. we will see one by one.</p><p>If you still have not created a new project, first of all, create a new project by the below two commands. You will also see these commands on the website.</p><pre>ng new my-project<br>cd my-project</pre><p>For the installation of Tailwind CSS run the below command in your terminal.</p><pre>npm install -D tailwindcss postcss autoprefixer</pre><p>Here you’ll see your terminal looks like this after the installation process is completed.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*4fGcnVbq7TbBzJQmdTiz3A.png" /><figcaption>Figure 04</figcaption></figure><p>If the installation process is successful you will see the Tailwind CSS version number on your package.json file.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/535/1*yhH_oWbWcItE5JQ1PhwWtA.png" /><figcaption>Figure 05</figcaption></figure><p>After that to generate a <em>tailwind.config.js</em> file run the init command in the terminal.</p><pre>npx tailwindcss init</pre><p>Then you will see a message like Created Tailwind CSS config file: tailwind.config.js.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/611/1*tft2pseNr_ZOxuWxfs662A.png" /><figcaption>Figure 06</figcaption></figure><p>To configure the template paths add the paths to all of your template files in your newly created <em>tailwind.config.js</em> file. In my case, I’ll add paths of <em>app.component.html</em> file and <em>app.component.spec.ts</em> file paths. Here is how my <em>tailwind.config.js </em>file appears after adding paths.</p><pre>/** @type {import(&#39;tailwindcss&#39;).Config} */<br>module.exports = {<br>  content: [<br>    &quot;./src/app/app.component.html&quot;,<br>    &quot;./src/app/app.component.spec.ts&quot;,<br>  ],<br>  theme: {<br>    extend: {},<br>  },<br>  plugins: [],<br>}</pre><p>Then go to your<em> styles.css</em> file and add the @tailwind directives to your CSS. Here is how my <em>styles.css</em> file looks after adding Tailwind directives.</p><pre>@tailwind base;<br>@tailwind components;<br>@tailwind utilities;</pre><p>If you are done with this step you are done with the installation process.</p><p>Now you have to start the build process. If your project is already running stop the process by pressing ctrl+C and rebuild the process with the below command.</p><pre>ng serve --open</pre><p>Let’s try Tailwind in our project. For that create a simple h1 tag in your app.component.html file and use Tailwind’s utility classes to style the content inside the h1 tag.</p><pre>&lt;h1 class=&quot;text-3xl font-bold underline&quot;&gt;<br>  Hello world!<br>&lt;/h1&gt;</pre><p>If you see the output like the below image you are done with the Tailwind CSS installation process. Now you can streamline your web development by adding Tailwind’s utility classes.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/288/1*7M8Q8ZJ_nE_Ah5PqAKGRUw.png" /><figcaption>Figure 07</figcaption></figure><p>You can find Tailwind’s utility classes on the tailwindcss.com website and you can now directly use those utility classes in your project.</p><p>Hope you enjoy my article. If any concerns or queries arise, I welcome your comments for further clarification or refinement. <br>Thank you.</p><p>Happy Coding……….</p><p>References</p><p><a href="https://tailwindcss.com/docs/guides/angular">Install Tailwind CSS with Angular - Tailwind CSS</a></p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=c74a75eb7e1c" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[How to Resolve Error: ng.ps1 cannot be loaded because running scripts is disabled on this system]]></title>
            <link>https://sitharihmd-19.medium.com/how-to-resolve-error-ng-ps1-cannot-be-loaded-because-running-scripts-is-disabled-on-this-system-8d346612c44a?source=rss-12d302bdc56b------2</link>
            <guid isPermaLink="false">https://medium.com/p/8d346612c44a</guid>
            <category><![CDATA[issues]]></category>
            <category><![CDATA[fix]]></category>
            <category><![CDATA[resolve-error]]></category>
            <category><![CDATA[angular]]></category>
            <category><![CDATA[ng-command]]></category>
            <dc:creator><![CDATA[Dilka Sithari]]></dc:creator>
            <pubDate>Sun, 11 Feb 2024 06:43:56 GMT</pubDate>
            <atom:updated>2024-02-11T06:43:56.384Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*enHw_6xZfQEaE05EMWdweA.jpeg" /><figcaption>Photo by <a href="https://unsplash.com/@markusspiske?utm_content=creditCopyText&amp;utm_medium=referral&amp;utm_source=unsplash">Markus Spiske</a> on <a href="https://unsplash.com/photos/matrix-movie-still-iar-afB0QQw?utm_content=creditCopyText&amp;utm_medium=referral&amp;utm_source=unsplash">Unsplash</a></figcaption></figure><p>Hello Everyone!!!</p><p>If you are working with Angular ng commands and getting the error ng.ps1 cannot be loaded because running scripts is disabled on this system, this article may help you to resolve the issue.</p><p>Let’s start with how to fix the issue. Enjoy the article ….</p><p>Here I attached the error appearing when I am working with ng commands in my visual studio.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/840/1*bV82PxYurkR0nZ5BIIoXHA.png" /><figcaption>Figure 01 — Error Message</figcaption></figure><p>This error occurs due to security reasons. Without our approval, this would not let us execute the script in our system. This means that the system has disabled the running scripts and the system can’t accept the ng commands. Then what we can do to resolve this is open the PowerShell with administrative rights. To do this let’s follow these steps.</p><p><strong>Step 01</strong></p><p>Run the below command in the terminal.</p><pre>set-ExecutionPolicy RemoteSigned -Scope CurrentUser</pre><p>After running this command you will see your terminal like below.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/782/1*mCvpHSQU03N7umitCzvFTQ.png" /><figcaption>Figure 02 — Step 01</figcaption></figure><p>Now you are ready to go to step 02.</p><p><strong>Step 02</strong></p><p>As step 02 you have to run the below command in your terminal.</p><pre>Get-ExecutionPolicy</pre><p>After running this command your system will show a message like “RemoteSigned” as below image. If you get this message you will resolve the issue by following the coming steps.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/601/1*iB5gNheGFl6EOykFpIZXYg.png" /><figcaption>Figure 03 — Step 02</figcaption></figure><p><strong>Step 03</strong></p><p>Step 03 is to view the list of policies which policy has been updated by the last commands. To view their policy next you need to run the below command in your terminal.</p><pre>Get-ExecutionPolicy -list</pre><p>Then you will see the list of policies in your terminal like in the below image.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/622/1*tILX-xXWx9bPd73WWRjv2A.png" /><figcaption>Figure 04 — Step 03</figcaption></figure><p>Now you have successfully fixed the issue. To check that you can run ng commands and see whether they are working properly. To Check that here I run “ng version” command in the same terminal. Here is my output.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/607/1*4b1ANFCgcEC2nS16Mgq_5w.png" /><figcaption>Figure 05 — Error Resolved Image</figcaption></figure><p>You can see that now ng command is working properly and the issue is now fixed.</p><p>Hope you enjoyed my article.</p><p>Happy Coding ……….</p><p>Thank you!</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=8d346612c44a" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Creating and Initiating Your First Angular Project on GitHub]]></title>
            <link>https://sitharihmd-19.medium.com/creating-and-initiating-your-first-angular-project-on-github-8f7611dc1bc5?source=rss-12d302bdc56b------2</link>
            <guid isPermaLink="false">https://medium.com/p/8f7611dc1bc5</guid>
            <category><![CDATA[github]]></category>
            <category><![CDATA[angular-cli]]></category>
            <category><![CDATA[angularjs]]></category>
            <category><![CDATA[vscode]]></category>
            <dc:creator><![CDATA[Dilka Sithari]]></dc:creator>
            <pubDate>Sun, 11 Feb 2024 06:42:06 GMT</pubDate>
            <atom:updated>2024-02-11T06:42:06.906Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*B7wnk3C0P8XEyyMKGli4VA.png" /></figure><p>Hello Everyone…</p><p>In this article, I am going to discuss how to create a new Angular App and how to put that project into your GitHub account.</p><p>Let’s get started.</p><p>Prior to creating your first Angular App, you need to check whether the correct version of Node.js is installed in your system. To check that simply give the below command in your command prompt.</p><pre>npm --version</pre><p>If you have already installed NodeJS in your system will give the version number of Node.js installed. In my case, it is 10.2.5. It will show like in the below image.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/541/1*d_e2dKKMTtbjCgkZp7tkXw.png" /><figcaption>Figure 01 — Checking the Node.js version</figcaption></figure><p>If you see version number 8.5.0 or later, you are ready to go with creating an Angular App.</p><p>In case you haven’t installed Node.js in your system don’t worry you can download Node.js from their official website. I will put the link below. Just download it according to your operating system and install it on your system.</p><p><a href="https://nodejs.org/en/download">Node.js - Download Node.js®</a></p><p>After downloading and installing Node.js you need to check the version.</p><p>Then you need to install Angular CLI for that run the below command on your command prompt.</p><pre>npm install -g @angular/cli</pre><p>After installing Angular CLI you can verify installation by running the below command.</p><pre>ng version</pre><p>Then you will see the version information of Angular CLI like below in the image.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/773/1*dbVlFS7b4Lxq_1o0m9DnWQ.png" /><figcaption>Figure 2 — Angular CLI</figcaption></figure><p>Now we are ready to create our new Angular App.</p><p>Create a new folder in any location you like. In my case, I created a folder named angular-project on my desktop.</p><p>If you haven&#39;t downloaded and installed Visual Studio IDE yet, don’t worry I have put the link below to download it. You can download and install it easily.</p><p><a href="https://code.visualstudio.com/download">Download Visual Studio Code - Mac, Linux, Windows</a></p><p>To easily open the project in Visual Studio code you need to open the command prompt inside your newly created folder. In my case, I open the command prompt on the desktop. Then type <strong><em>code .</em></strong> in the command prompt and press enter. The folder opens in Visual Studio code.</p><p>To create a new angular project you need to open the terminal in VS code. For that simply click on Terminal-&gt;New Terminal.</p><p>Then terminal will open, in the terminal run the below command to create a new angular project. In my case, I give the project name as angular-project. You can give any name you like.</p><pre>ng new angular-project</pre><p>This will take some time to execute, and make sure you have a good internet connection as well.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1023/1*O9hjoAeF0A3BVQn_VuKPqw.png" /><figcaption>Figure 5 — Create Angular Project</figcaption></figure><p>After completing the execution of the ng create command, the terminal will appear like the above in the image. You can see that the necessary files and folders are created.</p><p>Also, you can see the files and folders on the left side of the VS code.</p><p>Now you have successfully created your Angular App.</p><p>You can open the project in the browser by running the below command.</p><pre>ng serve --open</pre><p>Then we’ll see how to put this project into your GitHub account. Then you can work on the project and commit the changes.</p><p>If you do not have a GitHub account you can create one for yourself. Simply you need to follow some steps. I will paste the link to GitHub for you.</p><p><a href="https://github.com/">GitHub · Change is constant. GitHub keeps you ahead. · GitHub</a></p><p>Working with git commands is easy when we are coding with VS code. So you need to log in to your GitHub account through VS code in the source control section in the left side upper part of the IDE. After that, you can simply create a new repository and commit and push the changes by going through the source control section of VS code.</p><p>Now we are done with creating our Angular Project and putting that project to GitHub.</p><p>I think you enjoyed my article. Thank you for reading.</p><p>Happy Coding……..</p><p>References</p><p><a href="https://angular.io/quick-start">Angular</a></p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=8f7611dc1bc5" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Comprehensive Introduction to Cloud Computing]]></title>
            <link>https://sitharihmd-19.medium.com/comprehensive-introduction-to-cloud-computing-386792d3de1b?source=rss-12d302bdc56b------2</link>
            <guid isPermaLink="false">https://medium.com/p/386792d3de1b</guid>
            <category><![CDATA[introduction-to-cloud]]></category>
            <category><![CDATA[cloud-service-models]]></category>
            <category><![CDATA[cloud-services]]></category>
            <category><![CDATA[cloud-computing]]></category>
            <dc:creator><![CDATA[Dilka Sithari]]></dc:creator>
            <pubDate>Mon, 29 Jan 2024 08:45:24 GMT</pubDate>
            <atom:updated>2024-01-29T08:45:24.497Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*y78Nld9kBV77wWxHBeqfKA.jpeg" /><figcaption>Photo by Christina Morillo: <a href="https://www.pexels.com/photo/software-engineer-standing-beside-server-racks-1181354/">https://www.pexels.com/photo/software-engineer-standing-beside-server-racks-1181354/</a></figcaption></figure><p>We are now in a digital era where cloud computing has become a fundamental technology. Simply cloud computing is the delivery of computing services over the internet. Cloud computing allows users to access and utilize the resources remotely through the internet. Think about how cloud computing eases access and utilizes resources remotely through the internet instead of relying on local servers or personal devices to handle data and applications.</p><p>Cloud Computing has many service models. I have mentioned about some of them. For an in-depth study of cloud computing service models, it is recommended to consult the references provided in this article</p><p>01. Infrastructure as a service(IaaS)</p><p>02. Platform as a service(PaaS)</p><p>03. Software as a service(SaaS)</p><p>04. Backend as a service (BaaS)</p><p>05. Function as a service (FaaS)</p><p><strong>01. Infrastructure as a service(IaaS)</strong></p><p>This service model extends virtualized computing resources delivered over the internet, more over this allows users to access and manage fundamental computing infrastructure elements such as virtual machines, storage, networking, Operating Systems, Security Components, Monitoring and Management Tools, Load Balancers, APIs and Backup and Disaster Recovery Services.</p><p><strong>02. Platform as a service(PaaS)</strong></p><p>This service model provides a platform to facilitate the development, deployment, and management of applications without the complexities of managing the underlying infrastructure. PaaS abstracts a significant portion of infrastructure management tasks, enabling developers to concentrate on coding, testing, and deploying their applications.</p><p>Examples of PaaS service providers are Amazon Sage maker cloud App engine Heroku, Google App Engine, and Microsoft Azure App Service.</p><p><strong>03. Software as a service(SaaS)</strong></p><p>This service model delivers software applications over the Internet on a subscription basis. Instead of users installing and maintaining software on their local devices or servers, SaaS provides access to applications directly through a web browser. This model is designed to streamline software delivery, reduce maintenance efforts, and offer scalability based on the user’s needs. The key characteristics of SaaS include accessibility, subscription-based pricing, automatic updates, scalability, and centralized data storage.</p><p>Examples of SaaS include Salesforce which is a customer relationship management (CRM) platform, Microsoft 365, Google Workspace, and Figma.</p><p><strong>04. Backend as a service (BaaS)</strong></p><p>BaaS is a cloud computing service model that provides developers with pre-built backend infrastructure components and services, allowing them to focus on building the front end and core features of their applications. BaaS simplifies the development process by abstracting away the complexities of backend infrastructure management, such as server maintenance, database management, and user authentication. The key characteristics of BaaS include backend service, APIs, scalability, user authentication and authorization, data storage, file storage, push notifications, and serverless computing. This service model is important for developers who are looking to grow the development process, reduce the infrastructure management overhead, and build scalable and feature-rich applications with less backend complexity.</p><p>Examples of BaaS service providers include Firebase(Google) and AWS Amplify (Amazon Web Services).</p><p><strong>05. Function as a service (FaaS)</strong></p><p>FaaS is a cloud computing service model that allows developers to execute individual functions or pieces of code in response to events without the need to manage the underlying infrastructure. FaaS is a subset of serverless computing, where developers focus on writing code functions and delegate operational responsibilities, such as server provisioning and scaling, to the cloud provider. The key characteristics of FaaS include event-driven execution, stateless functions, automatic scaling, pay-as-you-go pricing, short-lived execution, and support for multiple programming languages.</p><p>Examples of FaaS include AWS Lambda, Azure Functions, and Google Cloud Functions.</p><p>While cloud computing presents a multitude of advantages, it is essential to acknowledge the accompanying challenges as well. Here I mention some advantages and disadvantages of cloud computing.</p><p><strong>Advantages of cloud computing</strong></p><ol><li>Scalability</li><li>Cost Efficiency</li><li>Accessibility</li><li>Reliability and Redundancy</li><li>Automatic Updates</li><li>Global Level Collaboration</li><li>Collaboration and Mobility</li><li>Resource Management</li><li>Free Maintainance Backups</li><li>Pay for Usage</li></ol><p><strong>Disadvantages of Cloud Computing</strong></p><ol><li>Security Concerns</li><li>Downtime and Reliability</li><li>Dependency on Internet Connectivity</li><li>Limited Customization</li><li>Data Transfer Costs</li><li>Lack of control</li></ol><p>I trust that you find value in this article and derive insights from its content. Your feedback is highly appreciated, if you have any concerns or inquiries, please feel free to articulate them in the comments section. Your engagement is essential as it contributes to the continual refinement and enhancement of the information presented.</p><p>Thank you for your time and consideration.</p><p><strong>References</strong></p><ul><li><a href="https://www.javatpoint.com/cloud-service-models">Cloud Service Models - javatpoint</a></li><li><a href="https://www.javatpoint.com/advantages-and-disadvantages-of-cloud-computing">Advantages of Cloud Computing - javatpoint</a></li><li><a href="https://www.guru99.com/advantages-disadvantages-cloud-computing.html">Advantages and Disadvantages of Cloud Computing</a></li></ul><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=386792d3de1b" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Learn Java from the Beginning]]></title>
            <link>https://medium.com/linkit-intecs/learn-java-from-the-beginning-878469ce0366?source=rss-12d302bdc56b------2</link>
            <guid isPermaLink="false">https://medium.com/p/878469ce0366</guid>
            <category><![CDATA[jdk]]></category>
            <category><![CDATA[java]]></category>
            <category><![CDATA[programming]]></category>
            <category><![CDATA[beginner-coding]]></category>
            <category><![CDATA[eclipse]]></category>
            <dc:creator><![CDATA[Dilka Sithari]]></dc:creator>
            <pubDate>Wed, 17 Aug 2022 10:41:18 GMT</pubDate>
            <atom:updated>2022-08-17T10:41:18.574Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*_TF41GE3B9jE_O9qKeqzdw.jpeg" /><figcaption>Photo by <a href="https://unsplash.com/@cgower?utm_source=unsplash&amp;utm_medium=referral&amp;utm_content=creditCopyText">Christopher Gower</a> on <a href="https://unsplash.com/s/photos/java?utm_source=unsplash&amp;utm_medium=referral&amp;utm_content=creditCopyText">Unsplash</a></figcaption></figure><p>Welcome to my first article on java.</p><p>Java is a high-level programming language.</p><p>Java is,</p><ol><li><strong>Free and Open Source — </strong>Once we install Java, we can start working with it.</li><li><strong>Cross Platform Compatible — </strong>Java can run on any operating system such as Windows, Mac, or Linux. We can run the same java project in whatever operating system we have.</li><li><strong>Object-oriented</strong> — Can represent all the objects from the programming point of view.</li></ol><p>To start learning Java, first, we need to download java JDK for our computer.</p><p>Let’s see how we can download JDK,</p><p>First, just search for download JDK from your browser as shown in image 01.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/872/1*yObXwMOKv_jnMFfqzq4_BA.png" /><figcaption>Image 01</figcaption></figure><p>Then click on the first link in the search results. When scrolling down we can see JDK downloadable links for Linux, macOS, and Windows as image 02.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*DwLvcyPYXOnipwdajQJXeg.png" /><figcaption>Image 02</figcaption></figure><p>Click on your operating system. My Operating System is Windows, so I click on Windows. Then it will display as in image 03.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*0hV2-lOOra9WHE486J0ifA.png" /><figcaption>Image 03</figcaption></figure><p>Now click on the link in the 64-bit installer as image 04.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*8hL0g_m8dVV_-gQpXv7iAg.png" /><figcaption>Image 04</figcaption></figure><p>Then JDK will start downloading to your computer.</p><p>For your ease, I just paste the link below,</p><p><a href="https://www.oracle.com/java/technologies/downloads/#jdk18-windows">Download the Latest Java LTS Free</a></p><p>JDK Stands for ‘Java Development Kit’ which means a kit for programming all Java concepts and a kit that helps to create and execute programs.</p><p>Let’s set up Integrated Development Environment(IDE) for Java. Now here we download and install Eclipse.</p><p>Eclipse provides a proper platform or proper development so that we can code in a very easy way.</p><p>To download Eclipse go to the below link.</p><p><a href="https://www.eclipse.org/downloads/">Eclipse Downloads | The Eclipse Foundation</a></p><p>Click on the download buttons respectively as in images 05 and 06.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/828/1*GWox4HT9WSDicpBb7yP8mg.png" /><figcaption>Image 05</figcaption></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*7_sEgvVBhOfnDgxBgXNBjw.png" /><figcaption>Image 06</figcaption></figure><p>Then it will begin to download.</p><p>Next, let’s install Eclipse on our computer.</p><p>When downloading is completed double click on Eclipse exe file. Then image 07 like window opens up and next click on Eclipse IDE for Java Developers.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/402/1*5REWpwE5e4wB1wTtjsGjRg.png" /><figcaption>Image 07</figcaption></figure><p>Next click on the install button. Then the installation process will begin as image 08.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/441/1*InxdqafRCrOpC6LZdu5elQ.png" /><figcaption>Image 08</figcaption></figure><p>Then below window open up as image 09. Click on Accept Now button.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/430/1*VBFnkIlzV_qCu1RdvdQNZQ.png" /><figcaption>Image 09</figcaption></figure><p>Then it starts installing as image 10.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/447/1*IlkJEYTrxC3kZiymW3l2SA.png" /><figcaption>Image 10</figcaption></figure><p>Then click on the Launch button as in image 11.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/456/1*Sn3DoAyE8_4QZHAZfttWYQ.png" /><figcaption>Image 11</figcaption></figure><p>Now downloading and installing are completed. Here browse a location to save the projects, then click on Launch as image 12.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/556/1*4Q49u-BEY18HUsecGlJfwA.png" /><figcaption>Image 12</figcaption></figure><p>Now let’s create our first java project on eclipse. Click on file, new, java project as image 13.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/611/1*4gVuAyEcfnB4eeH_ZbbOpg.png" /><figcaption>Image 13</figcaption></figure><p>Then below window open up as image14, so we need to give a project name. Here I give the name test_project. After giving the name click on the finish button.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/537/1*ZklpIwTn3CssKUDxrmiFzQ.png" /><figcaption>Image 14</figcaption></figure><p>After that, another window opens up as image 15 by creating a module name. There click on create button.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/597/1*jCEb-6Ea6XSrGrXreLFEAQ.png" /><figcaption>Image 15</figcaption></figure><p>Now we have successfully created our java project.</p><p>Inside our project, there is a source folder. All the codes we are creating are exited inside the source folder. Then we need to create a java package. For that, we have to right-click on the source folder, then click on the new, package as image 16.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/562/1*wmu9p47W9knHBKDhsZ2XzQ.png" /><figcaption>Image 16</figcaption></figure><p>Then another window opens up as image 17 and asks for the name of the package. I keep the package name as test_project. Then click on the finish button. Then it creates the package named test_project.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/566/1*t9j7QpFdJX9fPgE4VVto7g.png" /><figcaption>Image 17</figcaption></figure><p>Next, we want to create a class. For that right click on test_project package then click on new, class as image 18.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/535/1*f2YtWrN_UioSPLeOGhilVA.png" /><figcaption>Image 18</figcaption></figure><p>Then the window opens up as image 19 asks the name of our class. Here I give the class name as TestProject.Then tick on the box in front of the public static void main (String[] args). Then click on finish and it creates the java class as TestProject.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/502/1*zn6W1dJwWi8KZeIJMn8DvQ.png" /><figcaption>Image 19</figcaption></figure><pre>package test_project;</pre><pre>public class TestProject {<br>    public static void main(String[] args) {<br>    }<br>}</pre><p>Everything we see around us is an object. Class is a blueprint of an object. Everything inside java needs to be inside a class. In this example class name is TestProject. Generally, the name of the class starts with a capital letter.</p><p>Public is an access modifier. A public class can be accessed by everyone which present in the program.</p><p>Inside the class TestProject, we have the main function. Void is the return type of function main. Every function has a return type associated with it. The public keyword implies that this is a public function and the static keyword imply that this is a static function. Static function can be accessed without an object. If we did not add static before a function we need an object to invoke that function.</p><p>Let&#39;s write our first java program. Inside the main method, we include <em>System.out.println(“Hello World”); .</em></p><pre>package test_project;<br>public class TestProject {<br>  public static void main(String[] args) {<br>      System.out.println(&quot;Hello World&quot;);<br>   }<br>}</pre><p>When we run this simple program it prints Hello World.</p><p>Hope you enjoy my article. If there are any concerns please comment on your idea.</p><p>Thank you.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=878469ce0366" width="1" height="1" alt=""><hr><p><a href="https://medium.com/linkit-intecs/learn-java-from-the-beginning-878469ce0366">Learn Java from the Beginning</a> was originally published in <a href="https://medium.com/linkit-intecs">LinkIT</a> on Medium, where people are continuing the conversation by highlighting and responding to this story.</p>]]></content:encoded>
        </item>
    </channel>
</rss>