<?xml version="1.0" encoding="utf-8"?>

<rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:content="http://purl.org/rss/1.0/modules/content/">
	<channel>
		<title>DaniWeb IT Discussion Community</title>
		<link>http://www.daniweb.com/forums/</link>
		<description>Tech support, programming, web development, and internet marketing community. Forums to get free computer help and support.</description>
		<language>en-US</language>
		<lastBuildDate>Wed, 16 Dec 2009 08:01:39 GMT</lastBuildDate>
		<generator>vBulletin</generator>
		<ttl>60</ttl>
		<image>
			<url>http://www.daniweb.com/alphaimages/misc/rss.jpg</url>
			<title>DaniWeb IT Discussion Community</title>
			<link>http://www.daniweb.com/forums/</link>
		</image>
		<item>
			<title>Curious working with objects</title>
			<link>http://www.daniweb.com/forums/thread227305.html</link>
			<pubDate>Fri, 02 Oct 2009 21:19:52 GMT</pubDate>
			<description><![CDATA[struct Table 
{ 
char* aTag; 
char* bTag; 
}; 
int main() 
{ 
Table T1; 
cout<<T1.aTag; 
cout<<T1.bTag;]]></description>
			<content:encoded><![CDATA[<div> <pre style="margin:20px; line-height:13px">struct Table<br />
{<br />
char* aTag;<br />
char* bTag;<br />
};<br />
int main()<br />
{<br />
Table T1;<br />
cout&lt;&lt;T1.aTag;<br />
cout&lt;&lt;T1.bTag;<br />
return 0;<br />
}</pre><br />
This might be crazy but... i really need to know<br />
is there any way to so that we can only write <br />
 <pre style="margin:20px; line-height:13px">cout&lt;&lt;aTag <br />
cout&lt;&lt;bTag</pre>instead of  <pre style="margin:20px; line-height:13px">T1.aTag</pre> like we do in  <pre style="margin:20px; line-height:13px">namespace</pre>by  <pre style="margin:20px; line-height:13px">using namespace &lt;something&gt;</pre> for a block.<br />
Can in be done for pointers  <pre style="margin:20px; line-height:13px">T1-&gt;aTag</pre>.<br />
I tried something but have to write each of them for different object...</div> ]]></content:encoded>
			<category domain="http://www.daniweb.com/forums/forum8.html">C++</category>
			<dc:creator>Rhohitman</dc:creator>
			<guid isPermaLink="true">http://www.daniweb.com/forums/thread227305.html</guid>
		</item>
		<item>
			<title>Dynamic Memory allocation</title>
			<link>http://www.daniweb.com/forums/thread227285.html</link>
			<pubDate>Fri, 02 Oct 2009 18:36:47 GMT</pubDate>
			<description><![CDATA[01 Why i am not able to do this  
  <div class="codeblock"> <div class="spaced"> <div style="float:right; margin-right:10px"> <a href="/forums/misc.php?do=explaincode&amp;TB_iframe=true&amp;height=400&amp;width=680" class="thickbox" title="Help with Code Tags" target="_blank">Help with Code Tags</a> </div>...]]></description>
			<content:encoded><![CDATA[<div>01 Why i am not able to do this <br />
 <pre style="margin:20px; line-height:13px">int* px;<br />
px = new int[2][2];</pre>other the   <pre style="margin:20px; line-height:13px">px = new int[2*2];</pre>is there any other method<br />
<br />
02 Why i am not able do access through pointer dx by  <pre style="margin:20px; line-height:13px">dx[1][2]</pre> other than by using  <pre style="margin:20px; line-height:13px">dx[1*7+2]</pre><br />
 <pre style="margin:20px; line-height:13px">static float mat&#91;5&#93;&#91;7&#93; =<br />
&nbsp; &nbsp; &nbsp; &nbsp; {<br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; -5, -4,&nbsp; 0,&nbsp; 0,&nbsp; 0,&nbsp; 0,&nbsp; 0,<br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;  6,&nbsp; 4,&nbsp; 1,&nbsp; 0,&nbsp; 0,&nbsp; 0, 24,<br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;  1,&nbsp; 2,&nbsp; 0,&nbsp; 1,&nbsp; 0,&nbsp; 0,&nbsp; 6,<br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; -1,&nbsp; 1,&nbsp; 0,&nbsp; 0,&nbsp; 1,&nbsp; 0,&nbsp; 1,<br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;  0,&nbsp; 1,&nbsp; 0,&nbsp; 0,&nbsp; 0,&nbsp; 1,&nbsp; 2<br />
&nbsp; &nbsp; &nbsp; &nbsp; };<br />
&nbsp; &nbsp; &nbsp; &nbsp; float *dx=&amp;sim_max&#91;0&#93;&#91;0&#93;;<br />
&nbsp; &nbsp; &nbsp; &nbsp; cout&lt;&lt;dx&#91;1&#93;&#91;0&#93;;</pre><br />
03 why i am not able to directly initialize array of new dynamically alloc. mem to<br />
 <pre style="margin:20px; line-height:13px">float *dx= new float[5*7]<br />
&nbsp; &nbsp; &nbsp; &nbsp; (<br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; -5, -4,&nbsp; 0,&nbsp; 0,&nbsp; 0,&nbsp; 0,&nbsp; 0,<br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;  6,&nbsp; 4,&nbsp; 1,&nbsp; 0,&nbsp; 0,&nbsp; 0, 24,<br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;  1,&nbsp; 2,&nbsp; 0,&nbsp; 1,&nbsp; 0,&nbsp; 0,&nbsp; 6,<br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; -1,&nbsp; 1,&nbsp; 0,&nbsp; 0,&nbsp; 1,&nbsp; 0,&nbsp; 1,<br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;  0,&nbsp; 1,&nbsp; 0,&nbsp; 0,&nbsp; 0,&nbsp; 1,&nbsp; 2<br />
&nbsp; &nbsp; &nbsp; &nbsp; );</pre></div> ]]></content:encoded>
			<category domain="http://www.daniweb.com/forums/forum8.html">C++</category>
			<dc:creator>Rhohitman</dc:creator>
			<guid isPermaLink="true">http://www.daniweb.com/forums/thread227285.html</guid>
		</item>
	</channel>
</rss>
