<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en">
		<id>http://wiki.karljones.com/index.php?action=history&amp;feed=atom&amp;title=Instance_variable</id>
		<title>Instance variable - Revision history</title>
		<link rel="self" type="application/atom+xml" href="http://wiki.karljones.com/index.php?action=history&amp;feed=atom&amp;title=Instance_variable"/>
		<link rel="alternate" type="text/html" href="http://wiki.karljones.com/index.php?title=Instance_variable&amp;action=history"/>
		<updated>2026-10-23T16:22:57Z</updated>
		<subtitle>Revision history for this page on the wiki</subtitle>
		<generator>MediaWiki 1.24.2</generator>

	<entry>
		<id>http://wiki.karljones.com/index.php?title=Instance_variable&amp;diff=17767&amp;oldid=prev</id>
		<title>Karl Jones at 16:06, 4 September 2016</title>
		<link rel="alternate" type="text/html" href="http://wiki.karljones.com/index.php?title=Instance_variable&amp;diff=17767&amp;oldid=prev"/>
				<updated>2016-09-04T16:06:39Z</updated>
		
		<summary type="html">&lt;p&gt;&lt;/p&gt;
&lt;table class='diff diff-contentalign-left'&gt;
				&lt;col class='diff-marker' /&gt;
				&lt;col class='diff-content' /&gt;
				&lt;col class='diff-marker' /&gt;
				&lt;col class='diff-content' /&gt;
				&lt;tr style='vertical-align: top;'&gt;
				&lt;td colspan='2' style=&quot;background-color: white; color:black; text-align: center;&quot;&gt;← Older revision&lt;/td&gt;
				&lt;td colspan='2' style=&quot;background-color: white; color:black; text-align: center;&quot;&gt;Revision as of 16:06, 4 September 2016&lt;/td&gt;
				&lt;/tr&gt;&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;Line 3:&lt;/td&gt;
&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;Line 3:&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;An instance variable is similar to, but not to be confuse with, a [[class variable]].&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;An instance variable is similar to, but not to be confuse with, a [[class variable]].&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;−&lt;/td&gt;&lt;td style=&quot;color:black; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #ffe49c; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;An instance variable is not a class variable although there are similarities. It is a type of class attribute (or class property, field, or data member). The same dichotomy between instance and class members applies to methods (&amp;quot;member functions&amp;quot;) as well; a class may have both instance methods and class methods.&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;+&lt;/td&gt;&lt;td style=&quot;color:black; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;An instance variable is not a class variable although there are similarities. It is a type of &lt;ins class=&quot;diffchange diffchange-inline&quot;&gt;[[&lt;/ins&gt;class attribute&lt;ins class=&quot;diffchange diffchange-inline&quot;&gt;]] &lt;/ins&gt;(or class property, field, or data member). The same dichotomy between instance and class members applies to methods (&amp;quot;member functions&amp;quot;) as well; a class may have both instance methods and class methods.&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;Each class variable and instance variable you invoke with the object lives in memory for the life of that object.&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;Each class variable and instance variable you invoke with the object lives in memory for the life of that object.&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;/table&gt;</summary>
		<author><name>Karl Jones</name></author>	</entry>

	<entry>
		<id>http://wiki.karljones.com/index.php?title=Instance_variable&amp;diff=17766&amp;oldid=prev</id>
		<title>Karl Jones: Created page with &quot;In object-oriented programming with classes, an '''instance variable''' is a variable defined in a class (i.e. a member variable), for...&quot;</title>
		<link rel="alternate" type="text/html" href="http://wiki.karljones.com/index.php?title=Instance_variable&amp;diff=17766&amp;oldid=prev"/>
				<updated>2016-09-04T16:05:39Z</updated>
		
		<summary type="html">&lt;p&gt;Created page with &amp;quot;In &lt;a href=&quot;/index.php/Object-oriented_programming&quot; title=&quot;Object-oriented programming&quot;&gt;object-oriented programming&lt;/a&gt; with classes, an &amp;#039;&amp;#039;&amp;#039;instance variable&amp;#039;&amp;#039;&amp;#039; is a &lt;a href=&quot;/index.php/Variable_(computer_science)&quot; title=&quot;Variable (computer science)&quot;&gt;variable&lt;/a&gt; defined in a class (i.e. a &lt;a href=&quot;/index.php/Member_variable&quot; title=&quot;Member variable&quot;&gt;member variable&lt;/a&gt;), for...&amp;quot;&lt;/p&gt;
&lt;p&gt;&lt;b&gt;New page&lt;/b&gt;&lt;/p&gt;&lt;div&gt;In [[object-oriented programming]] with classes, an '''instance variable''' is a [[Variable (computer science)|variable]] defined in a class (i.e. a [[member variable]]), for which each instantiated [[Object (computer science)|object]] of the class has a separate copy, or instance.&lt;br /&gt;
&lt;br /&gt;
An instance variable is similar to, but not to be confuse with, a [[class variable]].&lt;br /&gt;
&lt;br /&gt;
An instance variable is not a class variable although there are similarities. It is a type of class attribute (or class property, field, or data member). The same dichotomy between instance and class members applies to methods (&amp;quot;member functions&amp;quot;) as well; a class may have both instance methods and class methods.&lt;br /&gt;
&lt;br /&gt;
Each class variable and instance variable you invoke with the object lives in memory for the life of that object.&lt;br /&gt;
&lt;br /&gt;
Variables are properties an object knows about itself. All instances of an object have their own copies of instance variables, even if the value is the same from one object to another. One object instance can change values of its instance variables without affecting all other instances. Instance variables can be used by all methods of a class unless the method is declared as static.&lt;br /&gt;
&lt;br /&gt;
== See also ==&lt;br /&gt;
&lt;br /&gt;
* [[Class variable]] - not to be confused with&lt;br /&gt;
&lt;br /&gt;
== External links ==&lt;br /&gt;
&lt;br /&gt;
* [https://en.wikipedia.org/wiki/Instance_variable Instance variable] @ Wikipedia.org &lt;br /&gt;
&lt;br /&gt;
[[Category:Computer programming]]&lt;br /&gt;
[[Category:Computer science]]&lt;br /&gt;
[[Category:Computing]]&lt;/div&gt;</summary>
		<author><name>Karl Jones</name></author>	</entry>

	</feed>