<?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: acobbina717</title>
    <description>The latest articles on DEV Community by acobbina717 (@acobbina717).</description>
    <link>https://dev.to/acobbina717</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.us-east-2.amazonaws.com%2Fuploads%2Fuser%2Fprofile_image%2F875337%2Fdee8af30-12d8-4fb1-84bb-b99222ca2292.png</url>
      <title>DEV Community: acobbina717</title>
      <link>https://dev.to/acobbina717</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://dev.to/feed/acobbina717"/>
    <language>en</language>
    <item>
      <title>javaScript?.Fundamentals</title>
      <dc:creator>acobbina717</dc:creator>
      <pubDate>Mon, 15 Aug 2022 16:43:00 +0000</pubDate>
      <link>https://dev.to/acobbina717/javascript-fundamentals-4p8h</link>
      <guid>https://dev.to/acobbina717/javascript-fundamentals-4p8h</guid>
      <description>&lt;p&gt;Here’s a few things to know when getting started with Javascript&lt;/p&gt;

&lt;h2&gt;
  
  
  Variables
&lt;/h2&gt;

&lt;p&gt;Variables are used to store data, like the price of a item&lt;/p&gt;

&lt;p&gt;&lt;code&gt;let&lt;/code&gt; and &lt;code&gt;const&lt;/code&gt; are used to declare variables&lt;/p&gt;

&lt;p&gt;Variables declared with &lt;code&gt;const&lt;/code&gt; can not be updated later in your code, variables declared with &lt;code&gt;let&lt;/code&gt; can be updated throughout your code.&lt;br&gt;
Use &lt;code&gt;const&lt;/code&gt; to store data you don’t expect to change, like your first name&lt;/p&gt;

&lt;h2&gt;
  
  
  Console Log
&lt;/h2&gt;

&lt;p&gt;&lt;code&gt;console.log&lt;/code&gt; is used to view data in the terminal. &lt;code&gt;console.log&lt;/code&gt; will be your best friend when you run into bugs. You will have the ability to log variables into the terminal to see where the error is coming from     &lt;/p&gt;

&lt;h2&gt;
  
  
  What type of data can be stored in a variable?
&lt;/h2&gt;

&lt;p&gt;JavaScript has 7 primitive data types &amp;amp; 1 non primitive data type&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;String&lt;/strong&gt; &lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;A sequence of text wrapped around double quotes: "", single quotes: '', or backticks: ``&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--lIqFEKiz--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/68nchpg26rud59o56ynz.jpeg" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--lIqFEKiz--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/68nchpg26rud59o56ynz.jpeg" alt="string" width="880" height="617"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;&lt;em&gt;If you’re storing a string with double quotes within, use single quotes or backticks&lt;/em&gt;&lt;/p&gt;

&lt;p&gt;You can also add other variables into a string using string interpolation. To use string interpolation you must &lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;wrap your string in backticks&lt;/li&gt;
&lt;li&gt;add a dollar sign&lt;/li&gt;
&lt;li&gt;add curly braces&lt;/li&gt;
&lt;li&gt;write your variable inside of the curly braces &lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--BVcJ9hlQ--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/83gpjcjq8xeyxy3h5l37.jpeg" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--BVcJ9hlQ--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/83gpjcjq8xeyxy3h5l37.jpeg" alt="String Interpolation" width="880" height="470"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Number&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;A number is just a number, numbers do not need to be wrapped in quotes like a string.&lt;/li&gt;
&lt;li&gt;Decimal numbers are called &lt;code&gt;floats&lt;/code&gt;
&lt;/li&gt;
&lt;/ul&gt;

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

&lt;p&gt;&lt;strong&gt;Boolean&lt;/strong&gt; &lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;True or False.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--GW7pcyO_--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/r38ibtrycf4ti88p3wvh.jpeg" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--GW7pcyO_--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/r38ibtrycf4ti88p3wvh.jpeg" alt="boolean" width="880" height="344"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;&lt;code&gt;undefined&lt;/code&gt;&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Variables declared with no value will be &lt;code&gt;undefined&lt;/code&gt;.&lt;/li&gt;
&lt;li&gt;Variables declared with &lt;code&gt;undefined&lt;/code&gt; will have a value of undefined&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--0Zvd8tfo--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/3cy55a4jire6ablqwfmm.jpeg" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--0Zvd8tfo--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/3cy55a4jire6ablqwfmm.jpeg" alt="undefined" width="772" height="328"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;&lt;code&gt;null&lt;/code&gt;&lt;/strong&gt;  &lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;&lt;p&gt;An empty or a unknown value&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;Unlike the undefined keyword we are defining a variable with a value of nothing.&lt;/p&gt;&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--Gqcxallp--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/mfb0xhm28jxnes73xfhc.jpeg" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--Gqcxallp--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/mfb0xhm28jxnes73xfhc.jpeg" alt="null" width="772" height="280"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;&lt;a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/BigInt"&gt;Bigint&lt;/a&gt;&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt; A number too larger to be stored in javascript's number data types&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;&lt;a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Symbol"&gt;Symbol&lt;/a&gt;&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;A value that is unique and unchangeable&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  Non primitive data types / Collections of data
&lt;/h2&gt;

&lt;p&gt;&lt;strong&gt;Object&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;&lt;p&gt;Objects are written with curly brackets and hold {&lt;code&gt;key&lt;/code&gt; : &lt;code&gt;value&lt;/code&gt;} pairs.. &lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;An object's &lt;code&gt;key&lt;/code&gt; is known as the property (the title of the &lt;code&gt;value&lt;/code&gt; its attached to)&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;code&gt;value&lt;/code&gt; can &lt;code&gt;=&lt;/code&gt; any javascript data type | primitives and non primitives&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;We can use Dot Notation to access a objects property and we will get the &lt;code&gt;value&lt;/code&gt; in return - ex: &lt;code&gt;object.property&lt;/code&gt;&lt;/p&gt;&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--idiD9eFy--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/uoqfy8sv70qt4qajz57u.jpeg" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--idiD9eFy--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/uoqfy8sv70qt4qajz57u.jpeg" alt="objects" width="444" height="360"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Array&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Arrays are "list-like" objects that store multiple data types into a collection&lt;/li&gt;
&lt;li&gt;Arrays are written with brackets &lt;code&gt;[]&lt;/code&gt; and hold multiple data types that are separated by commas &lt;code&gt;[1,"a",true,null]&lt;/code&gt;
&lt;/li&gt;
&lt;li&gt;Data in a array can be accessed individually by its index (numbered position in a list, javascript counts from 0) using bracket notation - ex: &lt;code&gt;array[0]&lt;/code&gt;
&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--YpcSx15m--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/xuogalfe9ewk6c63p0pi.jpeg" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--YpcSx15m--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/xuogalfe9ewk6c63p0pi.jpeg" alt="arrays" width="784" height="736"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  Operators
&lt;/h2&gt;

&lt;ul&gt;
&lt;li&gt;Operators are symbols used to preform operations on values and variables.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;Assignment Operator&lt;/strong&gt;: &lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Used to assign values to variables  &lt;code&gt;=&lt;/code&gt; &lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;Arithmetic Operators&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Used to preform arithmetic calculations&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--1tZPn5gQ--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/eryvfnijm1zz96njjpyg.png" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--1tZPn5gQ--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/eryvfnijm1zz96njjpyg.png" alt="arithmeticOperators" width="880" height="521"&gt;&lt;/a&gt;&lt;/p&gt;

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

&lt;p&gt;Using &lt;code&gt;+=&lt;/code&gt; or any arithmetic, assignment operator combination pair will update our initial variables value &lt;code&gt;+=&lt;/code&gt; &lt;code&gt;-=&lt;/code&gt; &lt;code&gt;*=&lt;/code&gt; &lt;code&gt;/=&lt;/code&gt; &lt;code&gt;%=&lt;/code&gt;&lt;/p&gt;

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

&lt;p&gt;&lt;strong&gt;Comparison operators&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Used in logical statements to determine equality of values or variables, returns a true or false boolean value&lt;/li&gt;
&lt;/ul&gt;

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

&lt;ul&gt;
&lt;li&gt;The equal to operator (==) will convert strings into numbers and compare values regardless of data type&lt;/li&gt;
&lt;li&gt;The strictly equal to operator(===) will only return true if both values are equal and have equal date types&lt;/li&gt;
&lt;li&gt;The not equal to operator(!=) will n
&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--2Wbzyp7e--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/zh725z9wa9zkdgaj7i5w.png" alt="comparisonOperators" width="880" height="528"&gt;
&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--1URy2IW7--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/2htrwxbv49yxmw0yyndg.png" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--1URy2IW7--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/2htrwxbv49yxmw0yyndg.png" alt="comparisonOperatorsTerminal" width="662" height="924"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Logical Operators&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Used to determine the true or false logic between variables and values
&lt;code&gt;(&amp;amp;&amp;amp;) , (||), (!)&lt;/code&gt;
&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--21T4LIX_--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/0jm8f1kkp689dx4omoaz.png" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--21T4LIX_--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/0jm8f1kkp689dx4omoaz.png" alt="logicalOperators" width="848" height="304"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;both values on each side of the and operator must be true for us to get a return value of true
&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--mXflVrLP--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/rhh3v9eocqnt61b4fgk6.png" alt="addOperator" width="876" height="620"&gt;
&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--ogIsabYZ--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/m5tpo567xixnvhfnwvlq.png" alt="orOperator" width="880" height="689"&gt;
&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--5cbroNip--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/m7sa2tc4mg8l2tvbongj.png" alt="bangOperator" width="880" height="689"&gt;
&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;String Operators&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Add strings together. We can combine two strings into one using the &lt;code&gt;+&lt;/code&gt; operator or the &lt;code&gt;+=&lt;/code&gt; operator&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;JAVASCRIPT FUNDAMENTALS PART 2... COMING SOON&lt;/strong&gt;&lt;/p&gt;

</description>
      <category>javascript</category>
      <category>beginners</category>
      <category>tutorial</category>
    </item>
    <item>
      <title>Javascript Type Conversion in 3 mins</title>
      <dc:creator>acobbina717</dc:creator>
      <pubDate>Fri, 22 Jul 2022 20:37:00 +0000</pubDate>
      <link>https://dev.to/acobbina717/javascript-type-conversion-1fc7</link>
      <guid>https://dev.to/acobbina717/javascript-type-conversion-1fc7</guid>
      <description>&lt;p&gt;I thought it might be cool to share with you how Javascript converts its primitive data types.&lt;br&gt;
This is a high level overview of Javascript Type Conversion. After reading this blog you will have a better understanding of how javascript converts its data types &lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Type Conversion&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Converting one data type to another ( Number to a String or String to a Number )&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;In Javascript there are two types of type conversion that happens, implicit conversion and explicit conversion. Let's go over both type of conversions. &lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Implicit Conversion&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Javascript automatically converts data types without us telling it to.&lt;/li&gt;
&lt;li&gt;Preforming arithmetic operations on two different data types with cause Javascript to convert the data types so it returns a valid value.&lt;/li&gt;
&lt;li&gt;When using the &lt;code&gt;+&lt;/code&gt; operator  with a string and another data type, Javascript will convert both data types into strings and give a return value of a string.
&lt;/li&gt;
&lt;/ul&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;console.log(5 + "5"); =&amp;gt; "55"
console.log(true + "false"); =&amp;gt; "truefalse"
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;ul&gt;
&lt;li&gt;When using the &lt;code&gt;| - | * | / | % |&lt;/code&gt; operators Javascript will try to convert both data types into numbers
&lt;/li&gt;
&lt;/ul&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;console.log(1 * "2"); =&amp;gt; 2
console.log(5 * "5"); =&amp;gt; 25
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;ul&gt;
&lt;li&gt;If a data type cant be converted into a number, Javascript will return &lt;code&gt;NaN (Not A Number)&lt;/code&gt; as a return value
&lt;/li&gt;
&lt;/ul&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;console.log(1 * "true"); =&amp;gt; NaN
console.log(0 / false); =&amp;gt; NaN
console.log(true % "false"); =&amp;gt; NaN
console.log(1 * undefined); =&amp;gt; NaN
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;ul&gt;
&lt;li&gt;When the boolean value of true is converted into a number, it has the value of 1
&lt;/li&gt;
&lt;/ul&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;console.log(0 + true); =&amp;gt; 1
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;ul&gt;
&lt;li&gt;The boolean value false is converted into a number, it has the value of 0
&lt;/li&gt;
&lt;/ul&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;console.log(1 * false); =&amp;gt; 0
console.log("14", true + false); =&amp;gt; 1
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;ul&gt;
&lt;li&gt;
&lt;code&gt;null&lt;/code&gt; also has the value of 0
&lt;/li&gt;
&lt;/ul&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;console.log(1 * null); =&amp;gt; 0
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;ul&gt;
&lt;li&gt;Any number divided by 0 equals infinity
&lt;/li&gt;
&lt;/ul&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;console.log(12 / false); =&amp;gt; Infinity
console.log(true / false); =&amp;gt; Infinity
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;ul&gt;
&lt;li&gt;Using equality operators will cause Javascript to convert data types&lt;/li&gt;
&lt;li&gt;The &lt;code&gt;==&lt;/code&gt; equals to operator compares both values and converts both data types into numbers&lt;/li&gt;
&lt;li&gt;The &lt;code&gt;===&lt;/code&gt; strictly equals to operator compares both values but does not convert data types
&lt;/li&gt;
&lt;/ul&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;console.log(7 == "7"); =&amp;gt; true
console.log(7 == "8"); =&amp;gt; false
console.log(7 === 7); =&amp;gt; true
console.log(7 === "7"); =&amp;gt; false
console.log(7 === "8"); =&amp;gt; false
console.log("true" == true); =&amp;gt; false
console.log("true" === true); =&amp;gt; false
console.log(true == 1); =&amp;gt; true
console.log(true === 1); =&amp;gt; false
console.log(null == undefined); =&amp;gt; true
console.log(null === undefined); =&amp;gt;false
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;&lt;strong&gt;Explicit Conversion&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Manually Converting Data Types&lt;/li&gt;
&lt;li&gt;The &lt;code&gt;Number()&lt;/code&gt; method converts string and boolean values into numbers. If a string contains any text, javascript will return &lt;code&gt;NaN&lt;/code&gt;
&lt;/li&gt;
&lt;/ul&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;console.log(Number("")); =&amp;gt; 0
console.log(Number("Halo 3")); =&amp;gt; NaN
console.log(Number("5")); =&amp;gt; 5
console.log(Number(true)); =&amp;gt; 1
console.log(Number(false)); =&amp;gt; 0
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;ul&gt;
&lt;li&gt;The &lt;code&gt;parseInt()&lt;/code&gt; method converts string values into whole numbers. &lt;code&gt;parseInt()&lt;/code&gt; is a string method. It returns an error when used with other data types. If a string holds text and numbers, we can extract the numbers in a string only if the number is at the beginning of the string. If the number is not at the beginning of the string, we get a return value of &lt;code&gt;NaN&lt;/code&gt; NotaNumber
&lt;/li&gt;
&lt;/ul&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;console.log(parseInt("12")); =&amp;gt; 12
console.log(parseInt("12.5")); =&amp;gt; 12
console.log(parseInt(true)); =&amp;gt; NaN
console.log(parseInt("true")); =&amp;gt; NaN
console.log(parseInt("true12")); =&amp;gt; NaN
console.log(parseInt("12true12")); =&amp;gt; 12
console.log(parseInt(null)); =&amp;gt; NaN
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;ul&gt;
&lt;li&gt;The &lt;code&gt;parseFloat()&lt;/code&gt; method is similar to the &lt;code&gt;parseInt()&lt;/code&gt; method except it is used to convert strings that hold decimal numbers into floats.
&lt;/li&gt;
&lt;/ul&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;console.log(parseFloat("12.5")); =&amp;gt; 12.5
console.log(parseFloat("2.5Hello")); =&amp;gt; 2.5
console.log(parseFloat("2.5 Hello")); =&amp;gt; 2.5
console.log(parseFloat("Hello2.5")); =&amp;gt; NaN
console.log(parseFloat("Hello 2.5")); =&amp;gt; NaN
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;ul&gt;
&lt;li&gt;The &lt;code&gt;String()&lt;/code&gt; method and &lt;code&gt;.toString()&lt;/code&gt; method converts primitive data types into strings
&lt;/li&gt;
&lt;/ul&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;console.log(String(12)); =&amp;gt; "12"
console.log(String(true)); =&amp;gt; "true"
console.log(String(3.41)); =&amp;gt; "3.14"
console.log((88).toString()); =&amp;gt; "88"
console.log(true.toString()); =&amp;gt; "true"
console.log((22.1).toString()); =&amp;gt; "22.1"
console.log((12345678).toString()); =&amp;gt; "12345678"
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;ul&gt;
&lt;li&gt;The &lt;code&gt;Boolean()&lt;/code&gt; method converts primitive data types into boolean values&lt;/li&gt;
&lt;li&gt;Positive &amp;amp; Negative numbers have a true value&lt;/li&gt;
&lt;li&gt;0 and empty strings have a false value&lt;/li&gt;
&lt;li&gt;Strings with text or numbers have true value&lt;/li&gt;
&lt;li&gt;null &amp;amp; undefined has a false value
&lt;/li&gt;
&lt;/ul&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;console.log(Boolean(3)); =&amp;gt; true
console.log(Boolean(0)); =&amp;gt; false
console.log(Boolean(-1)); =&amp;gt; true
console.log(Boolean(-10)); =&amp;gt; true
console.log(Boolean("")); =&amp;gt; false
console.log(Boolean("ghjk")); =&amp;gt; true
console.log(Boolean("56789")); =&amp;gt; true
console.log(Boolean(null)); =&amp;gt; false
console.log(Boolean(undefined)); =&amp;gt; false
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



</description>
    </item>
  </channel>
</rss>
