<?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: Marmot</title>
    <description>The latest articles on DEV Community by Marmot (@codandcode).</description>
    <link>https://dev.to/codandcode</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%2F379506%2Fe59b28f3-fb5b-4922-9d8f-2207b3340c88.jpg</url>
      <title>DEV Community: Marmot</title>
      <link>https://dev.to/codandcode</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://dev.to/feed/codandcode"/>
    <language>en</language>
    <item>
      <title>Stuck while learning ruby on rails</title>
      <dc:creator>Marmot</dc:creator>
      <pubDate>Thu, 19 Aug 2021 17:17:01 +0000</pubDate>
      <link>https://dev.to/codandcode/stuck-while-learning-ruby-on-rails-1lod</link>
      <guid>https://dev.to/codandcode/stuck-while-learning-ruby-on-rails-1lod</guid>
      <description>&lt;p&gt;Hi all,&lt;/p&gt;

&lt;p&gt;I'm learning ruby now and I have this exercise on which I'm stuck but can't figure out why. The picture says it all. I'm supposed to write a loop, it's supposed to end by "end" which it does but I get the error message that a keyword_end is expected.... I tried everything I could think of so now I'm asking help to see what I'm missing.&lt;/p&gt;

&lt;p&gt;Take care all and thanks for your help.&lt;/p&gt;

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

</description>
      <category>ruby</category>
      <category>learning</category>
      <category>help</category>
      <category>codecademy</category>
    </item>
    <item>
      <title>Install git on mac through terminal</title>
      <dc:creator>Marmot</dc:creator>
      <pubDate>Wed, 03 Jun 2020 10:59:00 +0000</pubDate>
      <link>https://dev.to/codandcode/install-git-on-mac-through-terminal-1lf2</link>
      <guid>https://dev.to/codandcode/install-git-on-mac-through-terminal-1lf2</guid>
      <description>

</description>
      <category>git</category>
      <category>help</category>
      <category>terminal</category>
      <category>mac</category>
    </item>
    <item>
      <title>How to cd to a directory with a space in the name? </title>
      <dc:creator>Marmot</dc:creator>
      <pubDate>Sun, 24 May 2020 15:52:01 +0000</pubDate>
      <link>https://dev.to/codandcode/how-to-cd-to-a-directory-with-a-space-in-the-name-3dn0</link>
      <guid>https://dev.to/codandcode/how-to-cd-to-a-directory-with-a-space-in-the-name-3dn0</guid>
      <description>&lt;p&gt;Hi, I'm trying to navigate my folders using terminal and want to go into a folder called 'Front end'. I googled and found 2 solutions :&lt;/p&gt;

&lt;p&gt;-Put quotes around the directory name. (cd ~/"Front end"/) &lt;br&gt;
-Escape the directory name with a backslash (cd ~/Front\ end/)&lt;/p&gt;

&lt;p&gt;None of these solutions work for me. Am I missing something?&lt;/p&gt;

&lt;p&gt;Thanks for help.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://dev-to-uploads.s3.amazonaws.com/i/8fksvb5za17363gsjrgh.png"&gt;https://dev-to-uploads.s3.amazonaws.com/i/8fksvb5za17363gsjrgh.png&lt;/a&gt;&lt;/p&gt;

</description>
      <category>terminal</category>
      <category>help</category>
    </item>
    <item>
      <title>Can someone explain that logic to me? </title>
      <dc:creator>Marmot</dc:creator>
      <pubDate>Wed, 06 May 2020 10:36:11 +0000</pubDate>
      <link>https://dev.to/codandcode/can-someone-explain-that-logic-to-me-4d3k</link>
      <guid>https://dev.to/codandcode/can-someone-explain-that-logic-to-me-4d3k</guid>
      <description>&lt;p&gt;Hi I'm following a Webdev Course on udemy. As an exercise we had to identify a missing number from an array and so the solution was like this :&lt;/p&gt;

&lt;p&gt;var numbers = [4, 8, 9, 12, 19, 7, 3, 15, 2, 17, 20, 1, 11, 5, 10, 13, 16, 14, 18]&lt;/p&gt;

&lt;p&gt;function missingno(numbers){&lt;/p&gt;

&lt;p&gt;var missing = - 1&lt;/p&gt;

&lt;p&gt;for (var i=0; i &amp;lt;= numbers. length; i++){&lt;/p&gt;

&lt;div class="highlight"&gt;&lt;pre class="highlight plaintext"&gt;&lt;code&gt;if(numbers.indexOf(i) === - 
1){
 missing = i
}
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;

&lt;p&gt;} &lt;br&gt;
  return missing&lt;br&gt;
} &lt;/p&gt;

&lt;p&gt;console.log(missingno(numbers))&lt;/p&gt;

&lt;p&gt;I don't understand why the index of the missing numbers is - 1. Is it a rule? or is there a mathematical logic to it? And if so, what would be that logic?&lt;/p&gt;

&lt;p&gt;My brain is smoking right now. &lt;/p&gt;

&lt;p&gt;If anyone can take the time to explain, it would be greatly appreciated.&lt;/p&gt;

&lt;p&gt;Peace! &lt;/p&gt;

</description>
      <category>help</category>
      <category>javascript</category>
      <category>logic</category>
    </item>
  </channel>
</rss>
