<?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: Yash Shah</title>
    <description>The latest articles on DEV Community by Yash Shah (@yashshah14093).</description>
    <link>https://dev.to/yashshah14093</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%2F389902%2F029eb2d6-1244-4189-b124-6fdace92f31a.png</url>
      <title>DEV Community: Yash Shah</title>
      <link>https://dev.to/yashshah14093</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://dev.to/feed/yashshah14093"/>
    <language>en</language>
    <item>
      <title>Class And Objects</title>
      <dc:creator>Yash Shah</dc:creator>
      <pubDate>Thu, 09 Jul 2020 18:12:24 +0000</pubDate>
      <link>https://dev.to/yashshah14093/class-and-objects-3802</link>
      <guid>https://dev.to/yashshah14093/class-and-objects-3802</guid>
      <description>&lt;p&gt;A &lt;strong&gt;Class&lt;/strong&gt; is a blueprint, template, or prototype that defines the variables and the methods common to all objects of the same kind. &lt;br&gt;
&lt;strong&gt;Object&lt;/strong&gt; acts as a member, specimen, or instance of the class.&lt;br&gt;
&lt;a href="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fi%2F8ymxw9fwclrj6lzux5w8.jpg" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fi%2F8ymxw9fwclrj6lzux5w8.jpg" alt="Alt Text"&gt;&lt;/a&gt;&lt;br&gt;
&lt;strong&gt;Objects&lt;/strong&gt; help programmers to use &lt;em&gt;variables&lt;/em&gt; and &lt;em&gt;methods&lt;/em&gt; as specified in the class.&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;Classes have logical existence and Objects have a physical existence.&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;Enough theory🥱, Let's take a real-world example of the laptop💻 on which you might be reading this tutorial:&lt;/p&gt;

&lt;p&gt;Take a laptop class has: &lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;variables(states): Brand, Operating System, Processor, and RAM&lt;/li&gt;
&lt;li&gt;methods(behavior): start, restart and shutdown
&lt;img src="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fi%2Frro6k046jqez7ipdet1r.JPG" alt="Alt Text"&gt;
&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Now, Let's real objects i.e real Laptops which follow the same blueprint as specified in the laptop class:&lt;/p&gt;

&lt;p&gt;Object LAP-01:&lt;a href="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fi%2Fvrkzio02tv6ynmfv4xpi.JPG" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fi%2Fvrkzio02tv6ynmfv4xpi.JPG" alt="Alt Text"&gt;&lt;/a&gt;&lt;br&gt;
Object LAP-02:&lt;a href="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fi%2F0hdrf86vc9n3ngnoiyog.JPG" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fi%2F0hdrf86vc9n3ngnoiyog.JPG" alt="Alt Text"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Taking look at these two objects: LAP-01 and LAP-02, You will observe that they have differences but they share the same prototype as specified in the parent class.&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;Thus, &lt;strong&gt;Class&lt;/strong&gt; is a sketch while &lt;strong&gt;Object&lt;/strong&gt; is the same sketch of a parent class with different colors.&lt;/p&gt;
&lt;/blockquote&gt;

</description>
      <category>oop</category>
      <category>computerscience</category>
      <category>codenewbie</category>
      <category>tutorial</category>
    </item>
    <item>
      <title>What is OOP...?</title>
      <dc:creator>Yash Shah</dc:creator>
      <pubDate>Sun, 05 Jul 2020 18:39:27 +0000</pubDate>
      <link>https://dev.to/yashshah14093/what-is-oop-4ha9</link>
      <guid>https://dev.to/yashshah14093/what-is-oop-4ha9</guid>
      <description>&lt;p&gt;Starting with a basic question...&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;Why do we need programming..???&lt;br&gt;
✔To design Software Applications that help in solving real-world problems.&lt;br&gt;
&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--cj20lfRs--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://res.cloudinary.com/practicaldev/image/fetch/s--_HBZhuhF--/c_limit%252Cf_auto%252Cfl_progressive%252Cq_auto%252Cw_880/https://thepracticaldev.s3.amazonaws.com/i/nweeqf97l2md3tlqkjyt.jpg" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--cj20lfRs--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://res.cloudinary.com/practicaldev/image/fetch/s--_HBZhuhF--/c_limit%252Cf_auto%252Cfl_progressive%252Cq_auto%252Cw_880/https://thepracticaldev.s3.amazonaws.com/i/nweeqf97l2md3tlqkjyt.jpg" alt="alt text" title="Programming"&gt;&lt;/a&gt;&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;One question More...🧐&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;How can we handle thousands/millions of lines of code of those complex software applications solving problems...?🙄&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;So, here comes the Object-Oriented Programming Paradigm...&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;The object-oriented model makes it easy to build up programs by accretion. What this often means, in practice, is that it provides a structured way to write spaghetti code.&lt;br&gt;
--&lt;strong&gt;&lt;em&gt;Paul Graham&lt;/em&gt;&lt;/strong&gt;&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;&lt;strong&gt;Object-Oriented Programming(OOP)&lt;/strong&gt; refers to the art of decomposing an application into a number of software objects that work together.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;What are Software objects?&lt;/strong&gt;&lt;br&gt;
Take real-world objects to share two characteristics:&lt;br&gt;
&lt;strong&gt;1.&lt;/strong&gt;they all have state and,&lt;br&gt;
&lt;strong&gt;2.&lt;/strong&gt;they all have behavior. &lt;br&gt;
For example, dogs have state (name, color, breed, hungry) and dogs have behavior (barking, fetching, and slobbering on your newly cleaned slacks).&lt;br&gt;
&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--E0aKDTF2--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://encrypted-tbn0.gstatic.com/images%3Fq%3Dtbn%253AANd9GcS-H4QqXST_JsWyn4NQ1GxgcYw6fQd-bolfoA%26usqp%3DCAU" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--E0aKDTF2--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://encrypted-tbn0.gstatic.com/images%3Fq%3Dtbn%253AANd9GcS-H4QqXST_JsWyn4NQ1GxgcYw6fQd-bolfoA%26usqp%3DCAU" alt="alt text" title="Dog"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Software objects are modeled after real-world objects in that they, too, have state and behavior. A software object maintains its state in variables and implements its behavior with methods.&lt;br&gt;
&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--2VFYzgVG--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_66%2Cw_880/http://journals.ecs.soton.ac.uk/java/tutorial/java/objects/images/object_trans.gif" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--2VFYzgVG--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_66%2Cw_880/http://journals.ecs.soton.ac.uk/java/tutorial/java/objects/images/object_trans.gif" alt="alt text" title="Object"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;In a Software Application,&lt;br&gt;
Objects communicate with each other by sending&lt;br&gt;
messages to each other. &lt;/p&gt;

&lt;p&gt;For e.g., a Circle object &lt;br&gt;
Data will be a center (x and y coordinates) and the radius. &lt;br&gt;
This object will have methods to be able to set its center coordinates or its radius, and report its radius to other object.&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;Thus, &lt;strong&gt;&lt;em&gt;Object-oriented programming (OOP) is a computer programming model that organizes software design around data, or objects.&lt;/em&gt;&lt;/strong&gt; An object can be defined as a data field that has unique variables and methods.&lt;/p&gt;
&lt;/blockquote&gt;

</description>
      <category>oop</category>
      <category>computerscience</category>
      <category>codequality</category>
      <category>codenewbie</category>
    </item>
  </channel>
</rss>
