<?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: Mounira Say</title>
    <description>The latest articles on DEV Community by Mounira Say (@mounira_say_13e6315265220).</description>
    <link>https://dev.to/mounira_say_13e6315265220</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%2F1833269%2Fadd8c408-8d9d-4856-b563-4c31bdae3cc8.jpg</url>
      <title>DEV Community: Mounira Say</title>
      <link>https://dev.to/mounira_say_13e6315265220</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://dev.to/feed/mounira_say_13e6315265220"/>
    <language>en</language>
    <item>
      <title>Popular interview question: What is the difference between Process and Thread ?</title>
      <dc:creator>Mounira Say</dc:creator>
      <pubDate>Thu, 26 Sep 2024 19:41:21 +0000</pubDate>
      <link>https://dev.to/mounira_say_13e6315265220/popular-interview-question-what-is-the-difference-between-process-and-thread--4098</link>
      <guid>https://dev.to/mounira_say_13e6315265220/popular-interview-question-what-is-the-difference-between-process-and-thread--4098</guid>
      <description>&lt;p&gt;To better understand this question, let's first take a look at what is a program.A program is an executable file containing a set of instructions and passively stored on disk. &lt;br&gt;
One program can have multiple processes.For example, the chrome browser creates a different process for every single tab.&lt;br&gt;
A Process means a program is in execution.When a program is loaded into the memory and becomes active, the program becomes a process.The process requires some essential resources such as registers,program counter,and stack.&lt;/p&gt;

&lt;p&gt;A Thread is the smallest unit of execution within a process.&lt;/p&gt;

&lt;p&gt;Main differences between process and thread:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;processes are usually independent,while threads exist as subsets of a process.&lt;/li&gt;
&lt;li&gt;Each process has its own memory space.Threads that belong to the same process share the same memory.
-A process is a heavyweight operation. It takes more time to create and terminate.
-Context switching is more expensive between processes.
-Inter-thread communication is faster for threads.&lt;/li&gt;
&lt;/ul&gt;

</description>
      <category>webdev</category>
      <category>news</category>
      <category>architecture</category>
      <category>interview</category>
    </item>
  </channel>
</rss>
