<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:dc="http://purl.org/dc/elements/1.1/">
  <channel>
    <title>DEV Community: Ali Hamza</title>
    <description>The latest articles on DEV Community by Ali Hamza (@ali_hamza_589ec7b3eb6688d).</description>
    <link>https://dev.to/ali_hamza_589ec7b3eb6688d</link>
    <image>
      <url>https://media2.dev.to/dynamic/image/width=90,height=90,fit=cover,gravity=auto,format=auto/https:%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Fuser%2Fprofile_image%2F3939488%2Fffc69754-c900-4599-b972-2a8d900525dd.png</url>
      <title>DEV Community: Ali Hamza</title>
      <link>https://dev.to/ali_hamza_589ec7b3eb6688d</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://dev.to/feed/ali_hamza_589ec7b3eb6688d"/>
    <language>en</language>
    <item>
      <title>apnacollege</title>
      <dc:creator>Ali Hamza</dc:creator>
      <pubDate>Mon, 08 Jun 2026 11:32:28 +0000</pubDate>
      <link>https://dev.to/ali_hamza_589ec7b3eb6688d/apnacollege-57p</link>
      <guid>https://dev.to/ali_hamza_589ec7b3eb6688d/apnacollege-57p</guid>
      <description>&lt;p&gt;Hello Dev Community! 👋&lt;/p&gt;

&lt;p&gt;It is officially &lt;strong&gt;Day 17&lt;/strong&gt; of my journey to master the MERN stack! Today, I wrapped up the final part of &lt;strong&gt;Lecture 5 of Apna College's JavaScript course&lt;/strong&gt; with Shradha Didi. We focused entirely on the holy trinity of functional array operations: &lt;strong&gt;&lt;code&gt;.map()&lt;/code&gt;&lt;/strong&gt;, &lt;strong&gt;&lt;code&gt;.filter()&lt;/code&gt;&lt;/strong&gt;, and &lt;strong&gt;&lt;code&gt;.reduce()&lt;/code&gt;&lt;/strong&gt;.&lt;/p&gt;

&lt;p&gt;Up until yesterday, if I wanted to copy or filter an array, I had to create empty arrays and write loop structures to push items manually. Today, I learned how to do it inline like a professional.&lt;/p&gt;




&lt;h2&gt;
  
  
  🧠 Key Learnings From JS Lecture 5 (Part 3)
&lt;/h2&gt;

&lt;p&gt;The biggest concept today was that &lt;code&gt;.map()&lt;/code&gt; and &lt;code&gt;.filter()&lt;/code&gt; do not change the original dataset; they return a brand-new array. This is a crucial rule for state management in modern development.&lt;/p&gt;

&lt;h3&gt;
  
  
  1. The &lt;code&gt;.map()&lt;/code&gt; Method
&lt;/h3&gt;

&lt;p&gt;Similar to &lt;code&gt;.forEach()&lt;/code&gt;, it loops through every item. However, &lt;code&gt;.map()&lt;/code&gt; &lt;strong&gt;returns a new array&lt;/strong&gt; containing the results of whatever operation you perform on each element. It's the standard way to generate UI elements from a data list.&lt;/p&gt;

&lt;h3&gt;
  
  
  2. The &lt;code&gt;.filter()&lt;/code&gt; Method
&lt;/h3&gt;

&lt;p&gt;This method loops through an array and filters out elements based on a condition. If the condition evaluates to &lt;code&gt;true&lt;/code&gt;, the item is added to the &lt;strong&gt;new filtered array&lt;/strong&gt;; if &lt;code&gt;false&lt;/code&gt;, it gets dropped.&lt;/p&gt;

&lt;h3&gt;
  
  
  3. The &lt;code&gt;.reduce()&lt;/code&gt; Method
&lt;/h3&gt;

&lt;p&gt;This is used when you want to take an entire array of multiple inputs and reduce it down to a &lt;strong&gt;single output value&lt;/strong&gt; (like a total sum or a maximum number). It utilizes an &lt;code&gt;accumulator&lt;/code&gt; (which stores the running total) and a &lt;code&gt;current&lt;/code&gt; value.&lt;/p&gt;




&lt;h2&gt;
  
  
  🛠️ What I Actually Code / Practiced
&lt;/h2&gt;

&lt;p&gt;I spent my practice session solving the algorithmic challenges from Shradha Didi’s lecture:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;The 90+ Marks Filter:&lt;/strong&gt; Created an array of student marks and used &lt;code&gt;.filter()&lt;/code&gt; to instantly generate a clean list containing only scores above 90.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;The Factorial / Sum Generator:&lt;/strong&gt; Took an array of sequential numbers from 1 to &lt;code&gt;n&lt;/code&gt; and used &lt;code&gt;.reduce()&lt;/code&gt; to compute both the total sum and the factorial product of the entire sequence.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Seeing multiple array values condense down into a single precise output or filter dynamically with just two lines of arrow-function logic felt absolutely powerful!&lt;/p&gt;




&lt;h2&gt;
  
  
  🎯 My Goal for Tomorrow (Day 18 / Lecture 6)
&lt;/h2&gt;

&lt;p&gt;Tomorrow, I am moving to &lt;strong&gt;Lecture 6&lt;/strong&gt; of the Apna College sequence:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Entering the bridge between JavaScript logic and visual design: the &lt;strong&gt;DOM (Document Object Model)&lt;/strong&gt;.&lt;/li&gt;
&lt;li&gt;Learning how to select and dynamically target HTML elements directly using scripts.&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  💬 Let's Connect!
&lt;/h2&gt;

&lt;p&gt;To the Apna College community: Which method did you find trickier to grasp initially, &lt;code&gt;.filter()&lt;/code&gt; or &lt;code&gt;.reduce()&lt;/code&gt;? To the senior devs: How often do you chain these three methods together in your data processing pipelines?&lt;/p&gt;

&lt;p&gt;My functional array practice scripts are committed and pushed to GitHub!&lt;br&gt;
[Links in the Comments]&lt;/p&gt;

&lt;p&gt;Keep learning, keep building! 🚀&lt;/p&gt;

</description>
      <category>beginners</category>
      <category>codenewbie</category>
      <category>javascript</category>
      <category>webdev</category>
    </item>
    <item>
      <title>#javascript #apnacollege #webdev #beginners</title>
      <dc:creator>Ali Hamza</dc:creator>
      <pubDate>Sat, 06 Jun 2026 10:22:47 +0000</pubDate>
      <link>https://dev.to/ali_hamza_589ec7b3eb6688d/javascript-apnacollege-webdev-beginners-3hjg</link>
      <guid>https://dev.to/ali_hamza_589ec7b3eb6688d/javascript-apnacollege-webdev-beginners-3hjg</guid>
      <description>&lt;p&gt;Hello Dev Community! 👋&lt;/p&gt;

&lt;p&gt;It is officially &lt;strong&gt;Day 15&lt;/strong&gt; of my journey toward mastering the MERN stack! Today, I stepped into one of the most critical fundamentals of all programming paradigms by starting &lt;strong&gt;Lecture 5 of Apna College's JavaScript playlist&lt;/strong&gt; with Shradha Didi: &lt;strong&gt;Functions&lt;/strong&gt;.&lt;/p&gt;

&lt;p&gt;Up until now, if I wanted to run a block of logic in different parts of my file, I had to rewrite or copy-paste it. Today, I learned how to package code into a clean, reusable machine.&lt;/p&gt;




&lt;h2&gt;
  
  
  🧠 Key Learnings From JS Lecture 5 (Functions)
&lt;/h2&gt;

&lt;p&gt;I explored how JavaScript blocks together logic and how data flows inside and outside of a function:&lt;/p&gt;

&lt;h3&gt;
  
  
  1. Function Definition &amp;amp; Execution
&lt;/h3&gt;

&lt;p&gt;A function is simply a block of code that performs a specific task and executes only when it is explicitly "called" or "invoked". &lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Definition Syntax:&lt;/strong&gt; &lt;code&gt;function myFunction() { // code }&lt;/code&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Invocation Syntax:&lt;/strong&gt; &lt;code&gt;myFunction();&lt;/code&gt;
&lt;/li&gt;
&lt;/ul&gt;

&lt;h3&gt;
  
  
  2. Parameters vs. Arguments
&lt;/h3&gt;

&lt;p&gt;I learned how to pass dynamic data into my functions to make them flexible:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Parameters:&lt;/strong&gt; The placeholder variables we define in the function declaration (e.g., &lt;code&gt;function add(a, b)&lt;/code&gt;).&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Arguments:&lt;/strong&gt; The actual real values we pass into the function when calling it (e.g., &lt;code&gt;add(5, 10)&lt;/code&gt;).&lt;/li&gt;
&lt;/ul&gt;

&lt;h3&gt;
  
  
  3. The &lt;code&gt;return&lt;/code&gt; Keyword
&lt;/h3&gt;

&lt;p&gt;A major takeaway today was understanding that a function can send a value back to the place where it was called using &lt;code&gt;return&lt;/code&gt;. Crucially, I learned that once a &lt;code&gt;return&lt;/code&gt; statement executes, the function stops immediately, and any code written after it becomes unreachable.&lt;/p&gt;




&lt;h2&gt;
  
  
  🛠️ What I Actually Code / Practiced
&lt;/h2&gt;

&lt;p&gt;I spent my practice session solving the algorithmic functional challenges from the lecture:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;The Sum &amp;amp; Product Functions:&lt;/strong&gt; Built basic math functions that take parameters and safely return values.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;The Vowels Counter Challenge:&lt;/strong&gt; This was the main highlight! I wrote a function that takes a string as an argument and uses a loop to count and return the exact number of vowels (&lt;code&gt;a&lt;/code&gt;, &lt;code&gt;e&lt;/code&gt;, &lt;code&gt;i&lt;/code&gt;, &lt;code&gt;o&lt;/code&gt;, &lt;code&gt;u&lt;/code&gt;) present inside that text block.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Seeing a function take a raw text input, scan it, and return a clean numerical count felt like a huge leap in my programming logic!&lt;/p&gt;




&lt;h2&gt;
  
  
  🎯 My Goal for Tomorrow (Day 16 / Lecture 5 Part 2)
&lt;/h2&gt;

&lt;p&gt;Tomorrow, I will be jumping into modern JavaScript syntax within &lt;strong&gt;Lecture 5&lt;/strong&gt;:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Mastering &lt;strong&gt;Arrow Functions&lt;/strong&gt; (&lt;code&gt;const myFunc = () =&amp;gt; {}&lt;/code&gt;) which are heavily used in modern frameworks like React.&lt;/li&gt;
&lt;li&gt;Learning about &lt;strong&gt;Array Callback Methods&lt;/strong&gt; like &lt;code&gt;.forEach()&lt;/code&gt;.&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  💬 Let's Connect!
&lt;/h2&gt;

&lt;p&gt;To the Apna College community: How did you optimize your Vowels Counter function today? To seniors: Do you still use traditional &lt;code&gt;function&lt;/code&gt; declarations in your codebases, or have you shifted 100% to Arrow Functions?&lt;/p&gt;

&lt;p&gt;My Lecture 5 function scripts are pushed to GitHub!&lt;br&gt;
[Links in the Comments]&lt;/p&gt;

&lt;p&gt;Keep learning, keep building! 🚀&lt;/p&gt;

</description>
      <category>beginners</category>
      <category>devjournal</category>
      <category>javascript</category>
      <category>webdev</category>
    </item>
    <item>
      <title>#javascript #apnacollege #webdev #beginners</title>
      <dc:creator>Ali Hamza</dc:creator>
      <pubDate>Fri, 05 Jun 2026 10:41:14 +0000</pubDate>
      <link>https://dev.to/ali_hamza_589ec7b3eb6688d/javascript-apnacollege-webdev-beginners-9cl</link>
      <guid>https://dev.to/ali_hamza_589ec7b3eb6688d/javascript-apnacollege-webdev-beginners-9cl</guid>
      <description>&lt;p&gt;Hello Dev Community! 👋&lt;/p&gt;

&lt;p&gt;Today marks &lt;strong&gt;Day 14&lt;/strong&gt; — exactly two full weeks of documenting my journey toward mastering the MERN stack! Today, I wrapped up the second half of &lt;strong&gt;Lecture 4 of Apna College's JavaScript playlist&lt;/strong&gt; with Shradha Didi, focusing on &lt;strong&gt;Array Methods&lt;/strong&gt;.&lt;/p&gt;

&lt;p&gt;Yesterday was about understanding array structures; today was about actively manipulating them using built-in functions.&lt;/p&gt;




&lt;h2&gt;
  
  
  🧠 Key Learnings From JS Lecture 4 (Array Methods)
&lt;/h2&gt;

&lt;p&gt;I experimented with several crucial array methods that allow us to add, remove, and alter items on the fly. Shradha Didi divided them into two main categories:&lt;/p&gt;

&lt;h3&gt;
  
  
  1. Basic Add / Remove Methods
&lt;/h3&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;code&gt;.push()&lt;/code&gt;: Adds one or more elements to the &lt;strong&gt;end&lt;/strong&gt; of an array (changes the original array).&lt;/li&gt;
&lt;li&gt;
&lt;code&gt;.pop()&lt;/code&gt;: Removes the last element from the &lt;strong&gt;end&lt;/strong&gt; of an array and returns it.&lt;/li&gt;
&lt;li&gt;
&lt;code&gt;.unshift()&lt;/code&gt;: Adds an element to the &lt;strong&gt;start&lt;/strong&gt; of an array (shifts all indexes forward).&lt;/li&gt;
&lt;li&gt;
&lt;code&gt;.shift()&lt;/code&gt;: Removes the first element from the &lt;strong&gt;start&lt;/strong&gt; of an array.&lt;/li&gt;
&lt;/ul&gt;

&lt;h3&gt;
  
  
  2. Advanced Manipulation Methods
&lt;/h3&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;code&gt;.toString()&lt;/code&gt;: Converts an array into a single comma-separated string.&lt;/li&gt;
&lt;li&gt;
&lt;code&gt;.concat()&lt;/code&gt;: Merges multiple arrays together into a brand-new array without changing the original ones.&lt;/li&gt;
&lt;li&gt;
&lt;code&gt;.slice(start, end)&lt;/code&gt;: Extracts a regular chunk of an array without changing the original structure.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;The Powerhouse—&lt;code&gt;.splice(start, delCount, newElements)&lt;/code&gt;:&lt;/strong&gt; This method is incredible. It can delete, add, or replace elements at &lt;em&gt;any&lt;/em&gt; specific index inside the original array. &lt;/li&gt;
&lt;/ul&gt;




&lt;h2&gt;
  
  
  🛠️ What I Actually Code / Practiced
&lt;/h2&gt;

&lt;p&gt;I spent my practice session solving the real-world array manipulation assignment from the lecture:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;The Companies Array Challenge:&lt;/strong&gt; Created an array storing a list of tech corporations: &lt;code&gt;["Bloomberg", "Microsoft", "Uber", "Google", "IBM", "Netflix"]&lt;/code&gt;.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Task 1:&lt;/strong&gt; Used &lt;code&gt;.shift()&lt;/code&gt; to remove the first company from the array.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Task 2:&lt;/strong&gt; Used &lt;code&gt;.splice()&lt;/code&gt; to remove "Uber" and add "Ola" in its exact location.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Task 3:&lt;/strong&gt; Used &lt;code&gt;.push()&lt;/code&gt; to add "Amazon" to the end of the array dynamically.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Successfully executing multiple operations on a single dataset and tracking how the indexes changed felt like writing true administrative frontend logic!&lt;/p&gt;




&lt;h2&gt;
  
  
  🎯 My Goal for Tomorrow (Day 15 / Lecture 5)
&lt;/h2&gt;

&lt;p&gt;Tomorrow, I will be moving to &lt;strong&gt;Lecture 5&lt;/strong&gt; of the Apna College sequence:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Stepping into &lt;strong&gt;Functions and Methods&lt;/strong&gt; in JavaScript.&lt;/li&gt;
&lt;li&gt;Learning how to block reusable code together and understanding parameters, arguments, and return types.&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  💬 Let's Connect!
&lt;/h2&gt;

&lt;p&gt;To the Apna College alumni: How clean did you write your solution for the Companies challenge? To seniors: Do you use &lt;code&gt;.splice()&lt;/code&gt; often in production, or do you prefer non-mutating modern methods?&lt;/p&gt;

&lt;p&gt;My completed array manipulation scripts are pushed to GitHub!&lt;br&gt;
[Links in the Comments]&lt;/p&gt;

&lt;p&gt;Two weeks down, a lifetime of engineering to build. Keep moving forward! 🚀&lt;/p&gt;

</description>
      <category>beginners</category>
      <category>devjournal</category>
      <category>javascript</category>
      <category>webdev</category>
    </item>
    <item>
      <title>#javascript #apnacollege #webdev #beginners</title>
      <dc:creator>Ali Hamza</dc:creator>
      <pubDate>Thu, 04 Jun 2026 16:27:09 +0000</pubDate>
      <link>https://dev.to/ali_hamza_589ec7b3eb6688d/javascript-apnacollege-webdev-beginners-56pf</link>
      <guid>https://dev.to/ali_hamza_589ec7b3eb6688d/javascript-apnacollege-webdev-beginners-56pf</guid>
      <description>&lt;p&gt;Hello Dev Community! 👋&lt;/p&gt;

&lt;p&gt;It is officially &lt;strong&gt;Day 13&lt;/strong&gt; of my journey toward mastering the MERN stack! Today, I moved on to &lt;strong&gt;Lecture 4 of Apna College's JavaScript playlist&lt;/strong&gt; with Shradha Didi, leaving primitive single variables behind and entering the world of &lt;strong&gt;Arrays&lt;/strong&gt;.&lt;/p&gt;

&lt;p&gt;Up until yesterday, if I had to store 5 student names, I had to create 5 different variables. Today, I learned how to store them inside a single collection.&lt;/p&gt;




&lt;h2&gt;
  
  
  🧠 Key Learnings From JS Lecture 4 (Arrays)
&lt;/h2&gt;

&lt;p&gt;I explored the structure of Arrays in JavaScript and how they allow us to manage linear lists of items efficiently:&lt;/p&gt;

&lt;h3&gt;
  
  
  1. What is an Array?
&lt;/h3&gt;

&lt;p&gt;An array is a linear collection of elements. Unlike some other languages, JavaScript arrays can store different data types together (though storing the same type is best practice). &lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Arrays are &lt;strong&gt;Zero-Indexed&lt;/strong&gt; (the first item is at position &lt;code&gt;0&lt;/code&gt;).&lt;/li&gt;
&lt;li&gt;They have a built-in &lt;code&gt;.length&lt;/code&gt; property that tells us exactly how many items are inside.&lt;/li&gt;
&lt;/ul&gt;

&lt;h3&gt;
  
  
  2. Array Mutability vs String Immutability
&lt;/h3&gt;

&lt;p&gt;A huge conceptual breakthrough today was learning that &lt;strong&gt;Arrays are mutable&lt;/strong&gt; in JavaScript. Unlike strings (where methods return a new value), we can directly change an item in an array using its index:&lt;/p&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;
javascript
let marks = [95, 82, 99];
marks[1] = 85; // Changes 82 to 85 directly in the original array!
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;

</description>
      <category>beginners</category>
      <category>devjournal</category>
      <category>javascript</category>
      <category>webdev</category>
    </item>
    <item>
      <title>#javascript #apnacollege #webdev #beginners</title>
      <dc:creator>Ali Hamza</dc:creator>
      <pubDate>Wed, 03 Jun 2026 06:33:36 +0000</pubDate>
      <link>https://dev.to/ali_hamza_589ec7b3eb6688d/javascript-apnacollege-webdev-beginners-366f</link>
      <guid>https://dev.to/ali_hamza_589ec7b3eb6688d/javascript-apnacollege-webdev-beginners-366f</guid>
      <description>&lt;p&gt;Hello Dev Community! 👋&lt;/p&gt;

&lt;p&gt;It is officially &lt;strong&gt;Day 12&lt;/strong&gt; of my journey to master the MERN stack! Today, I wrapped up &lt;strong&gt;Lecture 3 of Apna College's JavaScript playlist&lt;/strong&gt; with Shradha Didi, focusing on a fundamental data type we use every day: &lt;strong&gt;Strings&lt;/strong&gt;.&lt;/p&gt;

&lt;p&gt;Before today, I thought strings were just plain text wrapped in quotes. Today, I learned how much power JavaScript gives us to manipulate, slice, and dynamically format text.&lt;/p&gt;




&lt;h2&gt;
  
  
  🧠 Key Learnings From JS Lecture 3 (Strings)
&lt;/h2&gt;

&lt;p&gt;I explored how JavaScript handles text strings and the built-in properties and methods that make text manipulation effortless:&lt;/p&gt;

&lt;h3&gt;
  
  
  1. Template Literals (The Ultimate Game Changer)
&lt;/h3&gt;

&lt;p&gt;Shradha Didi introduced &lt;strong&gt;Template Literals&lt;/strong&gt;, which use backticks (&lt;code&gt;`&lt;/code&gt;) instead of standard quotes. This allows us to perform &lt;strong&gt;String Interpolation&lt;/strong&gt;—embedding variables directly inside a string using &lt;code&gt;${variable}&lt;/code&gt;. It makes code look clean and professional:&lt;/p&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;
javascript
let obj = { item: "pen", price: 10 };
// Old way: console.log("The cost of", obj.item, "is", obj.price, "rupees.");
// Modern way:
console.log(`The cost of ${obj.item} is ${obj.price} rupees.`);
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;

</description>
      <category>beginners</category>
      <category>devjournal</category>
      <category>javascript</category>
      <category>webdev</category>
    </item>
    <item>
      <title>#javascript #apnacollege #webdev #beginners</title>
      <dc:creator>Ali Hamza</dc:creator>
      <pubDate>Tue, 02 Jun 2026 10:50:15 +0000</pubDate>
      <link>https://dev.to/ali_hamza_589ec7b3eb6688d/javascript-apnacollege-webdev-beginners-5bdj</link>
      <guid>https://dev.to/ali_hamza_589ec7b3eb6688d/javascript-apnacollege-webdev-beginners-5bdj</guid>
      <description>&lt;p&gt;Hello Dev Community! 👋&lt;/p&gt;

&lt;p&gt;It is officially &lt;strong&gt;Day 11&lt;/strong&gt; of my journey to master the MERN stack! Today, I dived into &lt;strong&gt;Lecture 3 of Apna College's JavaScript playlist&lt;/strong&gt; with Shradha Didi, focusing on one of the most powerful concepts in programming: &lt;strong&gt;Loops&lt;/strong&gt;.&lt;/p&gt;

&lt;p&gt;Before today, if I wanted to run a line of code 10 times, I had to copy-paste it. Today, I learned how to automate repetition efficiently.&lt;/p&gt;




&lt;h2&gt;
  
  
  🧠 Key Learnings From JS Lecture 3 (Loops)
&lt;/h2&gt;

&lt;p&gt;I explored how JavaScript handles repetitive tasks using different types of loops, depending on the scenario:&lt;/p&gt;

&lt;h3&gt;
  
  
  1. The Classic Loops
&lt;/h3&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;&lt;code&gt;for&lt;/code&gt; Loop:&lt;/strong&gt; The absolute standard when you know exactly how many times the code needs to run. (e.g., executing a block exactly 5 times).&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;&lt;code&gt;while&lt;/code&gt; Loop:&lt;/strong&gt; Perfect when you want the code to keep running as long as a specific condition remains true.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;&lt;code&gt;do-while&lt;/code&gt; Loop:&lt;/strong&gt; A unique loop that is guaranteed to run &lt;em&gt;at least once&lt;/em&gt;, even if the condition is false from the start, because the condition is checked at the very end.&lt;/li&gt;
&lt;/ul&gt;

&lt;h3&gt;
  
  
  2. Modern JavaScript Loops (The Game Changers)
&lt;/h3&gt;

&lt;p&gt;Shradha Didi also introduced two modern and highly useful loops that senior devs use all the time:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;&lt;code&gt;for-of&lt;/code&gt; Loop:&lt;/strong&gt; Used exclusively for iterating over characters in a string or items in an array. It makes the syntax incredibly clean.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;&lt;code&gt;for-in&lt;/code&gt; Loop:&lt;/strong&gt; Perfect for stepping through the properties of a JavaScript object.&lt;/li&gt;
&lt;/ul&gt;




&lt;h2&gt;
  
  
  🛠️ What I Actually Code / Practiced
&lt;/h2&gt;

&lt;p&gt;I spent my practice session solving the practice problems from the lecture to lock in the logic:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;The Even Number Challenge:&lt;/strong&gt; Wrote a &lt;code&gt;for&lt;/code&gt; loop that prints all even numbers from 1 to 100.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;The Guessing Game:&lt;/strong&gt; Created a simple mini-game using a &lt;code&gt;while&lt;/code&gt; loop that keeps prompting the user to guess a correct "game number" until they enter the right answer.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Seeing the loop dynamically handle user input without breaking the browser console felt like a massive milestone!&lt;/p&gt;




&lt;h2&gt;
  
  
  🎯 My Goal for Tomorrow (Day 12 / Lecture 3 Part 2)
&lt;/h2&gt;

&lt;p&gt;Tomorrow, I will be wrapping up the rest of &lt;strong&gt;Lecture 3&lt;/strong&gt; from Apna College:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Diving deep into &lt;strong&gt;Strings&lt;/strong&gt; and their built-in methods (like &lt;code&gt;.toUpperCase()&lt;/code&gt;, &lt;code&gt;.trim()&lt;/code&gt;, and &lt;code&gt;.slice()&lt;/code&gt;).&lt;/li&gt;
&lt;li&gt;Learning how to manipulate text data dynamically.&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  💬 Let's Connect!
&lt;/h2&gt;

&lt;p&gt;To the Apna College alumni: How long did it take you to crack the guessing game logic? To seniors: Do you find yourself using &lt;code&gt;for-of&lt;/code&gt; loops more often than traditional &lt;code&gt;for&lt;/code&gt; loops in production?&lt;/p&gt;

&lt;p&gt;My Lecture 3 loop scripts are pushed to GitHub!&lt;br&gt;
[Links in the Comments]&lt;/p&gt;

&lt;p&gt;Keep learning, keep building! 🚀&lt;/p&gt;

</description>
      <category>beginners</category>
      <category>javascript</category>
      <category>learning</category>
      <category>webdev</category>
    </item>
    <item>
      <title>#javascript #apnacollege #webdev #beginners</title>
      <dc:creator>Ali Hamza</dc:creator>
      <pubDate>Mon, 01 Jun 2026 10:00:05 +0000</pubDate>
      <link>https://dev.to/ali_hamza_589ec7b3eb6688d/javascript-apnacollege-webdev-beginners-d4</link>
      <guid>https://dev.to/ali_hamza_589ec7b3eb6688d/javascript-apnacollege-webdev-beginners-d4</guid>
      <description>&lt;p&gt;Hello Dev Community! 👋&lt;/p&gt;

&lt;p&gt;It is &lt;strong&gt;Day 9&lt;/strong&gt; of my journey toward the MERN stack! Today, I followed &lt;strong&gt;Lecture 2 of Apna College's JavaScript course&lt;/strong&gt;, which transitions from storing data to actually manipulating it and making decisions.&lt;/p&gt;

&lt;p&gt;Yesterday was about variables; today was about giving the code a "brain" to choose different paths based on conditions.&lt;/p&gt;




&lt;h2&gt;
  
  
  🧠 Key Learnings From JS Lecture 2
&lt;/h2&gt;

&lt;p&gt;Here is the exact breakdown of the concepts I cracked today:&lt;/p&gt;

&lt;h3&gt;
  
  
  1. JavaScript Operators
&lt;/h3&gt;

&lt;p&gt;Before making decisions, code needs to compare values. I learned about:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Arithmetic Operators:&lt;/strong&gt; &lt;code&gt;+&lt;/code&gt;, &lt;code&gt;-&lt;/code&gt;, &lt;code&gt;*&lt;/code&gt;, &lt;code&gt;/&lt;/code&gt;, and &lt;code&gt;%&lt;/code&gt; (Modulus—great for finding odd/even numbers).&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Assignment Operators:&lt;/strong&gt; &lt;code&gt;=&lt;/code&gt;, &lt;code&gt;+=&lt;/code&gt;, &lt;code&gt;-=&lt;/code&gt; to update variable values quickly.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Comparison Operators:&lt;/strong&gt; &lt;code&gt;==&lt;/code&gt; (checks value) vs &lt;code&gt;===&lt;/code&gt; (Strict Equality: checks both value AND data type—a true senior dev practice!).&lt;/li&gt;
&lt;/ul&gt;

&lt;h3&gt;
  
  
  2. Conditional Statements (The Decision Makers)
&lt;/h3&gt;

&lt;p&gt;I learned how to control the flow of my program using &lt;code&gt;if&lt;/code&gt;, &lt;code&gt;else if&lt;/code&gt;, and &lt;code&gt;else&lt;/code&gt; blocks. The syntax is straightforward:&lt;/p&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;
javascript
let mode = "dark";
let color;

if (mode === "dark") {
    color = "black";
} else {
    color = "white";
}
console.log(color);
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;

</description>
      <category>beginners</category>
      <category>devjournal</category>
      <category>javascript</category>
      <category>webdev</category>
    </item>
    <item>
      <title>#javascript #webdev #beginners #codenewbie</title>
      <dc:creator>Ali Hamza</dc:creator>
      <pubDate>Mon, 01 Jun 2026 09:53:49 +0000</pubDate>
      <link>https://dev.to/ali_hamza_589ec7b3eb6688d/javascript-webdev-beginners-codenewbie-5ed5</link>
      <guid>https://dev.to/ali_hamza_589ec7b3eb6688d/javascript-webdev-beginners-codenewbie-5ed5</guid>
      <description>&lt;p&gt;Hello Dev Community! 👋&lt;/p&gt;

&lt;p&gt;It is officially &lt;strong&gt;Day 8&lt;/strong&gt; of my journey to master the MERN stack! After spending the first week structuring with HTML and styling with CSS, today I finally started learning the core language of web logic: &lt;strong&gt;JavaScript&lt;/strong&gt;.&lt;/p&gt;

&lt;p&gt;Moving from static designs to actual programming logic feels like unlocking a whole new level of web development.&lt;/p&gt;




&lt;h2&gt;
  
  
  🧠 Key Learnings From Day 8
&lt;/h2&gt;

&lt;p&gt;Today was all about setting up the foundation in JavaScript and understanding how code runs in the browser. Here is what I covered:&lt;/p&gt;

&lt;h3&gt;
  
  
  1. The Browser Console &amp;amp; Execution
&lt;/h3&gt;

&lt;p&gt;I learned that every browser has a built-in environment to run JavaScript. Writing my very first &lt;code&gt;console.log("Hello World");&lt;/code&gt; and seeing it print in the developer tools console was the perfect start.&lt;/p&gt;

&lt;h3&gt;
  
  
  2. Variables: Storing Data Safely
&lt;/h3&gt;

&lt;p&gt;I learned how to store information using variables and the crucial differences between modern variable declarations:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;code&gt;let&lt;/code&gt;: For values that can change later in the program (mutable).&lt;/li&gt;
&lt;li&gt;
&lt;code&gt;const&lt;/code&gt;: For values that must remain constant and cannot be reassigned (immutable).&lt;/li&gt;
&lt;li&gt;
&lt;em&gt;Note:&lt;/em&gt; I also read about &lt;code&gt;var&lt;/code&gt;, but learned why modern JavaScript avoids it due to scoping issues.&lt;/li&gt;
&lt;/ul&gt;

&lt;h3&gt;
  
  
  3. Data Types Fundamentals
&lt;/h3&gt;

&lt;p&gt;Data needs a type so the computer knows how to handle it. Today I practiced with:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Strings:&lt;/strong&gt; Plain text enclosed in quotes (e.g., &lt;code&gt;"MERN Stack"&lt;/code&gt;).&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Numbers:&lt;/strong&gt; Integers and decimals without quotes (e.g., &lt;code&gt;2026&lt;/code&gt;).&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Booleans:&lt;/strong&gt; Simple true or false states (e.g., &lt;code&gt;isLearning = true&lt;/code&gt;).&lt;/li&gt;
&lt;/ul&gt;




&lt;h2&gt;
  
  
  🛠️ What I Actually Code / Experimented With
&lt;/h2&gt;

&lt;p&gt;Since I am just starting with core logic, I didn't write code directly into my HTML webpage layout today. Instead, I created a &lt;code&gt;script.js&lt;/code&gt; file, linked it to my project, and built a basic script in the console that:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Stores a user's name and learning status in variables.&lt;/li&gt;
&lt;li&gt;Dynamically calculates values (like years left until a milestone).&lt;/li&gt;
&lt;li&gt;Outputs formatted statements into the browser console.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;It is simple, but understanding how data moves in the background is incredibly exciting.&lt;/p&gt;




&lt;h2&gt;
  
  
  🎯 My Goal for Tomorrow (Day 9)
&lt;/h2&gt;

&lt;p&gt;Tomorrow, I will make my JavaScript code make decisions:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Learning &lt;strong&gt;Conditional Statements&lt;/strong&gt; (&lt;code&gt;if&lt;/code&gt;, &lt;code&gt;else if&lt;/code&gt;, &lt;code&gt;else&lt;/code&gt;).&lt;/li&gt;
&lt;li&gt;Understanding basic comparison operators to control the flow of execution.&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  💬 Let's Connect!
&lt;/h2&gt;

&lt;p&gt;To the senior engineers: What is the number one bad habit beginners fall into when learning JavaScript variables? To fellow learners: Did you start with &lt;code&gt;let&lt;/code&gt; and &lt;code&gt;const&lt;/code&gt; directly, or did you accidentally use &lt;code&gt;var&lt;/code&gt; first?&lt;/p&gt;

&lt;p&gt;My first JavaScript file has been committed and pushed to GitHub!&lt;br&gt;
[Links in the Comments]&lt;/p&gt;

&lt;p&gt;The real programming begins now. Keep building! 🚀&lt;/p&gt;

</description>
      <category>beginners</category>
      <category>codenewbie</category>
      <category>javascript</category>
      <category>webdev</category>
    </item>
    <item>
      <title>#css #responsive #beginners #codenewbie</title>
      <dc:creator>Ali Hamza</dc:creator>
      <pubDate>Tue, 26 May 2026 10:02:33 +0000</pubDate>
      <link>https://dev.to/ali_hamza_589ec7b3eb6688d/css-responsive-beginners-codenewbie-1bbj</link>
      <guid>https://dev.to/ali_hamza_589ec7b3eb6688d/css-responsive-beginners-codenewbie-1bbj</guid>
      <description>&lt;p&gt;Hello Dev Community! 👋&lt;/p&gt;

&lt;p&gt;Today marks &lt;strong&gt;Day 7&lt;/strong&gt; — a full week of documenting my journey toward mastering the MERN stack! After mastering Flexbox yesterday, today I tackled the most crucial aspect of modern frontend development: &lt;strong&gt;Responsive Web Design using Media Queries&lt;/strong&gt;.&lt;/p&gt;

&lt;p&gt;With more than half of web traffic coming from mobile devices, a layout that only looks good on a laptop is a broken layout. Today, I learned how to make my code adapt.&lt;/p&gt;




&lt;h2&gt;
  
  
  🧠 Key Learnings From Day 7
&lt;/h2&gt;

&lt;h3&gt;
  
  
  1. The Mobile-First Approach
&lt;/h3&gt;

&lt;p&gt;I learned that instead of styling for big desktop screens first and then trying to shrink everything for mobile, it is much cleaner to write CSS for mobile screens &lt;em&gt;first&lt;/em&gt;, and then use Media Queries to add styles as the screen gets wider.&lt;/p&gt;

&lt;h3&gt;
  
  
  2. Understanding Breakpoints
&lt;/h3&gt;

&lt;p&gt;Media queries allow us to apply CSS rules only when certain conditions are met, such as a maximum or minimum screen width (&lt;code&gt;min-width&lt;/code&gt; or &lt;code&gt;max-width&lt;/code&gt;).&lt;/p&gt;

&lt;p&gt;I experimented with standard breakpoints today:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Mobile screens (default CSS)&lt;/li&gt;
&lt;li&gt;Tablets (&lt;code&gt;min-width: 768px&lt;/code&gt;)&lt;/li&gt;
&lt;li&gt;Desktops (&lt;code&gt;min-width: 1024px&lt;/code&gt;)&lt;/li&gt;
&lt;/ul&gt;

&lt;h3&gt;
  
  
  3. Combining Flexbox with Media Queries
&lt;/h3&gt;

&lt;p&gt;The real magic happened when I combined yesterday's Flexbox knowledge with today's Media Queries. I learned how to change &lt;code&gt;flex-direction: column;&lt;/code&gt; on mobile to &lt;code&gt;flex-direction: row;&lt;/code&gt; on desktop screens smoothly.&lt;/p&gt;




&lt;h2&gt;
  
  
  🛠️ What I Actually Built / Refactored
&lt;/h2&gt;

&lt;p&gt;I took the form and navigation bar from the previous days and made them fully responsive:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;The Navbar:&lt;/strong&gt; On desktop, the navigation links sit horizontally next to the logo. Using a media query, I configured it so that on smaller screens, the links stack vertically and center neatly, making it touch-friendly for mobile users.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;The Form Layout:&lt;/strong&gt; Input fields that look great spanning across a desktop screen were wrapping tightly on mobile. I adjusted their widths using percentages (&lt;code&gt;width: 100%&lt;/code&gt;) inside mobile parameters so they scale flawlessly.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Opening my browser's inspect tool and dragging the screen size back and forth to see the layout adjust automatically was the perfect way to wrap up week one!&lt;/p&gt;




&lt;h2&gt;
  
  
  🎯 My Goal for Tomorrow (Day 8)
&lt;/h2&gt;

&lt;p&gt;I have built a solid foundation in HTML structures and CSS layout principles over the last week. Tomorrow, it's time to add true logic, interactivity, and brainpower to the frontend:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Starting &lt;strong&gt;JavaScript (JS)&lt;/strong&gt; fundamentals.&lt;/li&gt;
&lt;li&gt;Learning about variables, data types, and how code runs in the browser console.&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  💬 Let's Connect!
&lt;/h2&gt;

&lt;p&gt;To the seasoned developers: What are your go-to breakpoint values when starting a clean CSS project? To fellow beginners: Have you tested your webpages on your actual phone yet?&lt;/p&gt;

&lt;p&gt;My first fully responsive stylesheet is committed and pushed to GitHub!&lt;br&gt;
[Links in the Comments]&lt;/p&gt;

&lt;p&gt;One week down, many more to go. Keep pushing! 🚀&lt;/p&gt;

</description>
      <category>beginners</category>
      <category>codenewbie</category>
      <category>css</category>
      <category>frontend</category>
    </item>
    <item>
      <title>#css, #webdev, #beginners, #codenewbie</title>
      <dc:creator>Ali Hamza</dc:creator>
      <pubDate>Mon, 25 May 2026 12:07:21 +0000</pubDate>
      <link>https://dev.to/ali_hamza_589ec7b3eb6688d/css-webdev-beginners-codenewbie-14i8</link>
      <guid>https://dev.to/ali_hamza_589ec7b3eb6688d/css-webdev-beginners-codenewbie-14i8</guid>
      <description>&lt;p&gt;Hello Dev Community! 👋&lt;/p&gt;

&lt;p&gt;It is officially &lt;strong&gt;Day 6&lt;/strong&gt; of my web development journey! Yesterday, I learned how to create space using the Box Model. Today, I stepped into the absolute game-changer of frontend layouts: &lt;strong&gt;CSS Flexbox&lt;/strong&gt;.&lt;/p&gt;

&lt;p&gt;Before today, aligning elements horizontally or centering a button vertically felt like guesswork. Today, I learned how to control my layout vectors with just a few lines of code.&lt;/p&gt;




&lt;h2&gt;
  
  
  🧠 Key Learnings From Day 6
&lt;/h2&gt;

&lt;p&gt;Flexbox is all about a parent container (the Flex Container) controlling its children (Flex Items) along a main axis and a cross axis. &lt;/p&gt;

&lt;p&gt;Here are the structural properties I mastered today:&lt;/p&gt;

&lt;h3&gt;
  
  
  1. Activating the Layout
&lt;/h3&gt;

&lt;p&gt;By simply applying &lt;code&gt;display: flex;&lt;/code&gt; to a parent container, all its direct children instantly align horizontally (row layout) by default. No more messy floats!&lt;/p&gt;

&lt;h3&gt;
  
  
  2. Controlling Alignment
&lt;/h3&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;code&gt;justify-content&lt;/code&gt;: Controls spacing along the main axis. I experimented with &lt;code&gt;center&lt;/code&gt;, &lt;code&gt;space-between&lt;/code&gt; (perfect for navbars), and &lt;code&gt;space-around&lt;/code&gt;.&lt;/li&gt;
&lt;li&gt;
&lt;code&gt;align-items&lt;/code&gt;: Controls spacing along the cross axis. Setting this to &lt;code&gt;center&lt;/code&gt; makes vertical alignment effortless.&lt;/li&gt;
&lt;li&gt;
&lt;code&gt;flex-direction&lt;/code&gt;: Allows switching the axis from a row layout to a vertical stack (&lt;code&gt;column&lt;/code&gt;), which is crucial for mobile-responsive design.&lt;/li&gt;
&lt;/ul&gt;




&lt;h2&gt;
  
  
  🛠️ What I Actually Built / Refactored
&lt;/h2&gt;

&lt;p&gt;I took my navigation bar and the "About Me" form from the previous days and completely rebuilt their positioning using Flexbox:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;The Navbar:&lt;/strong&gt; Wrapped my logo and nav links in a header container, applied &lt;code&gt;display: flex;&lt;/code&gt; and &lt;code&gt;justify-content: space-between;&lt;/code&gt;. Now the logo sits on the far left and the links sit perfectly on the far right, completely responsive.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;The Centered Button:&lt;/strong&gt; I finally learned how to perfectly center my submission button inside the form box using &lt;code&gt;justify-content: center;&lt;/code&gt;.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;The code looks incredibly clean, and I don't have to use random margins or line breaks (&lt;code&gt;&amp;lt;br&amp;gt;&lt;/code&gt;) to push things around anymore!&lt;/p&gt;




&lt;h2&gt;
  
  
  🎯 My Goal for Tomorrow (Day 7)
&lt;/h2&gt;

&lt;p&gt;Now that I can create clean structural layouts, it is time to make them look professional on mobile screens:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Learning &lt;strong&gt;Media Queries&lt;/strong&gt; and Responsive Web Design.&lt;/li&gt;
&lt;li&gt;Understanding how to change layouts smoothly based on different screen sizes.&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  💬 Let's Connect!
&lt;/h2&gt;

&lt;p&gt;To the senior devs: What is the one Flexbox shorthand property you use the most? To beginners: Have you cracked the ultimate challenge yet—centering a &lt;code&gt;&amp;lt;div&amp;gt;&lt;/code&gt;? &lt;/p&gt;

&lt;p&gt;My Flexbox-powered responsive structures are pushed to GitHub!&lt;br&gt;
[Links in the Comments]&lt;/p&gt;

&lt;p&gt;Keep building! 🚀&lt;/p&gt;

</description>
      <category>beginners</category>
      <category>codenewbie</category>
      <category>css</category>
      <category>webdev</category>
    </item>
    <item>
      <title>#css #webdev #beginners #codenewbie</title>
      <dc:creator>Ali Hamza</dc:creator>
      <pubDate>Sun, 24 May 2026 05:58:58 +0000</pubDate>
      <link>https://dev.to/ali_hamza_589ec7b3eb6688d/css-webdev-beginners-codenewbie-3akn</link>
      <guid>https://dev.to/ali_hamza_589ec7b3eb6688d/css-webdev-beginners-codenewbie-3akn</guid>
      <description>&lt;p&gt;Hello Dev Community! 👋&lt;/p&gt;

&lt;p&gt;It is officially &lt;strong&gt;Day 5&lt;/strong&gt; of my journey toward the MERN stack! Yesterday, I learned how to add colors and fonts using CSS selectors. Today, I tackled the absolute core of CSS layout design: &lt;strong&gt;The Box Model&lt;/strong&gt;.&lt;/p&gt;

&lt;p&gt;Before today, whenever I tried to move an element, it would randomly overlap or break the layout. Today, I finally understood &lt;em&gt;why&lt;/em&gt; that happens.&lt;/p&gt;




&lt;h2&gt;
  
  
  🧠 Key Learnings From Day 5
&lt;/h2&gt;

&lt;p&gt;I learned that the browser treats every single HTML element as a rectangular box. This box consists of four distinct layers:&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;
&lt;strong&gt;Content:&lt;/strong&gt; The actual text, image, or video inside the element.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Padding:&lt;/strong&gt; The transparent space &lt;em&gt;inside&lt;/em&gt; the element, between the content and its border. (Great for making buttons look spacious!).&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Border:&lt;/strong&gt; The line wrapped around the padding and content (I experimented with &lt;code&gt;border-radius&lt;/code&gt; to make smooth, rounded corners).&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Margin:&lt;/strong&gt; The transparent space &lt;em&gt;outside&lt;/em&gt; the element, separating it from other surrounding boxes.&lt;/li&gt;
&lt;/ol&gt;

&lt;h3&gt;
  
  
  ⚡ The Life-Saving Property: &lt;code&gt;box-sizing: border-box;&lt;/code&gt;
&lt;/h3&gt;

&lt;p&gt;One major headache I faced was that adding padding or borders increased the actual width of my elements, ruining my layout math. &lt;/p&gt;

&lt;p&gt;Then I learned about a universal reset that senior developers use. Adding this to the top of my CSS file fixed everything instantly:&lt;/p&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;
css
* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;

</description>
      <category>beginners</category>
      <category>codenewbie</category>
      <category>css</category>
      <category>webdev</category>
    </item>
    <item>
      <title>#css #webdev #beginners #codenewbie</title>
      <dc:creator>Ali Hamza</dc:creator>
      <pubDate>Fri, 22 May 2026 12:24:53 +0000</pubDate>
      <link>https://dev.to/ali_hamza_589ec7b3eb6688d/css-webdev-beginners-codenewbie-5d9d</link>
      <guid>https://dev.to/ali_hamza_589ec7b3eb6688d/css-webdev-beginners-codenewbie-5d9d</guid>
      <description>&lt;p&gt;Hello Dev Community! 👋&lt;/p&gt;

&lt;p&gt;It is &lt;strong&gt;Day 4&lt;/strong&gt; of my journey toward mastering the MERN stack. For the past three days, I was busy building skeletons with HTML. Today, I finally started bringing those dry structures to life using &lt;strong&gt;CSS (Cascading Style Sheets)&lt;/strong&gt;!&lt;/p&gt;

&lt;p&gt;It felt amazing to move away from black text on a plain white screen and actually control how things look.&lt;/p&gt;




&lt;h2&gt;
  
  
  🧠 Key Learnings From Day 4
&lt;/h2&gt;

&lt;h3&gt;
  
  
  1. The Three Ways to Add CSS
&lt;/h3&gt;

&lt;p&gt;I learned that there are three methods to attach styles to HTML, but one is clearly the professional standard:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Inline CSS:&lt;/strong&gt; Writing styles directly inside the HTML tag (makes code messy).&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Internal CSS:&lt;/strong&gt; Writing styles inside the &lt;code&gt;&amp;lt;style&amp;gt;&lt;/code&gt; tag in the HTML head.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;External CSS (The Winner):&lt;/strong&gt; Creating a separate &lt;code&gt;.css&lt;/code&gt; file and linking it via &lt;code&gt;&amp;lt;link rel="stylesheet"&amp;gt;&lt;/code&gt;. I chose this method because it keeps my HTML clean and modular.&lt;/li&gt;
&lt;/ul&gt;

&lt;h3&gt;
  
  
  2. CSS Syntax &amp;amp; Basic Selectors
&lt;/h3&gt;

&lt;p&gt;I mastered the basic anatomy of a CSS rule: &lt;code&gt;Selector { Property: Value; }&lt;/code&gt;. I experimented with three primary selectors today:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Element Selector:&lt;/strong&gt; Targeting tags directly (e.g., &lt;code&gt;body&lt;/code&gt;, &lt;code&gt;h1&lt;/code&gt;).&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Class Selector (&lt;code&gt;.&lt;/code&gt;):&lt;/strong&gt; The most reusable way to style elements (e.g., &lt;code&gt;.btn-primary&lt;/code&gt;).&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;ID Selector (&lt;code&gt;#&lt;/code&gt;):&lt;/strong&gt; For styling a single, unique element (e.g., &lt;code&gt;#main-header&lt;/code&gt;).&lt;/li&gt;
&lt;/ul&gt;




&lt;h2&gt;
  
  
  🛠️ What I Actually Built / Styled
&lt;/h2&gt;

&lt;p&gt;I took the semantic "About Me" page and navigation bar that I refactored yesterday and created an external &lt;code&gt;style.css&lt;/code&gt; file for it. &lt;/p&gt;

&lt;p&gt;Today, I didn't worry about complex layouts. Instead, I focused on the basics:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Changed the background color of the body to a clean, modern off-white.&lt;/li&gt;
&lt;li&gt;Styled my headings with different font families and dark gray tones.&lt;/li&gt;
&lt;li&gt;Turned my navigation list items (&lt;code&gt;&amp;lt;li&amp;gt;&lt;/code&gt;) into an inline layout so they sit horizontally like a real navbar, instead of a vertical bulleted list.&lt;/li&gt;
&lt;/ul&gt;




&lt;h2&gt;
  
  
  🎯 My Goal for Tomorrow (Day 5)
&lt;/h2&gt;

&lt;p&gt;Tomorrow, I'm diving into the absolute core of CSS layouts:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Understanding the &lt;strong&gt;CSS Box Model&lt;/strong&gt; (Margin, Border, Padding, Content).&lt;/li&gt;
&lt;li&gt;Learning how space works between elements so my layout stops overlapping.&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  💬 Let's Connect!
&lt;/h2&gt;

&lt;p&gt;To the senior engineers: What is your favorite CSS font stack for clean, readable code? To fellow beginners: Did you start with Inline CSS or go straight to External files?&lt;/p&gt;

&lt;p&gt;My styled code and repository are up to date on GitHub!&lt;br&gt;
[Links in the Comments]&lt;/p&gt;

&lt;p&gt;Keep coding! 🚀&lt;/p&gt;

</description>
      <category>beginners</category>
      <category>codenewbie</category>
      <category>css</category>
      <category>webdev</category>
    </item>
  </channel>
</rss>
