<?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 PyShihab on Medium]]></title>
        <description><![CDATA[Stories by PyShihab on Medium]]></description>
        <link>https://medium.com/@shihabyahia22?source=rss-ce4c9b1b6f96------2</link>
        <image>
            <url>https://cdn-images-1.medium.com/fit/c/150/150/0*kGbaPPS7_2FSC07V</url>
            <title>Stories by PyShihab on Medium</title>
            <link>https://medium.com/@shihabyahia22?source=rss-ce4c9b1b6f96------2</link>
        </image>
        <generator>Medium</generator>
        <lastBuildDate>Tue, 01 Dec 2026 13:16:36 GMT</lastBuildDate>
        <atom:link href="https://medium.com/@shihabyahia22/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[About Calculator]]></title>
            <link>https://medium.com/@shihabyahia22/about-calculator-b04d89b30538?source=rss-ce4c9b1b6f96------2</link>
            <guid isPermaLink="false">https://medium.com/p/b04d89b30538</guid>
            <dc:creator><![CDATA[PyShihab]]></dc:creator>
            <pubDate>Wed, 11 Mar 2026 09:59:14 GMT</pubDate>
            <atom:updated>2026-03-11T09:59:14.399Z</atom:updated>
            <content:encoded><![CDATA[<p>Calculator is common for students daily life. they use it to solve complex calculation. however, a few days ago i was trying to solve a math problem but i can’t solve it because i didn’t carry my calculator in my beg. though we can calculate with our mind. but it doesn’t work all the time while we try to solve complex calculation. some example techer ask to you find the area of trapeziam and he gives a clue to you which is height between two arms it’s 16. and now you need to the find the are of trapeziam. you things it might easier but it would be complex calculation. it also easy for me. but harsh truth is complex calculation makes it harder.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=b04d89b30538" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[What is bias and average in Machine learning & Data analyst]]></title>
            <link>https://medium.com/@shihabyahia22/what-is-bias-and-average-in-machine-learning-data-analyst-4ce7dfda48e8?source=rss-ce4c9b1b6f96------2</link>
            <guid isPermaLink="false">https://medium.com/p/4ce7dfda48e8</guid>
            <dc:creator><![CDATA[PyShihab]]></dc:creator>
            <pubDate>Wed, 16 Jul 2025 06:53:26 GMT</pubDate>
            <atom:updated>2025-07-16T09:26:49.175Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/526/0*2x8FFCAM5AkaBmrs" /></figure><p>You might have heard the terms bias or average, but maybe you don’t fully understand what they mean. Today, I’ll try to explain some of these basic concepts simply.</p><p>What is Bias?</p><p>Bias is basically a small adjust value.</p><p>Imagine you created a trendline in Excel, but the line doesn’t perfectly fit all the data points. You’d need to add or subtract a little value so that it matches the real data more accurately.</p><p>In machine learning, the model shouldn’t depend only on the input value.<br>If there’s no bias, the model would always predict strictly based on input:</p><pre>Example formula:<br>output = weight * input + bias</pre><p>If bias is missing, all decisions would start from zero.<br>With bias, the model can adjust its decision more flexibly.</p><p>One line summary:<br>Bias allows the model to make better decisions, even when input is zero.</p><p>---</p><p>What Does &quot;Average of Numbers&quot; Mean?</p><p>You probably know how to calculate an average, but what does it really mean?</p><p>It means converting many numbers into a single number so that we understand the middle position of all values.</p><p>Example:</p><p>Data: 10, 20, 30</p><p>Average calculation:<br>(10 + 20 + 30) ÷ 3 = 20</p><p>That tells you the numbers, on average, are around 20.</p><p>One-line definition:</p><p>Average = Total sum ÷ Number of values</p><p>Even though it’s a basic concept, average is used in many complex projects:</p><p>Finding average values in a dataset</p><p>Business reports</p><p>Average salary, sales, etc.</p><p>---</p><p>I hope now you have a clearer understanding of bias and average of numbers.</p><p>If anything is unclear, feel free to ask. Happy learning!</p><p>---</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=4ce7dfda48e8" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Probability for Machine learning- Part 3]]></title>
            <link>https://medium.com/@shihabyahia22/probability-for-machine-learning-part-3-a58795c58da6?source=rss-ce4c9b1b6f96------2</link>
            <guid isPermaLink="false">https://medium.com/p/a58795c58da6</guid>
            <category><![CDATA[machine-learning]]></category>
            <category><![CDATA[programming]]></category>
            <category><![CDATA[data-science]]></category>
            <category><![CDATA[coding]]></category>
            <category><![CDATA[probability]]></category>
            <dc:creator><![CDATA[PyShihab]]></dc:creator>
            <pubDate>Sun, 13 Jul 2025 06:15:48 GMT</pubDate>
            <atom:updated>2025-07-13T06:15:48.823Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*ppV2IMkwdgDCaAa4PnEejg.webp" /></figure><p>We often say things like,<br>“There’s an 80% chance of rain today.”</p><p>That &quot;chance&quot; means probability.</p><p>In machine learning, probability is very important.<br>Because often, the machine has to decide:<br>“Yes or No?”</p><p>If:<br>Yes → 70% chance<br>No → 30% chance</p><p>Then the machine will pick Yes.</p><p>---</p><p>What is Probability?</p><p>Probability means:<br>How likely something is to happen.</p><p>Formula:<br>Probability = (Desired outcome) ÷ (Total possible outcomes)</p><p>Example:<br>You toss a coin.<br>Two sides: Head and Tail.<br>You want Head:</p><p>Probability = 1 ÷ 2 = 0.5</p><p>That means, there’s a 50% chance it will be Head.</p><p>---</p><p>Now another example:</p><p>In a bag:</p><p>3 red balls</p><p>2 blue balls</p><p>You pick one ball randomly.<br>Probability of getting a red ball:</p><p>= Number of red balls ÷ Total balls<br>= 3 ÷ (3+2)<br>= 3/5<br>= 0.6</p><p>That means 60% chance of getting a red ball.</p><p>---</p><p>Where It’s Used:</p><p>Weather prediction: Will it rain or not?</p><p>Machine learning: Cat or Dog image detection.</p><p>The machine uses probability to decide confidently.</p><p>---</p><p>If anything feels unclear, feel free to ask.<br>Hope now you got the basic idea of Probability. Thank you!</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=a58795c58da6" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Variance and standard deviation explained - Part 2]]></title>
            <link>https://medium.com/@shihabyahia22/variance-and-standard-deviation-explained-part-2-cad6ab828160?source=rss-ce4c9b1b6f96------2</link>
            <guid isPermaLink="false">https://medium.com/p/cad6ab828160</guid>
            <category><![CDATA[programming]]></category>
            <category><![CDATA[machine-learning]]></category>
            <category><![CDATA[technology]]></category>
            <category><![CDATA[data-science]]></category>
            <category><![CDATA[neural-network-algorithm]]></category>
            <dc:creator><![CDATA[PyShihab]]></dc:creator>
            <pubDate>Fri, 11 Jul 2025 09:20:02 GMT</pubDate>
            <atom:updated>2025-07-11T09:20:03.172Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*InRzF1sXDOKWnmm0O0vTrw.webp" /></figure><p>Why Mean Isn’t Always Enough: Understanding Variance and Standard Deviation</p><p>You might analyze data using the Mean. But Mean doesn’t always tell the full story. That’s where Variance and Standard Deviation come in.</p><p>A Simple Example:<br>Imagine two people both earn the same average salary. One has steady income, the other’s income jumps up and down. Mean alone won’t show that difference — Variance and Standard Deviation will.</p><p>---</p><p>What Is Variance?</p><p>Variance measures how far data points are from the mean.<br>The higher the variance, the more spread out the data is.</p><p>In simple words:<br>Mean tells the average. Variance tells how much values move around the average.</p><p>How to Calculate Variance:</p><p>1. Subtract the mean from each value</p><p>2. Square the differences</p><p>3. Add them up and divide by the number of values</p><p>Example:<br>Data: 10, 20, 30<br>Mean = 20</p><p>Variance = {(10−20)² + (20−20)² + (30−20)²} ÷ 3 = 66.67</p><p>---</p><p>Why Standard Deviation?</p><p>Variance is measured in squared units, which isn’t always easy to interpret.<br>That’s why we take the square root of the Variance — this is called the Standard Deviation.</p><p>It shows, in real numbers, how far values typically are from the mean.</p><p>Real-Life Example:<br>Monthly expenses: 15,000, 14,800, 16,000, 20,000.</p><p>The mean might look stable. But Standard Deviation will show exactly how much expenses rise and fall month to month.</p><p>---<br>Mean just shows the average.<br>Variance and Standard Deviation show how spread out your data really is.</p><p>You can’t fully understand data with only Mean.<br>Hope this gives you a clear idea of Variance and Standard Deviation.</p><p>If anything feels unclear, feel free to ask!</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=cad6ab828160" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Stastics basics explained]]></title>
            <link>https://medium.com/@shihabyahia22/stastics-basics-explained-4e067973030a?source=rss-ce4c9b1b6f96------2</link>
            <guid isPermaLink="false">https://medium.com/p/4e067973030a</guid>
            <category><![CDATA[math]]></category>
            <category><![CDATA[programming]]></category>
            <category><![CDATA[mathematics]]></category>
            <category><![CDATA[machine-learning]]></category>
            <category><![CDATA[data-science]]></category>
            <dc:creator><![CDATA[PyShihab]]></dc:creator>
            <pubDate>Thu, 10 Jul 2025 04:22:33 GMT</pubDate>
            <atom:updated>2025-07-10T04:23:57.183Z</atom:updated>
            <content:encoded><![CDATA[<p>What is Statistics and Why Should You Care?</p><p>If you want to teach a machine, you need to understand the data first.<br>And that’s exactly what Statistics helps you do — collect, analyze, and learn from data.</p><p>Let’s understand 3 fundamental terms:</p><p>1. Mean (Average)<br>Add all values and divide by total number of values.<br>Example:<br>Scores: 70, 80, 85, 90, 75<br>Mean = (70+80+85+90+75)/5 = 80</p><p>But wait!<br>If the values were 10, 15, 20, 25, 300<br>Mean = 74 — even though most are below 30.<br>Why? A large value (Outlier) distorts the average.</p><p>---</p><p>2. Median<br>The middle value when sorted.<br>For 10, 15, 20, 25, 300 → Median = 20<br>It’s stable, doesn’t get affected by outliers.</p><p>---</p><p>3. Mode<br>The most frequently occurring value.<br>In [5, 6, 6, 7, 8], Mode = 6<br>Example: If most customers ask for red t-shirts — that’s the mode.</p><p>When to use what?</p><p>Situation	Use</p><p>Data is clean and even	Mean<br>Data has extreme values (outliers)	Median<br>You need the most frequent value	Mode</p><p>---</p><p>Real Example: Salary Analysis</p><p>9 employees earn 30k, one earns 300k.<br>Mean = 57k<br>But 9 people still earn 30k!<br>Median = 30k → shows the real picture.</p><p>So, before you teach a model to learn, you must learn to think statistically.<br>In future posts, we’ll explore variance and standard deviation.</p><p>Stay tuned.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=4e067973030a" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Type of Neural network — Part 2]]></title>
            <link>https://medium.com/@shihabyahia22/type-of-neural-network-part-2-6f5f992eafc6?source=rss-ce4c9b1b6f96------2</link>
            <guid isPermaLink="false">https://medium.com/p/6f5f992eafc6</guid>
            <category><![CDATA[neural-network-algorithm]]></category>
            <category><![CDATA[machine-learning]]></category>
            <category><![CDATA[technology]]></category>
            <category><![CDATA[programming]]></category>
            <category><![CDATA[data-science]]></category>
            <dc:creator><![CDATA[PyShihab]]></dc:creator>
            <pubDate>Sat, 05 Jul 2025 11:38:56 GMT</pubDate>
            <atom:updated>2025-07-05T11:38:56.220Z</atom:updated>
            <content:encoded><![CDATA[<p>Just like everything in the world comes in different types, Neural Networks do too.<br>Imagine you have five sons. Not all of them are good at the same thing. One might be great at math, another at singing, another at drawing.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*UL8HqyCVIQgRDWfXaMhmdA.webp" /><figcaption>image generate by sora(AI)</figcaption></figure><p>That’s exactly how Neural Networks work. There are different types of neural networks, and each one specializes in a different kind of task.</p><p>The 5 Most Common Types of Neural Networks</p><p>1. ANN (Artificial Neural Network):<br>The most basic structure. It follows a flat design where the input flows through hidden layers to the output. Suitable for general problems.</p><p>2. CNN (Convolutional Neural Network):<br>Mainly used for visual data like images and videos. It helps detect features from images, like faces or objects.</p><p>3. RNN (Recurrent Neural Network):<br>Best for sequence-based data — like time-series, speech, or text. It processes data step by step, maintaining context from earlier inputs.</p><p>4. LSTM (Long Short-Term Memory):<br>An improved version of RNN. It can remember long-term dependencies — great for understanding long paragraphs or time-based data.</p><p>5. GAN (Generative Adversarial Network):<br>Used to generate new content — like creating realistic images, fake videos, or even new music.</p><p>So, what’s the point?</p><p>Each neural network type is designed for a specific kind of task or data.<br>Sometimes the model needs to recognize images, sometimes it needs to understand language, and sometimes it needs to track time-based changes.</p><blockquote>They all learn differently, understand differently, and make decisions differently — just like humans with different skills.</blockquote><p>This was just the basic overview of the common neural network types.<br>In upcoming parts, we’ll explore each one in more depth.</p><p>Thanks for reading!</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=6f5f992eafc6" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Neural Networks Explained Simply — Part 1]]></title>
            <link>https://medium.com/@shihabyahia22/neural-networks-explained-simply-part-1-2ef80f388da5?source=rss-ce4c9b1b6f96------2</link>
            <guid isPermaLink="false">https://medium.com/p/2ef80f388da5</guid>
            <category><![CDATA[neural-network-algorithm]]></category>
            <category><![CDATA[data-science]]></category>
            <category><![CDATA[ai]]></category>
            <category><![CDATA[programming]]></category>
            <category><![CDATA[machine-learning]]></category>
            <dc:creator><![CDATA[PyShihab]]></dc:creator>
            <pubDate>Thu, 03 Jul 2025 08:06:43 GMT</pubDate>
            <atom:updated>2025-07-03T08:06:43.369Z</atom:updated>
            <content:encoded><![CDATA[<p>Imagine you&#39;re teaching your child:<br>&quot;This is an apple,&quot; and &quot;That&#39;s a banana.&quot;<br>After a few examples, you show a picture of an orange — and they instantly recognize it.</p><p>But how?</p><p>Because the child has learned the patterns — colors, shapes, maybe even textures.<br>This process is exactly what happens inside a Neural Network.</p><p>---</p><p>So, what is a Neural Network?</p><p>A Neural Network is a machine learning model inspired by the human brain. It’s made of layers of &quot;neurons&quot; that process data in steps:</p><p>1. Input Layer – Accepts the data (images, text, numbers, etc.)</p><p>2. Hidden Layers – Perform calculations and extract patterns</p><p>3. Output Layer – Gives the final decision or prediction</p><p>---</p><p>Let’s break down a single neuron</p><p>Each neuron does this:</p><pre>output = activation(w1*x1 + w2*x2 + ... + wn*xn + bias)</pre><p>x1, x2, ..., xn are the inputs</p><p>w1, w2, ..., wn are weights (how important each input is)</p><p>bias adjusts flexibility</p><p>activation() helps decide the final output (like ReLU, Sigmoid, etc.)</p><p>---</p><p>A quick analogy</p><p>You’re shopping with 100 bucks.</p><p>Weights decide how much to spend on each item</p><p>Bias is like a backup — a small adjustment if prices are higher than expected</p><p>Together, they help the network make balanced decisions.</p><p>---</p><p>Forward vs Backward Propagation</p><p>Forward Propagation: Data goes in → math happens → output comes out</p><p>Backward Propagation: Model learns from the error → adjusts weights/bias → gets smarter</p><p>This happens thousands of times, slowly reducing errors until the model can confidently predict new data.</p><p>---</p><p>Final Thoughts</p><p>Neural Networks might sound complex, but at their core, they mimic how we humans learn from examples.<br>Once you understand neurons, layers, weights, and bias — everything else starts to click.</p><p>This is just the beginning.<br>In the next parts, we’ll go deeper into types of neural networks like ANN, CNN, RNN and more.</p><p>Thanks for reading!</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=2ef80f388da5" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[What Is Train-Test Split in Machine Learning?]]></title>
            <link>https://medium.com/@shihabyahia22/what-is-train-test-split-in-machine-learning-c863b0e54a31?source=rss-ce4c9b1b6f96------2</link>
            <guid isPermaLink="false">https://medium.com/p/c863b0e54a31</guid>
            <category><![CDATA[data-science]]></category>
            <category><![CDATA[python-programming]]></category>
            <category><![CDATA[machine-learning]]></category>
            <category><![CDATA[python]]></category>
            <category><![CDATA[coding]]></category>
            <dc:creator><![CDATA[PyShihab]]></dc:creator>
            <pubDate>Tue, 01 Jul 2025 03:22:27 GMT</pubDate>
            <atom:updated>2025-07-01T03:22:27.791Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*1yGOwzPZ0xzWOmp9YfO2OA.webp" /></figure><p>Imagine you’re a teacher. If you give your students the exact questions you taught during class, they’ll score full marks easily. But if you give them new questions, only then can you actually judge whether they understood the material.</p><p>Machine Learning works the same way. That’s why we use a technique called Train-Test Split — it’s one of the core steps in building and validating any ML model.</p><p>---</p><p>Why Do We Need Train-Test Split?</p><p>When we get a dataset, we divide it into two parts:</p><p>1. Training Set – to train the model</p><p>2. Test Set – to test the model on unseen data</p><p>We use the training set to teach the model how to make predictions. Then we use the test set to check if the model can handle new, real-world data.<br>This helps us ensure that the model isn&#39;t just memorizing — it’s actually learning to generalize.</p><p>---</p><p>Code Example (using Scikit-learn):</p><pre>from sklearn.model_selection import train_test_split X_train, X_test, y_train, y_test = train_test_split(X, y, test_size=0.2, random_state=42)</pre><p>test_size=0.2 means 20% of the data is used for testing, and 80% for training.</p><p>random_state=42 is used to keep the split reproducible.</p><p>---</p><p>Why It Matters</p><p>If your model performs well on training data but fails on new inputs, it’s practically useless in real-world scenarios.<br>That’s why Train-Test Split is not just a basic step — it’s a powerful checkpoint to build reliable machine learning models.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=c863b0e54a31" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Why Is requirements.txt So Important for programmer?]]></title>
            <link>https://medium.com/@shihabyahia22/why-is-requirements-txt-so-important-for-programmer-ead437b4b6ca?source=rss-ce4c9b1b6f96------2</link>
            <guid isPermaLink="false">https://medium.com/p/ead437b4b6ca</guid>
            <category><![CDATA[data-science]]></category>
            <category><![CDATA[programming]]></category>
            <category><![CDATA[terminal]]></category>
            <category><![CDATA[python]]></category>
            <category><![CDATA[machine-learning]]></category>
            <dc:creator><![CDATA[PyShihab]]></dc:creator>
            <pubDate>Mon, 30 Jun 2025 04:08:36 GMT</pubDate>
            <atom:updated>2025-07-01T04:07:22.524Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*fuZplEtWxpxQzjFjR9dS5w.webp" /><figcaption>Image genarate by Sora(AI)</figcaption></figure><p>Let’s say you’ve built a Python project, and you’ve installed a few libraries on your machine:</p><pre>pandas==1.5.3  <br>numpy==1.24.2  <br>scikit-learn==1.2.1</pre><p>Everything works perfectly. Now you upload the project to GitHub or send it to someone else. But — you haven’t told them which libraries they need to install.</p><p>Let’s assume they do install the required libraries, but maybe with different versions than yours. Suddenly, something breaks. A function is missing, or some syntax has changed.</p><p>Result?<br>Your program throws an error.</p><p>This is where requirements.txt saves the day.</p><p>---</p><p>So, what is requirements.txt?</p><p>It’s simply a .txt file that lists all the libraries your Python project depends on — along with their versions.</p><p>Think of it like a shopping list.<br>When someone wants to run your project, they can use this list to install all the required packages in one go.</p><p>---</p><p>How do you create it?</p><p>Once you’ve installed all the necessary libraries inside your virtual environment, just run this command in the terminal:</p><pre>pip freeze &gt; requirements.txt</pre><p>This will generate a requirements.txt file with all installed libraries and their exact versions.</p><p>---</p><p>Why even small projects should use it?</p><p>Even if you’re working on a small project, version mismatch can cause unexpected errors later. And for larger projects — it’s almost mandatory.</p><p>Whether you’re doing freelancing, working in a team, or deploying your app to production, requirements.txt is a must-have step.</p><p>---</p><p>যেI hope this helped clarify the importance of requirements.txt.<br>Thanks for reading.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=ead437b4b6ca" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[What is a Python Virtual Environment and Why Should You Use It?]]></title>
            <link>https://medium.com/@shihabyahia22/what-is-a-python-virtual-environment-and-why-should-you-use-it-b0d33a50b23c?source=rss-ce4c9b1b6f96------2</link>
            <guid isPermaLink="false">https://medium.com/p/b0d33a50b23c</guid>
            <category><![CDATA[data-science]]></category>
            <category><![CDATA[terminal]]></category>
            <category><![CDATA[python]]></category>
            <category><![CDATA[programming]]></category>
            <category><![CDATA[machine-learning]]></category>
            <dc:creator><![CDATA[PyShihab]]></dc:creator>
            <pubDate>Sun, 29 Jun 2025 11:09:16 GMT</pubDate>
            <atom:updated>2025-06-29T11:13:18.121Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*K3Rr1RWdpzT8G3ITH2Hj1A.webp" /><figcaption>Image generate by Sora (AI)</figcaption></figure><p>A virtual environment in Python is basically a separate workspace or a project-specific space where the libraries you install only work for that particular project. It doesn’t affect the global Python environment or system-wide settings.</p><p>---</p><p>Why is it necessary?</p><p>Let’s say you’re working on two different projects:</p><p>Project A: Requires Django version 3.2<br>Project B: Requires Django version 4.1</p><p>Now, if you install Django 4.1 globally, it may cause bugs in Project A because that project depends on version 3.2.<br>To avoid this kind of conflict, you can create a separate virtual environment for each project.<br>That way, every project will have the exact versions of tools it needs — no interference.</p><p>---</p><p>How to Create and Use a Virtual E nvironment</p><p>Step 1: Create the environment</p><pre>python -m venv new</pre><p>Here, new is just the folder name — feel free to use any name you prefer.</p><p>---</p><p>Step 2: Activate the environment</p><p>For Windows:</p><pre>new\Scripts\activate</pre><p>For macOS/Linux:</p><pre>source new/bin/activate</pre><p>Once it&#39;s activated, you’ll see the environment name like (new) in your terminal.</p><p>---</p><p>Step 3: Install a library</p><pre>pip install pandas</pre><p>This will install pandas only inside your virtual environment — not system-wide.</p><p>---</p><p>Step 4: To deactivate or exit the environment</p><pre>deactivate</pre><p>---</p><p>A Simple Analogy</p><p>Imagine you have two separate rooms in your house — one for studying and one for eating. Each room serves a different purpose.<br>Virtual environments are just like that — different environments for different projects, keeping things clean and organized.</p><p>---</p><p>Final Words</p><p>If you’re getting started with Python, understanding virtual environments early on is super important.<br>You might not notice the need during small projects, but once you go big — trust me, it’ll save you from a lot of version conflicts and headaches.<br>So, make it a habit from day one.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=b0d33a50b23c" width="1" height="1" alt="">]]></content:encoded>
        </item>
    </channel>
</rss>