<?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: Margarita Vlachou</title>
    <description>The latest articles on DEV Community by Margarita Vlachou (@mvlachou).</description>
    <link>https://dev.to/mvlachou</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%2F673102%2F146a3a3a-157b-40c0-ac0d-393e7b2957b4.jpg</url>
      <title>DEV Community: Margarita Vlachou</title>
      <link>https://dev.to/mvlachou</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://dev.to/feed/mvlachou"/>
    <language>en</language>
    <item>
      <title>Blockchain - a distributed P2P network</title>
      <dc:creator>Margarita Vlachou</dc:creator>
      <pubDate>Sun, 23 Jan 2022 14:26:23 +0000</pubDate>
      <link>https://dev.to/mvlachou/blockchain-a-distributed-p2p-network-hgn</link>
      <guid>https://dev.to/mvlachou/blockchain-a-distributed-p2p-network-hgn</guid>
      <description>&lt;h2&gt;
  
  
  Network Types
&lt;/h2&gt;

&lt;p&gt;&lt;u&gt;&lt;strong&gt;Centralized network&lt;/strong&gt;&lt;br&gt;
&lt;/u&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Built around a single server and use client-server architecture. &lt;/li&gt;
&lt;li&gt;Advantages: Efficiency, consistency and affordability. &lt;/li&gt;
&lt;li&gt;Disadvantages: single point of failure can be risk for organizations, limited scalability, lack of bandwidth&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--n32OeLE5--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/pju715bron466kzgzujc.png" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--n32OeLE5--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/pju715bron466kzgzujc.png" alt="Image description" width="437" height="305"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;&lt;u&gt;&lt;strong&gt;Decentralized network&lt;/strong&gt; &lt;br&gt;
&lt;/u&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Distributes the workload among different machines. &lt;/li&gt;
&lt;li&gt;Benefits: reliability, scalability and privacy.There is no single point of failure. Information passes through a number of different points. &lt;/li&gt;
&lt;li&gt;Disadvantages: requires more machines.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--uUhbK7ih--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/7tqc2c39bg2umw6weos8.png" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--uUhbK7ih--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/7tqc2c39bg2umw6weos8.png" alt="Image description" width="277" height="158"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;&lt;u&gt;&lt;strong&gt;Distributed Network&lt;/strong&gt;&lt;/u&gt; spread over different networks. Part of distributed computing architecture. &lt;/p&gt;

&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--2rSJzK7L--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/vwh3szwjb4093nqcmllw.png" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--2rSJzK7L--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/vwh3szwjb4093nqcmllw.png" alt="Image description" width="276" height="168"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;&lt;u&gt;&lt;strong&gt;P2P network&lt;/strong&gt; &lt;br&gt;
&lt;/u&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Consists of a group of devices that collectively store and share files. &lt;/li&gt;
&lt;li&gt;Each participant (peer) has equal power and each node holds a copy of the file and each node can download nodes from other nodes. &lt;/li&gt;
&lt;li&gt;In a P2P network there is no central governing authority. &lt;/li&gt;
&lt;li&gt;All nodes are equal to each other. Anyone connected to this network can share and download any file shared by other users in the network&lt;/li&gt;
&lt;li&gt;A P2P network refers to the exchange of digital assets or cryptocurrencies via a distributed network and there is no need for intermediaries. P2P networks are at the center of most cryptocurrencies and other stributed computed applications such as Netflix, Amazon, Google.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--kX_iPjad--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/tqg5km4xesn4rlcs4i4m.png" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--kX_iPjad--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/tqg5km4xesn4rlcs4i4m.png" alt="Image description" width="322" height="262"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  P2P networks categorized into 3 main types :
&lt;/h2&gt;

&lt;ul&gt;
&lt;li&gt;&lt;p&gt;&lt;u&gt;&lt;strong&gt;Unstructured&lt;/strong&gt;&lt;/u&gt;, no specific organization of nodes. Participants communicate randomly with one another. They are robust and require higher memory&lt;br&gt;
&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--x59Wtj67--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/v8awmypcuh3zivzwdjci.png" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--x59Wtj67--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/v8awmypcuh3zivzwdjci.png" alt="Image description" width="320" height="232"&gt;&lt;/a&gt;&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;u&gt;&lt;strong&gt;Structured&lt;/strong&gt;&lt;/u&gt; allows nodes to search for files even if the content is not available. They are more efficient but require higher maintenance and setup costs but also they are less robust.&lt;/p&gt;&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--2mGX7M8e--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/n5tl3savpg5jwxdjq0ku.png" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--2mGX7M8e--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/n5tl3savpg5jwxdjq0ku.png" alt="Image description" width="196" height="191"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;u&gt;&lt;strong&gt;Hybrid&lt;/strong&gt;&lt;/u&gt; Combines the conventional client server model with some facets of the peer-to-peer architecture and improve overall performance&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--F6t5Qaah--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/xorsx8sxfptmteuy17nr.png" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--F6t5Qaah--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/xorsx8sxfptmteuy17nr.png" alt="Image description" width="251" height="213"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  Server based vs P2P network
&lt;/h2&gt;

&lt;p&gt;&lt;u&gt; Server based network&lt;br&gt;
&lt;/u&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Network security and storage are controlled and managed by one or more servers&lt;/li&gt;
&lt;li&gt;More complex and costly to manage and set up compared to a P2P network&lt;/li&gt;
&lt;li&gt;Are good for businesses that are having more than 10 computers&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;u&gt; P2P network&lt;br&gt;
&lt;/u&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Consists of devices that are collectively store and share files.&lt;/li&gt;
&lt;li&gt;There is no central regulatory authority&lt;/li&gt;
&lt;li&gt;Anyone can share and download any file which is shared by other peers in the network&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--M2kMUQ7v--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/2xrfel53mld80vivjlkm.png" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--M2kMUQ7v--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/2xrfel53mld80vivjlkm.png" alt="Image description" width="489" height="277"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  P2P network &amp;amp; Blockchain
&lt;/h2&gt;

&lt;ul&gt;
&lt;li&gt;In 2008, Satoshi Nakamoto defined Bitcoin as a Peer-to-peer Electronic Cash System&lt;/li&gt;
&lt;li&gt;P2P allows Bitcoin and other cryptocurrencies to be transferred worldwide, without the need for any central server.&lt;/li&gt;
&lt;li&gt;Anyone can set up a Bitcoin node if they want to participate in the process of validating and verifying blocks&lt;/li&gt;
&lt;li&gt;Blockchain acts as a digital ledger that publicly records all the activity. If any malicious activity is found the network quickly rejects it&lt;/li&gt;
&lt;li&gt;Nodes provide security to the network by verifying transactions against the system’s consensus rules&lt;/li&gt;
&lt;li&gt;The P2P architecture of blockchains provides benefits of greater security than traditional client-server based networks as distribution of large numbers of nodes creates an immune system to Denial-of-Service attack.&lt;/li&gt;
&lt;li&gt;Changing data is almost impossible in a distributed P2P network especially when we talk about big networks such as Bitcoin&lt;/li&gt;
&lt;li&gt;Unlike standard bank accounts, cryptocurrency can’t be drained or frozen by governments.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--VstBOxbZ--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/mxu1vhbawcimgaevzk28.png" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--VstBOxbZ--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/mxu1vhbawcimgaevzk28.png" alt="Image description" width="686" height="262"&gt;&lt;/a&gt;&lt;/p&gt;

</description>
      <category>blockchain</category>
      <category>developer</category>
      <category>networks</category>
      <category>webdev</category>
    </item>
    <item>
      <title>How I started my Web Development career in 2021</title>
      <dc:creator>Margarita Vlachou</dc:creator>
      <pubDate>Wed, 29 Dec 2021 22:33:05 +0000</pubDate>
      <link>https://dev.to/mvlachou/how-i-started-my-web-development-career-in-2021-58aa</link>
      <guid>https://dev.to/mvlachou/how-i-started-my-web-development-career-in-2021-58aa</guid>
      <description>&lt;p&gt;2021 has been a very challenging and exciting year at the same time but at the end I managed to do the switch I always wanted... &lt;/p&gt;

&lt;p&gt;10 years ago I started my bachelor's degree in Information Technology but due to life circumstances I was never able to pursue that career as sometimes life gets in the middle you see. &lt;/p&gt;

&lt;p&gt;I remember, 6 years ago, I was talking with friends and they were asking me what I want to do, what is the dream job for me.. and I remember I was just smiling and I was saying "Web development" and everyone was telling me that I need to focus on that and follow my heart. But in life things aren't as straight forward sometimes. &lt;/p&gt;

&lt;p&gt;I was at a point in my life where I didn't have the space to think or dream about anything, but I had to do what I had to do in order to pay my bills. But every time I was closing my eyes ... I was keep dreaming and thinking about that dream career and job and I was instantly smiling.&lt;/p&gt;

&lt;p&gt;In 2020... and when the pandemic started, I realized that life can be too short and there is no reason to waste our time and do things we don't enjoy. For that reason, I decided to apply for a master's degree in Software Development. I was studying full time my online course, while I was working full time as well and sometimes without days off for weeks. But I said to myself that if I can push through this, then I will be unstoppable. &lt;/p&gt;

&lt;p&gt;I only new the basic of C++, HTML, CSS , JS and I just started learning React when I applied for my Masters. The challenge I had in front of me was unreal and many times I was getting frustrated and I was asking myself why I did this as I didn't have the knowledge required for that degree. I had to do python, develop a full stack application and all that while I had to learn the technologies as I go. It was tough...&lt;/p&gt;

&lt;p&gt;The first 2 semesters gone and I have been successful so far. In addition to that I had a full stack application in my hands as a project I could add to my portfolio. And that was the point when I started applying for jobs. I applied for over 100 jobs in 3 months time with no luck. And suddenly I've been offered a position as full stack developer position. I couldn't believe it. And few months later, I realized that I do enjoy more front end development and I moved to a different company as front end developer.&lt;/p&gt;

&lt;p&gt;The lesson I've learnt from that process is that you will never be 100% ready for any job but apply anyway. Employers are looking for skills and experience, but also they are looking for the right attitude and willingness to learn. Skills get be taught, but the right attitude can't.&lt;/p&gt;

&lt;p&gt;So if you are starting out now, make a portfolio and showcase some of the projects you have created, create an attractive resume to show your skills and personality and go get it !! You will fail, you will get rejected at the beginning....but this will help you to learn more and prepare you for the next interview. &lt;/p&gt;

&lt;p&gt;"In order to succeed you must have willing to fail"&lt;/p&gt;

&lt;p&gt;Good Luck :) &lt;/p&gt;

</description>
      <category>webdev</category>
      <category>career</category>
      <category>beginners</category>
      <category>programming</category>
    </item>
    <item>
      <title>Factorial In Javascript</title>
      <dc:creator>Margarita Vlachou</dc:creator>
      <pubDate>Wed, 25 Aug 2021 18:12:30 +0000</pubDate>
      <link>https://dev.to/mvlachou/factorial-in-javascript-3nna</link>
      <guid>https://dev.to/mvlachou/factorial-in-javascript-3nna</guid>
      <description>&lt;h3&gt;
  
  
  Factorial Formula
&lt;/h3&gt;

&lt;p&gt;The factorial function (symbol: !) says to multiply all whole numbers from our chosen number down to 1. &lt;/p&gt;

&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--uGdgZ5pl--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/3o09w83ejt8vbecp9npw.png" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--uGdgZ5pl--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/3o09w83ejt8vbecp9npw.png" alt="Alt Text"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;In general the formula has as shown below:&lt;/p&gt;

&lt;p&gt;&lt;b&gt; n! = n * (n-1) * (n-2) * .... * 2 * 1 &lt;/b&gt;&lt;/p&gt;

&lt;p&gt;If for example we would like to calculate the factorial of number 4 then we would have:&lt;/p&gt;

&lt;p&gt;4! = 4 * 3 * 2 * 1&lt;/p&gt;

&lt;h3&gt;
  
  
  Factorial in Javascript
&lt;/h3&gt;

&lt;p&gt;Here's how we would calculate the factorial in Javascript&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight javascript"&gt;&lt;code&gt;&lt;span class="kd"&gt;function&lt;/span&gt; &lt;span class="nx"&gt;FirstFactorial&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;num&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;     &lt;span class="c1"&gt;//consider our num=3&lt;/span&gt;
&lt;span class="nx"&gt;factorial&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="mi"&gt;1&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;span class="k"&gt;for&lt;/span&gt; &lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="kd"&gt;var&lt;/span&gt; &lt;span class="nx"&gt;i&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="mi"&gt;1&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt; &lt;span class="nx"&gt;i&lt;/span&gt;&lt;span class="o"&gt;&amp;lt;=&lt;/span&gt;&lt;span class="nx"&gt;num&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt; &lt;span class="nx"&gt;i&lt;/span&gt;&lt;span class="o"&gt;++&lt;/span&gt;&lt;span class="p"&gt;){&lt;/span&gt;        &lt;span class="c1"&gt;// loop from 1 to 3&lt;/span&gt;
  &lt;span class="nx"&gt;factorial&lt;/span&gt; &lt;span class="o"&gt;*=&lt;/span&gt; &lt;span class="nx"&gt;i&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;                  &lt;span class="c1"&gt;// and multiply with each number&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt; 

 &lt;span class="k"&gt;return&lt;/span&gt; &lt;span class="nx"&gt;factorial&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;                 &lt;span class="c1"&gt;//return the factorial which is &lt;/span&gt;
                                   &lt;span class="c1"&gt;// 3*2*1=6&lt;/span&gt;

&lt;span class="p"&gt;}&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



</description>
      <category>javascript</category>
      <category>codenewbie</category>
      <category>challenge</category>
    </item>
  </channel>
</rss>
