<?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 Diyora M on Medium]]></title>
        <description><![CDATA[Stories by Diyora M on Medium]]></description>
        <link>https://medium.com/@mdiyora?source=rss-ffa45edd7a81------2</link>
        <image>
            <url>https://cdn-images-1.medium.com/fit/c/150/150/1*8kF55jiXPYBJbycJML0ciQ.jpeg</url>
            <title>Stories by Diyora M on Medium</title>
            <link>https://medium.com/@mdiyora?source=rss-ffa45edd7a81------2</link>
        </image>
        <generator>Medium</generator>
        <lastBuildDate>Fri, 04 Dec 2026 22:09:26 GMT</lastBuildDate>
        <atom:link href="https://medium.com/@mdiyora/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[Pure functions in JS]]></title>
            <link>https://medium.com/@mdiyora/pure-functions-in-js-908bda7c1b78?source=rss-ffa45edd7a81------2</link>
            <guid isPermaLink="false">https://medium.com/p/908bda7c1b78</guid>
            <category><![CDATA[javascript]]></category>
            <category><![CDATA[pure-function]]></category>
            <category><![CDATA[functional-programming]]></category>
            <dc:creator><![CDATA[Diyora M]]></dc:creator>
            <pubDate>Sun, 01 Jun 2025 07:53:55 GMT</pubDate>
            <atom:updated>2025-06-01T07:53:55.005Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*pYHxIAP36C-rphCHXOCnmQ.png" /></figure><h3>What are pure functions?</h3><p>In javascript, pure functions are functions that follow these <strong>two main rules</strong>:</p><ol><li><strong>Same inputs always produce same outputs</strong></li></ol><p>A pure function always returns the same result if the same arguments are passed.</p><p><strong><em>2. No side effects</em></strong></p><p>This means it doesn’t alter external data. Specifically, it doesn’t:</p><ul><li>Modify global variables</li><li>Change the values of arguments</li><li>Perform I/O operations (e. g. logging to a console, writing to a file, etc.)</li></ul><h4>Example of a pure function:</h4><pre>function multiply(a, b){<br>	return a*b;<br>}</pre><p>Note that:</p><ul><li>It always returns the same result for the same inputs.</li><li>It does not modify anything outside itself.</li></ul><h4>Example of an impure function:</h4><pre>let multiplier=2;<br><br>function multiply(a){<br>	return a*multiplier;<br>}</pre><p>It is not a pure function, because:</p><ul><li>If multiplier changes outside of a function, the result of multiply(10) also changes.</li><li>The function depends on something outside its own scope — the multiplier variable.</li><li>So, it’s not pure, even though it looks simple.</li></ul><h4>Still don’t understand?</h4><p>Think of a pure function like a mathematical function. f(x)=x+5 always returns 7 when x=2, no matter what is happening outside of a function.</p><p>In the next post, we will explore pure components in React.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=908bda7c1b78" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Synthetic Events in React]]></title>
            <link>https://medium.com/@mdiyora/synthetic-events-in-react-7ab28adf68d9?source=rss-ffa45edd7a81------2</link>
            <guid isPermaLink="false">https://medium.com/p/7ab28adf68d9</guid>
            <category><![CDATA[synthetic-event]]></category>
            <category><![CDATA[react]]></category>
            <category><![CDATA[reactjs]]></category>
            <dc:creator><![CDATA[Diyora M]]></dc:creator>
            <pubDate>Wed, 28 May 2025 17:34:07 GMT</pubDate>
            <atom:updated>2025-05-28T17:34:07.084Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*ZOX__LaCTSlPAyLYIlNA7g.png" /></figure><p>In React, a <strong>SyntheticEvent</strong> is a cross-browser wrapper around the browser’s native event system. It provides a consistent API for handling events across all browsers, ensuring that your application behaves predictably regardless of the user’s browser.</p><p>React provides synthetic events for various types, such as:</p><ul><li>onClick</li><li>onChange</li><li>onSubmit</li><li>onKeyDown, etc.</li></ul><p>The SyntheticEvent mimics the interface of native events, including properties and methods like:</p><ul><li>event.preventDefault()</li><li>event.stopPropagation()</li><li>event.target</li></ul><p><strong>How does it work?</strong><br> React creates a SyntheticEvent object that wraps the native browser event object to normalize event properties and behavior.</p><p><strong>Why is it needed?</strong><br> Different browsers can handle events differently. SyntheticEvent ensures that events have the same properties and methods regardless of the browser.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=7ab28adf68d9" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Topic vocabulary: At work]]></title>
            <link>https://medium.com/@mdiyora/topic-vocabulary-at-work-59ab5bf67bca?source=rss-ffa45edd7a81------2</link>
            <guid isPermaLink="false">https://medium.com/p/59ab5bf67bca</guid>
            <category><![CDATA[work]]></category>
            <category><![CDATA[english-vocabulary]]></category>
            <category><![CDATA[ielts-vocabulary]]></category>
            <category><![CDATA[new-words]]></category>
            <category><![CDATA[vocabulary-for-ielts]]></category>
            <dc:creator><![CDATA[Diyora M]]></dc:creator>
            <pubDate>Tue, 22 Oct 2024 07:10:37 GMT</pubDate>
            <atom:updated>2024-10-22T07:10:37.888Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*-ptpfi0iefG5Bh-KereddA.jpeg" /></figure><p>I invite you to allocate your 5 minute time and learn 5 new English words related to work. Let’s dive in!</p><p>1. Tight schedules</p><p><em>very strict or severely limited timetables</em></p><p><strong>Example</strong>: Working under <strong>tight schedules</strong> requires efficient time management and prioritization to meet deadlines.</p><p>2. Mundane</p><p><em>ordinary, not interesting</em></p><p><strong>Example</strong>: I do fairly <strong>mundane</strong> tasks at work.</p><p>3. Glamorous</p><p><em>very exciting, which everyone admires</em></p><p><strong>Example: </strong>I have a pretty <strong>glamorous</strong> job.</p><p>4. Monotonous</p><p><em>boring because it never changes</em></p><p><strong>Example</strong>: The daily meetings felt <strong>monotonous</strong>, covering the same points with little variation.</p><p>5. Stimulating</p><p><em>encouraging new ideas or new thinking</em></p><p><strong>Example</strong>: The team found the brainstorming session <strong>stimulating</strong>, as it sparked new ideas for the project.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=59ab5bf67bca" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Topic vocabulary: Studying]]></title>
            <link>https://medium.com/@mdiyora/topic-vocabulary-studying-372e61b6419e?source=rss-ffa45edd7a81------2</link>
            <guid isPermaLink="false">https://medium.com/p/372e61b6419e</guid>
            <category><![CDATA[ielts-vocabulary]]></category>
            <category><![CDATA[english-vocabulary-words]]></category>
            <category><![CDATA[topic-vocabulary]]></category>
            <category><![CDATA[ielts-vocabulary-topic]]></category>
            <category><![CDATA[studying]]></category>
            <dc:creator><![CDATA[Diyora M]]></dc:creator>
            <pubDate>Mon, 21 Oct 2024 09:41:55 GMT</pubDate>
            <atom:updated>2024-10-21T09:41:55.016Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*RxdZzICYxLp7JnxvdRU_Lg.jpeg" /></figure><p>Topic vocabulary is essential to speak and write effectively in any language. Below I will list 5 vocabulary terms about studying.</p><ol><li>Cram</li></ol><p><em>study in a very concentrated way for a short period of time</em></p><p><strong>Example</strong>: Before an exam, some students <strong>cram</strong> for it.</p><p>2. Genius</p><p><em>an exceptionally clever person</em></p><p><strong>Example</strong>: Even if you’re a <strong>genius</strong>, you’ll have to do some revision.</p><p>3. Past papers</p><p><em>exam papers from previous years</em></p><p><strong>Example</strong>: If the exam happens every year, you can revise by looking at <strong>past papers</strong>.</p><p>4. Know the subject inside out</p><p><em>know it completely</em></p><p><strong>Example</strong>: Study intensively until you <strong>know the subject inside out</strong>.</p><p>5. Bury oneself into their books</p><p><em>spend the maximum time studying</em></p><p><strong>Example</strong>: All things considered, the best idea is to <strong>bury yourself into your books.</strong></p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=372e61b6419e" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Event stages in JavaScript]]></title>
            <link>https://medium.com/@mdiyora/event-stages-in-javascript-f737a8bdbd23?source=rss-ffa45edd7a81------2</link>
            <guid isPermaLink="false">https://medium.com/p/f737a8bdbd23</guid>
            <category><![CDATA[js]]></category>
            <category><![CDATA[bubbling]]></category>
            <category><![CDATA[js-event-handling]]></category>
            <category><![CDATA[target]]></category>
            <category><![CDATA[capturing]]></category>
            <dc:creator><![CDATA[Diyora M]]></dc:creator>
            <pubDate>Wed, 16 Oct 2024 12:16:05 GMT</pubDate>
            <atom:updated>2024-10-16T12:16:05.105Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*hTohJITrIVziX8BF7QmwCA.png" /></figure><p>Do you know what are three stages of JavaScript event? If, not you should probably read this post till the end. It was my recent interview question.</p><p>There are 3 stages of JS event:</p><ol><li>Capturing phase</li><li>Target phase</li><li>Bubbling phase</li></ol><p>They follow the same order as listed above.</p><p>Capturing phase is when the event goes down to the element. Target phase is when the event reaches the target element. Bubbling phase occurs when the event bubbles up from the element.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*kPQAoaPFS3ZLRtQDlHtbew.png" /></figure><p>By default, the addEventListener() method will be called during bubbling phase.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=f737a8bdbd23" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Parallel Structure]]></title>
            <link>https://medium.com/@mdiyora/parallel-structure-ebc44c85e082?source=rss-ffa45edd7a81------2</link>
            <guid isPermaLink="false">https://medium.com/p/ebc44c85e082</guid>
            <category><![CDATA[sentence-structure]]></category>
            <category><![CDATA[writing]]></category>
            <category><![CDATA[parallel-structure]]></category>
            <category><![CDATA[english-grammar]]></category>
            <category><![CDATA[writing-tips]]></category>
            <dc:creator><![CDATA[Diyora M]]></dc:creator>
            <pubDate>Tue, 01 Oct 2024 14:16:29 GMT</pubDate>
            <atom:updated>2024-10-01T14:16:29.142Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*nO1uYqVoddJnwp2LmodUuQ.jpeg" /></figure><p>In English, we can create parallel structure in our sentences. We achieve parallel structure by using the same grammatical forms or structures.</p><p><em>She loves to sing and dance.</em></p><p>In the example above, both <em>sing</em> and <em>dance</em> are verbs. It is important that both are verbs because we have the conjunction “and” joining them. On both sides of the conjunction, we need to have the same grammatical form.</p><p>Here are some connectors that require parallel structure:</p><p>___ and ___<br>___ but ___<br>both ___ and ___<br>not only ___ but also ___</p><p>With these connectors, you need to have the same grammatical structure in both blanks.</p><p>Look at this example:</p><p><em>I was looking for an apartment that was both close to my work and easy to afford.</em></p><p>Here we have “close to my work” and “easy to afford”; both are adjective phrases, so they have the same structure.</p><p>Now, let’s look at an example that does not have parallel structure:</p><p><em>I want to find a gym that is not only close to my apartment but also I want to find a cheap one.</em></p><p>“Close to my apartment” is an adjective phrase, while “I want to find a cheap one” is an independent clause. Therefore, they do not have the same structure. Here’s one way to fix it:</p><p><em>I want to find a gym that is not only close to my apartment but also affordable.</em></p><p>By changing the independent clause to an adjective, now <em>close to my apartment</em> and <em>affordable</em> are both adjective phrases, creating parallel structure.</p><p>Another example of parallel structure:</p><p><em>They are interested in visiting Paris and going to the Eiffel Tower.</em></p><p>By maintaining parallel structure, your sentences will flow better and sound more balanced. Happy writing!</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=ebc44c85e082" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[When to Use a Comma?]]></title>
            <link>https://medium.com/@mdiyora/when-to-use-a-comma-e1b3b1ce2ee4?source=rss-ffa45edd7a81------2</link>
            <guid isPermaLink="false">https://medium.com/p/e1b3b1ce2ee4</guid>
            <category><![CDATA[sentence]]></category>
            <category><![CDATA[writing]]></category>
            <category><![CDATA[english-grammar]]></category>
            <category><![CDATA[comma]]></category>
            <dc:creator><![CDATA[Diyora M]]></dc:creator>
            <pubDate>Mon, 30 Sep 2024 04:46:10 GMT</pubDate>
            <atom:updated>2024-09-30T04:46:10.863Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*zZWds86rFZkmcvycdLtBSw.jpeg" /></figure><p>This is a simple and easy guide to the correct use cases of commas in sentences. There are <strong>four</strong> main cases where commas should be used:</p><ol><li><strong>Compound sentences</strong></li></ol><p>Use a comma in compound sentences when two independent clauses are connected by <strong>conjunctions</strong> or <strong>transitions</strong>.</p><p><em>The game is difficult, but it is fun to play.</em></p><p>Here, we used the conjunction “but” along with the comma. Remember to place the comma <strong>before</strong> the conjunction in compound sentences. Common conjunctions include: <em>and, but, or, nor, yet, so,</em> and <em>for</em>.</p><p><em>Jane loves books; therefore, she reads all the time.</em></p><p>In this sentence, we used the transition word “therefore.” When you use a transition word to connect two simple sentences, place a semicolon before the transition and a comma after it. Common transitions include: <em>however, otherwise, then, also, thus, indeed,</em> and <em>finally</em>.</p><p><strong>2. Series of words</strong></p><p><em>The dog chases rabbits, cats, and birds.</em></p><p>Use a comma with a series of three or more items in a sentence. These items could be <em>nouns</em>, <em>adjectives</em>, or <em>verbs</em>:</p><p><em>She learned to swim, kayak, and sail.</em></p><p><strong>3. Introductory phrases</strong></p><p><em>On Monday, my teacher announced a test.</em></p><p><em>For several month, I have been playing the guitar.</em></p><p>With introductory phrases, use a comma to separate them from the main sentence. In the examples above, “On Monday” and “For several months” are introductory phrases.</p><p><strong>4. Interrupting phrases</strong></p><p><em>The mayor, by the way, will be at the meeting.</em></p><p>Interrupting phrases break the flow of the sentence without changing its overall meaning. For example, in the sentence above, removing the phrase “by the way” leaves “The mayor will be at the meeting,” which is still a complete sentence. Interrupting phrases can also appear at the end of a sentence:</p><p><em>Joe want to buy a house, too.</em></p><h3>Summary</h3><p>Use a comma:</p><ul><li>In compound sentences with conjunctions and transitions</li><li>With a series of three or more items</li><li>With introductory phrases</li><li>With interrupting phrases</li></ul><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=e1b3b1ce2ee4" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Complex sentence in English]]></title>
            <link>https://medium.com/@mdiyora/complex-sentence-in-english-3c8c4290f870?source=rss-ffa45edd7a81------2</link>
            <guid isPermaLink="false">https://medium.com/p/3c8c4290f870</guid>
            <category><![CDATA[writing-tips]]></category>
            <category><![CDATA[when-to-use-comma]]></category>
            <category><![CDATA[adverb-clause]]></category>
            <category><![CDATA[complex-sentences]]></category>
            <category><![CDATA[adverb-clause-connectors]]></category>
            <dc:creator><![CDATA[Diyora M]]></dc:creator>
            <pubDate>Thu, 26 Sep 2024 13:50:55 GMT</pubDate>
            <atom:updated>2024-09-26T13:59:55.709Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*XSFroxjt_PisCNwtgcirFQ.jpeg" /></figure><p>Let’s review sentence types in English. We know there are three main sentence types: simple, compound, and complex.</p><ol><li><strong>A simple sentence</strong> has one independent clause:<br><em>James did his homework.</em></li><li><strong>A compound sentence</strong> has two independent clauses:<br><em>James did his homework, and Matt read a book.</em></li><li><strong>A complex sentence</strong> has one independent clause and one or more dependent clauses:<br><em>I started working after I graduated from college.</em></li></ol><h3>What exactly is an independent and a dependent clause?</h3><p>An independent clause is simply a simple sentence. It has one subject and one verb, and it can stand as a complete sentence. However, a dependent clause is an incomplete sentence. It can’t stand alone as a sentence. In the last example, “after I graduated from college” is a dependent clause, and “I started working” is an independent clause.</p><h3><strong>Adverb clause connectors</strong></h3><p>Dependent clauses are also called adverb clauses. They are connected to the independent clause with adverb clause connectors.</p><p>Here are some examples of adverb clause connectors:<br><em>after, while, before, when, since, because, although, if, unless</em></p><h3><strong>When to Use a Comma</strong></h3><ol><li>If the dependent clause comes before the independent clause, we place a comma after the dependent clause:<br><em>After I graduated from college, I started working.</em></li><li>If the independent clause comes before the dependent clause, we do NOT place a comma:<br><em>I started working after I graduated from college.</em></li></ol><p>Now you know what a complex sentence is and how to use them correctly. Remember to place commas carefully, as many of us tend to misplace commas in complex sentences.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=3c8c4290f870" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Compound sentence and punctuation]]></title>
            <link>https://medium.com/@mdiyora/compound-sentence-and-punctuation-c29cfe33c44d?source=rss-ffa45edd7a81------2</link>
            <guid isPermaLink="false">https://medium.com/p/c29cfe33c44d</guid>
            <category><![CDATA[compound-sentence]]></category>
            <category><![CDATA[english]]></category>
            <category><![CDATA[conjunctions]]></category>
            <category><![CDATA[semi-colon]]></category>
            <category><![CDATA[punctuation]]></category>
            <dc:creator><![CDATA[Diyora M]]></dc:creator>
            <pubDate>Wed, 25 Sep 2024 01:49:24 GMT</pubDate>
            <atom:updated>2024-09-25T02:06:22.954Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*dGiwaA-9RzNN8EQjH3XIJA.jpeg" /></figure><p>In the last post, we talked about sentence types in English. Now, let’s learn more about the second sentence type: the compound sentence.</p><p>A compound sentence has two independent clauses, which include two subjects and two verbs:.</p><p><em>Alice washed her face, and she combed her hair.</em></p><p>There are three types of compound sentences:</p><ol><li>Compound sentences with conjunctions</li><li>Compound sentences with transitions</li><li>Compound sentences with only a semicolon</li></ol><h3>1. Compound sentences with conjunctions</h3><p>There are seven coordinating conjunctions: and, but, or, nor, yet, so, for. When a compound sentence includes a conjunction, place a comma before the conjunction.</p><p><em>The cyclist used all of his energy</em><strong><em>, but</em></strong><em> he rode up the steep hill very slowly.</em></p><h3>2. Compound sentences with transitions</h3><p>These are just some of the transition words that you can use in your writing: therefore, in addition, however, thus, similarly, then, also, otherwise. Transition words are punctuated differently from conjunctions.</p><p><em>Saving money is not easy</em><strong><em>; however,</em></strong><em> it is a good habit to follow.</em></p><p>Notice the punctuation. When we use a transition word, we have to put a semicolon in front of the word and a comma after it.</p><h3>3. Compound sentences with only a semicolon</h3><p>In this type of compound sentence, we only use a semicolon to join two sentences.</p><p><em>The music was loud</em><strong><em>;</em></strong><em> everyone was dancing.</em></p><p>Notice that these two sentences are closely related. We could imagine saying “and” here:</p><p><em>The music was loud</em><strong><em>, and</em></strong><em> everyone was dancing.</em></p><p>When your sentences are closely related, you can join them with a semicolon. However, be careful not to use this method too often in your writing.</p><p>So remember, there are three types of compound sentences that you can use in your writing. The first type uses a comma and a conjunction like “and,” “but,” or “so.”</p><p>The second type uses a semicolon with a transition and a comma. Transitions are words like “therefore” or “however.”</p><p>The third type uses only a semicolon. And remember, you can only do that when the two sentences are very closely related.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=c29cfe33c44d" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Sentence types in English that you should know]]></title>
            <link>https://medium.com/@mdiyora/sentence-types-in-english-that-you-should-know-e3c4ed1166f4?source=rss-ffa45edd7a81------2</link>
            <guid isPermaLink="false">https://medium.com/p/e3c4ed1166f4</guid>
            <category><![CDATA[english]]></category>
            <category><![CDATA[conjunctions]]></category>
            <category><![CDATA[sentence-types]]></category>
            <category><![CDATA[simple-sentence]]></category>
            <category><![CDATA[compound-sentence]]></category>
            <dc:creator><![CDATA[Diyora M]]></dc:creator>
            <pubDate>Tue, 24 Sep 2024 11:37:39 GMT</pubDate>
            <atom:updated>2024-09-24T11:42:09.599Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*747B34Q0laP1skZzfwvH9A.jpeg" /></figure><p>In this post, we will talk about sentence types, conjunctions, and punctuation. To improve your writing skills in English, you should know about them. Whether you are preparing for academic tests or writing a post on social media, it is important to be aware of basic English grammar regarding sentences.</p><p>There are three sentence types in English:</p><ul><li>Simple</li><li>Compound</li><li>Complex</li></ul><p><strong>Simple sentence<br></strong><em>Alice washed her face.</em><br>A simple sentence has just one subject and verb and is called an independent clause.</p><p><strong>Compound sentence</strong><br><em>Alice washed her face, and she combed her hair.</em><br>A compound sentence is made up of two simple sentences, or two independent clauses. These two independent clauses are joined together, and one way to join them is with a conjunction and a comma.</p><p><strong>Complex sentence</strong><br><em>Alice got dressed because it was time for school.</em><br>A complex sentence has one independent clause and one or more dependent clauses.</p><p>We will talk more about complex sentences in the next posts. Right now, let’s talk about conjunctions and their use cases.</p><p><strong>And, but, or, nor, yet, so, for</strong> are called coordinating conjunctions. These conjunctions help us connect things.</p><p><em>Alice washed her face but not her hair.</em><br>(The conjunction <em>but</em> is joining “face” and “hair.”)</p><p><em>We will go to the park or the market.</em><br>(The conjunction <em>or</em> is joining “park” and “market.”)</p><p><em>She bought apples, pears, and grapes.</em><br>(The conjunction <em>and</em> is joining the three nouns.)</p><p>Notice in the first sentence, we had two nouns, “face” and “hair,” and we used the conjunction <em>and</em>. We don’t use a comma because there are only two nouns joined. In the last sentence, we have “apples, pears, and grapes.” Because we have three or more nouns, we use commas between each one. And you should notice that all of these sentences are simple sentences. Simple sentences don’t use a lot of commas.</p><p>Now, let’s look at compound sentences. Here, we’re using conjunctions to join two sentences instead of two words.</p><p><em>Alice washed her face, and she combed her hair.</em><br>Here, our first sentence or independent clause is “Alice washed her face.” The other independent clause is “she combed her hair.” Both of these are simple sentences and could stand alone by themselves. But we’re joining them to make a compound sentence, and we used the conjunction <em>and</em>. When we join two independent clauses with conjunctions, we must put a comma in front of them.</p><p>More examples:<br><em>The bank is closed, so we can’t cash the check.</em><br><em>There was no air conditioning, yet we were cool.</em></p><p>So conclusion is, in simple sentences with two nouns joined by a conjunction, no comma is needed. Use commas to separate three or more items in a list.</p><p>In compound sentences, place a comma before the conjunction joining two independent clauses.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=e3c4ed1166f4" width="1" height="1" alt="">]]></content:encoded>
        </item>
    </channel>
</rss>