<?xml version='1.0' encoding='UTF-8'?><rss xmlns:atom="http://www.w3.org/2005/Atom" xmlns:openSearch="http://a9.com/-/spec/opensearchrss/1.0/" xmlns:blogger="http://schemas.google.com/blogger/2008" xmlns:georss="http://www.georss.org/georss" xmlns:gd="http://schemas.google.com/g/2005" xmlns:thr="http://purl.org/syndication/thread/1.0" version="2.0"><channel><atom:id>tag:blogger.com,1999:blog-2916649872140425333</atom:id><lastBuildDate>Sun, 23 Jul 2017 08:34:56 +0000</lastBuildDate><category>calculate daye</category><category>gtu papers</category><category>memory address</category><category>months</category><category>years</category><title>Learn Programming With Me</title><description></description><link>http://programmingwithme.blogspot.com/</link><managingEditor>noreply@blogger.com (THE Author)</managingEditor><generator>Blogger</generator><openSearch:totalResults>40</openSearch:totalResults><openSearch:startIndex>1</openSearch:startIndex><openSearch:itemsPerPage>25</openSearch:itemsPerPage><item><guid isPermaLink="false">tag:blogger.com,1999:blog-2916649872140425333.post-2851479326146008275</guid><pubDate>Thu, 14 Apr 2011 14:19:00 +0000</pubDate><atom:updated>2011-09-30T21:06:49.068+05:30</atom:updated><category domain="http://www.blogger.com/atom/ns#">gtu papers</category><title>Links for the papers of OOCP in GTU</title><description>&lt;div dir=&quot;ltr&quot; style=&quot;text-align: left;&quot; trbidi=&quot;on&quot;&gt;Here are the links provided for the papers of GTU in OOCP&lt;br /&gt;&lt;br /&gt;1.http://www.gtu.edu.in/GTU_Papers/BE/NOV-DEC-JAN-10-11/140704.zip&lt;br /&gt;&lt;br /&gt;2.http://www.gtu.edu.in/GTU_Papers/BE/2010June/140704.zip &lt;/div&gt;&lt;div class=&quot;blogger-post-footer&quot;&gt;For more detailed version visit http://programmingwithme.blogspot.com&lt;/div&gt;</description><link>http://programmingwithme.blogspot.com/2011/04/links-for-papers-of-oocp-in-gtu.html</link><author>noreply@blogger.com (THE Author)</author><thr:total>0</thr:total></item><item><guid isPermaLink="false">tag:blogger.com,1999:blog-2916649872140425333.post-1209558474320469867</guid><pubDate>Sun, 20 Mar 2011 11:26:00 +0000</pubDate><atom:updated>2011-09-30T21:06:48.965+05:30</atom:updated><title>Using Pointers (continues)</title><description>&lt;div dir=&quot;ltr&quot; style=&quot;text-align: left;&quot; trbidi=&quot;on&quot;&gt;  &lt;br /&gt;&lt;div style=&quot;direction: ltr; line-height: 90%; margin-bottom: 0pt; margin-top: 4.32pt; text-align: left; unicode-bidi: embed; vertical-align: baseline;&quot;&gt;&lt;span style=&quot;color: #006600; font-family: &amp;quot;Courier New&amp;quot;; font-weight: bold;&quot;&gt;int&lt;/span&gt;&lt;span style=&quot;color: #006600; font-family: &amp;quot;Courier New&amp;quot;; font-weight: bold;&quot;&gt;&lt;span&gt;&amp;nbsp; &lt;/span&gt;int1&lt;span&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;= 1036;&lt;span&gt;&amp;nbsp;&amp;nbsp; &lt;/span&gt;/* some data to point to&lt;span&gt;&amp;nbsp; &lt;/span&gt;*/&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;direction: ltr; line-height: 90%; margin-bottom: 0pt; margin-top: 4.32pt; text-align: left; unicode-bidi: embed; vertical-align: baseline;&quot;&gt;&lt;span style=&quot;color: #006600; font-family: &amp;quot;Courier New&amp;quot;; font-weight: bold;&quot;&gt;int&lt;/span&gt;&lt;span style=&quot;color: #006600; font-family: &amp;quot;Courier New&amp;quot;; font-weight: bold;&quot;&gt;&lt;span&gt;&amp;nbsp; &lt;/span&gt;int2&lt;span&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;= 8;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;direction: ltr; line-height: 90%; margin-bottom: 0pt; margin-top: 4.32pt; text-align: left; unicode-bidi: embed; vertical-align: baseline;&quot;&gt;&lt;span style=&quot;color: #006600; font-family: &amp;quot;Courier New&amp;quot;; font-weight: bold;&quot;&gt; &lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;direction: ltr; line-height: 90%; margin-bottom: 0pt; margin-top: 4.32pt; text-align: left; unicode-bidi: embed; vertical-align: baseline;&quot;&gt;&lt;span style=&quot;color: #006600; font-family: &amp;quot;Courier New&amp;quot;; font-weight: bold;&quot;&gt;int&lt;/span&gt;&lt;span style=&quot;color: #006600; font-family: &amp;quot;Courier New&amp;quot;; font-weight: bold;&quot;&gt; *int_ptr1 = &amp;amp;int1;&lt;span&gt;&amp;nbsp; &lt;/span&gt;/* get addresses of data&lt;span&gt;&amp;nbsp; &lt;/span&gt;*/&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;direction: ltr; line-height: 90%; margin-bottom: 0pt; margin-top: 4.32pt; text-align: left; unicode-bidi: embed; vertical-align: baseline;&quot;&gt;&lt;span style=&quot;color: #006600; font-family: &amp;quot;Courier New&amp;quot;; font-weight: bold;&quot;&gt;int&lt;/span&gt;&lt;span style=&quot;color: #006600; font-family: &amp;quot;Courier New&amp;quot;; font-weight: bold;&quot;&gt; *int_ptr2 = &amp;amp;int2;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;direction: ltr; line-height: 90%; margin-bottom: 0pt; margin-top: 4.32pt; text-align: left; unicode-bidi: embed; vertical-align: baseline;&quot;&gt;&lt;span style=&quot;color: #006600; font-family: &amp;quot;Courier New&amp;quot;; font-weight: bold;&quot;&gt; &lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;direction: ltr; line-height: 90%; margin-bottom: 0pt; margin-top: 4.32pt; text-align: left; unicode-bidi: embed; vertical-align: baseline;&quot;&gt;&lt;span style=&quot;color: #006600; font-family: &amp;quot;Courier New&amp;quot;; font-weight: bold;&quot;&gt;int_ptr1 = *int_ptr2;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;direction: ltr; line-height: 90%; margin-bottom: 0pt; margin-top: 4.32pt; text-align: left; unicode-bidi: embed; vertical-align: baseline;&quot;&gt;&lt;span style=&quot;color: #006600; font-family: &amp;quot;Courier New&amp;quot;; font-weight: bold;&quot;&gt; &lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;direction: ltr; line-height: 90%; margin-bottom: 0pt; margin-top: 4.32pt; text-align: left; unicode-bidi: embed; vertical-align: baseline;&quot;&gt;&lt;span style=&quot;color: #006600; font-family: &amp;quot;Courier New&amp;quot;; font-weight: bold;&quot;&gt;int_ptr1 = int_ptr2;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;direction: ltr; line-height: 90%; margin-bottom: 0pt; margin-top: 4.32pt; text-align: left; unicode-bidi: embed; vertical-align: baseline;&quot;&gt;&lt;br /&gt;&lt;/div&gt;&lt;div style=&quot;direction: ltr; line-height: 90%; margin-bottom: 0pt; margin-top: 4.32pt; text-align: left; unicode-bidi: embed; vertical-align: baseline;&quot;&gt;&lt;span style=&quot;color: #006600; font-family: &amp;quot;Courier New&amp;quot;; font-weight: bold;&quot;&gt;Changes happen:&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;direction: ltr; margin-bottom: 0pt; margin-top: 0pt; text-align: left; unicode-bidi: embed; vertical-align: baseline;&quot;&gt;&lt;span style=&quot;color: #006600; font-family: &amp;quot;Courier New&amp;quot;; font-weight: bold;&quot;&gt;1.&lt;/span&gt;&lt;span style=&quot;font-size: small;&quot;&gt;&lt;span style=&quot;color: #006600; font-family: Verdana; font-weight: bold;&quot;&gt;Type check warning:&lt;span&gt;&amp;nbsp; &lt;/span&gt;&lt;/span&gt;&lt;span style=&quot;color: #006600; font-family: &amp;quot;Courier New&amp;quot;; font-weight: bold;&quot;&gt;*int_ptr2&lt;/span&gt;&lt;span style=&quot;color: #006600; font-family: Verdana; font-weight: bold;&quot;&gt; is not an &lt;/span&gt;&lt;span style=&quot;color: #006600; font-family: &amp;quot;Courier New&amp;quot;; font-weight: bold;&quot;&gt;int&lt;/span&gt;&lt;span style=&quot;color: #006600; font-family: &amp;quot;Courier New&amp;quot;; font-weight: bold;&quot;&gt; *&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;direction: ltr; margin-bottom: 0pt; margin-top: 0pt; text-align: left; unicode-bidi: embed; vertical-align: baseline;&quot;&gt;&lt;span style=&quot;font-size: small;&quot;&gt;&lt;span style=&quot;color: #006600; font-family: &amp;quot;Courier New&amp;quot;; font-weight: bold;&quot;&gt;2.&lt;/span&gt;&lt;span style=&quot;color: #006600; font-family: Verdana; font-weight: bold;&quot;&gt;Changes &lt;/span&gt;&lt;span style=&quot;color: #006600; font-family: &amp;quot;Courier New&amp;quot;; font-weight: bold;&quot;&gt;int_ptr1&lt;/span&gt;&lt;span style=&quot;color: #006600; font-family: Verdana; font-weight: bold;&quot;&gt; – doesn’t change &lt;/span&gt;&lt;span style=&quot;color: #006600; font-family: &amp;quot;Courier New&amp;quot;; font-weight: bold;&quot;&gt;int1&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div&gt;  &lt;/div&gt;&lt;div style=&quot;direction: ltr; margin-bottom: 0pt; margin-top: 0pt; text-align: left; unicode-bidi: embed; vertical-align: baseline;&quot;&gt;&lt;span style=&quot;font-size: small;&quot;&gt;&lt;span style=&quot;color: #006600; font-family: &amp;quot;Courier New&amp;quot;; font-weight: bold;&quot;&gt; &lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;text-align: left;&quot;&gt;&lt;br /&gt;&lt;/div&gt;&lt;/div&gt;&lt;div class=&quot;blogger-post-footer&quot;&gt;For more detailed version visit http://programmingwithme.blogspot.com&lt;/div&gt;</description><link>http://programmingwithme.blogspot.com/2011/03/using-pointers-continues.html</link><author>noreply@blogger.com (THE Author)</author><thr:total>0</thr:total></item><item><guid isPermaLink="false">tag:blogger.com,1999:blog-2916649872140425333.post-9216820944261398117</guid><pubDate>Sun, 20 Mar 2011 11:24:00 +0000</pubDate><atom:updated>2011-09-30T21:06:49.224+05:30</atom:updated><title>Using Pointers (cont.)</title><description>&lt;div dir=&quot;ltr&quot; style=&quot;text-align: left;&quot; trbidi=&quot;on&quot;&gt;  &lt;br /&gt;&lt;div style=&quot;direction: ltr; line-height: 90%; margin-bottom: 0pt; margin-top: 4.32pt; text-align: left; unicode-bidi: embed; vertical-align: baseline;&quot;&gt;&lt;span style=&quot;color: #006600; font-family: &amp;quot;Courier New&amp;quot;; font-weight: bold;&quot;&gt;int&lt;/span&gt;&lt;span style=&quot;color: #006600; font-family: &amp;quot;Courier New&amp;quot;; font-weight: bold;&quot;&gt;&lt;span&gt;&amp;nbsp; &lt;/span&gt;int1&lt;span&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;= 1036;&lt;span&gt;&amp;nbsp;&amp;nbsp; &lt;/span&gt;/* some data to point to&lt;span&gt;&amp;nbsp; &lt;/span&gt;*/&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;direction: ltr; line-height: 90%; margin-bottom: 0pt; margin-top: 4.32pt; text-align: left; unicode-bidi: embed; vertical-align: baseline;&quot;&gt;&lt;span style=&quot;color: #006600; font-family: &amp;quot;Courier New&amp;quot;; font-weight: bold;&quot;&gt;int&lt;/span&gt;&lt;span style=&quot;color: #006600; font-family: &amp;quot;Courier New&amp;quot;; font-weight: bold;&quot;&gt;&lt;span&gt;&amp;nbsp; &lt;/span&gt;int2&lt;span&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;= 8;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;direction: ltr; line-height: 90%; margin-bottom: 0pt; margin-top: 4.32pt; text-align: left; unicode-bidi: embed; vertical-align: baseline;&quot;&gt;&lt;span style=&quot;color: #006600; font-family: &amp;quot;Courier New&amp;quot;; font-weight: bold;&quot;&gt; &lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;direction: ltr; line-height: 90%; margin-bottom: 0pt; margin-top: 4.32pt; text-align: left; unicode-bidi: embed; vertical-align: baseline;&quot;&gt;&lt;span style=&quot;color: #006600; font-family: &amp;quot;Courier New&amp;quot;; font-weight: bold;&quot;&gt;int&lt;/span&gt;&lt;span style=&quot;color: #006600; font-family: &amp;quot;Courier New&amp;quot;; font-weight: bold;&quot;&gt; *int_ptr1 = &amp;amp;int1;&lt;span&gt;&amp;nbsp; &lt;/span&gt;/* get addresses of data&lt;span&gt;&amp;nbsp; &lt;/span&gt;*/&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;direction: ltr; line-height: 90%; margin-bottom: 0pt; margin-top: 4.32pt; text-align: left; unicode-bidi: embed; vertical-align: baseline;&quot;&gt;&lt;span style=&quot;color: #006600; font-family: &amp;quot;Courier New&amp;quot;; font-weight: bold;&quot;&gt;int&lt;/span&gt;&lt;span style=&quot;color: #006600; font-family: &amp;quot;Courier New&amp;quot;; font-weight: bold;&quot;&gt; *int_ptr2 = &amp;amp;int2;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;direction: ltr; line-height: 90%; margin-bottom: 0pt; margin-top: 4.32pt; text-align: left; unicode-bidi: embed; vertical-align: baseline;&quot;&gt;&lt;span style=&quot;color: #006600; font-family: &amp;quot;Courier New&amp;quot;; font-weight: bold;&quot;&gt; &lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;direction: ltr; line-height: 90%; margin-bottom: 0pt; margin-top: 4.32pt; text-align: left; unicode-bidi: embed; vertical-align: baseline;&quot;&gt;&lt;span style=&quot;color: #006600; font-family: &amp;quot;Courier New&amp;quot;; font-weight: bold;&quot;&gt;*int_ptr1 = int_ptr2;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;direction: ltr; line-height: 90%; margin-bottom: 0pt; margin-top: 4.32pt; text-align: left; unicode-bidi: embed; vertical-align: baseline;&quot;&gt;&lt;span style=&quot;color: #006600; font-family: &amp;quot;Courier New&amp;quot;; font-weight: bold;&quot;&gt; &lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;direction: ltr; line-height: 90%; margin-bottom: 0pt; margin-top: 4.32pt; text-align: left; unicode-bidi: embed; vertical-align: baseline;&quot;&gt;&lt;span style=&quot;color: #006600; font-family: &amp;quot;Courier New&amp;quot;; font-weight: bold;&quot;&gt;*int_ptr1 = int2;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;direction: ltr; line-height: 90%; margin-bottom: 0pt; margin-top: 4.32pt; text-align: left; unicode-bidi: embed; vertical-align: baseline;&quot;&gt;&lt;br /&gt;&lt;/div&gt;&lt;div style=&quot;direction: ltr; line-height: 90%; margin-bottom: 0pt; margin-top: 4.32pt; text-align: left; unicode-bidi: embed; vertical-align: baseline;&quot;&gt;&lt;span style=&quot;color: #006600; font-family: &amp;quot;Courier New&amp;quot;; font-weight: bold;&quot;&gt;int1 becomes 8&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;direction: ltr; line-height: 90%; margin-bottom: 0pt; margin-top: 4.32pt; text-align: left; unicode-bidi: embed; vertical-align: baseline;&quot;&gt;&lt;span style=&quot;color: #006600; font-family: &amp;quot;Courier New&amp;quot;; font-weight: bold;&quot;&gt; &lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;direction: ltr; line-height: 90%; margin-bottom: 0pt; margin-top: 4.32pt; text-align: left; unicode-bidi: embed; vertical-align: baseline;&quot;&gt;  &lt;/div&gt;&lt;div style=&quot;direction: ltr; margin-bottom: 0pt; margin-top: 0pt; text-align: left; unicode-bidi: embed; vertical-align: baseline;&quot;&gt;&lt;span style=&quot;font-size: small;&quot;&gt;&lt;span style=&quot;color: #006600; font-family: Verdana; font-weight: bold;&quot;&gt;Type check warning:&lt;span&gt;&amp;nbsp; &lt;/span&gt;&lt;/span&gt;&lt;span style=&quot;color: #006600; font-family: &amp;quot;Courier New&amp;quot;; font-weight: bold;&quot;&gt;int_ptr2&lt;/span&gt;&lt;span style=&quot;color: #006600; font-family: Verdana; font-weight: bold;&quot;&gt; is not an &lt;/span&gt;&lt;span style=&quot;color: #006600; font-family: &amp;quot;Courier New&amp;quot;; font-weight: bold;&quot;&gt;int&lt;/span&gt;&lt;span style=&quot;color: #006600; font-family: &amp;quot;Courier New&amp;quot;; font-weight: bold;&quot;&gt; &lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;direction: ltr; line-height: 90%; margin-bottom: 0pt; margin-top: 4.32pt; text-align: left; unicode-bidi: embed; vertical-align: baseline;&quot;&gt;&lt;span style=&quot;color: #006600; font-family: &amp;quot;Courier New&amp;quot;; font-weight: bold;&quot;&gt; &lt;/span&gt;&lt;/div&gt;&lt;/div&gt;&lt;div class=&quot;blogger-post-footer&quot;&gt;For more detailed version visit http://programmingwithme.blogspot.com&lt;/div&gt;</description><link>http://programmingwithme.blogspot.com/2011/03/using-pointers-cont.html</link><author>noreply@blogger.com (THE Author)</author><thr:total>0</thr:total></item><item><guid isPermaLink="false">tag:blogger.com,1999:blog-2916649872140425333.post-4934140437966913935</guid><pubDate>Sun, 20 Mar 2011 11:20:00 +0000</pubDate><atom:updated>2011-09-30T21:06:49.142+05:30</atom:updated><title>Using Pointers</title><description>&lt;div dir=&quot;ltr&quot; style=&quot;text-align: left;&quot; trbidi=&quot;on&quot;&gt;  &lt;br /&gt;&lt;br /&gt;&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;&lt;a href=&quot;https://lh3.googleusercontent.com/-W59fDJgQsls/TYXfntXrw4I/AAAAAAAAABI/4tI2yMo-fbo/s1600/pointer.png&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;212&quot; src=&quot;https://lh3.googleusercontent.com/-W59fDJgQsls/TYXfntXrw4I/AAAAAAAAABI/4tI2yMo-fbo/s320/pointer.png&quot; width=&quot;320&quot; /&gt;&lt;/a&gt;&lt;/div&gt;&lt;div style=&quot;color: blue; direction: ltr; margin-bottom: 0pt; margin-top: 4.32pt; text-align: left; unicode-bidi: embed; vertical-align: baseline;&quot;&gt;&lt;span style=&quot;font-family: &amp;quot;Courier New&amp;quot;; font-weight: bold;&quot;&gt;int&lt;/span&gt;&lt;span style=&quot;font-family: &amp;quot;Courier New&amp;quot;; font-weight: bold;&quot;&gt;&lt;span&gt;&amp;nbsp; &lt;/span&gt;i1;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;color: blue; direction: ltr; margin-bottom: 0pt; margin-top: 4.32pt; text-align: left; unicode-bidi: embed; vertical-align: baseline;&quot;&gt;&lt;span style=&quot;font-family: &amp;quot;Courier New&amp;quot;; font-weight: bold;&quot;&gt;int&lt;/span&gt;&lt;span style=&quot;font-family: &amp;quot;Courier New&amp;quot;; font-weight: bold;&quot;&gt;&lt;span&gt;&amp;nbsp; &lt;/span&gt;i2;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;color: blue; direction: ltr; margin-bottom: 0pt; margin-top: 4.32pt; text-align: left; unicode-bidi: embed; vertical-align: baseline;&quot;&gt;&lt;span style=&quot;font-family: &amp;quot;Courier New&amp;quot;; font-weight: bold;&quot;&gt;int&lt;/span&gt;&lt;span style=&quot;font-family: &amp;quot;Courier New&amp;quot;; font-weight: bold;&quot;&gt; *ptr1;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;color: blue; direction: ltr; margin-bottom: 0pt; margin-top: 4.32pt; text-align: left; unicode-bidi: embed; vertical-align: baseline;&quot;&gt;&lt;br /&gt;&lt;/div&gt;&lt;div style=&quot;color: blue; direction: ltr; margin-bottom: 0pt; margin-top: 4.32pt; text-align: left; unicode-bidi: embed; vertical-align: baseline;&quot;&gt;&lt;span style=&quot;font-family: &amp;quot;Courier New&amp;quot;; font-weight: bold;&quot;&gt;int&lt;/span&gt;&lt;span style=&quot;font-family: &amp;quot;Courier New&amp;quot;; font-weight: bold;&quot;&gt; *ptr2;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;color: blue; direction: ltr; margin-bottom: 0pt; margin-top: 4.32pt; text-align: left; unicode-bidi: embed; vertical-align: baseline;&quot;&gt;&lt;span style=&quot;font-family: &amp;quot;Courier New&amp;quot;; font-weight: bold;&quot;&gt; &lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;color: blue; direction: ltr; margin-bottom: 0pt; margin-top: 4.32pt; text-align: left; unicode-bidi: embed; vertical-align: baseline;&quot;&gt;&lt;span style=&quot;font-family: &amp;quot;Courier New&amp;quot;; font-weight: bold;&quot;&gt;i1 = 1;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;color: blue; direction: ltr; margin-bottom: 0pt; margin-top: 4.32pt; text-align: left; unicode-bidi: embed; vertical-align: baseline;&quot;&gt;&lt;span style=&quot;font-family: &amp;quot;Courier New&amp;quot;; font-weight: bold;&quot;&gt;i2 = 2;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;color: blue; direction: ltr; margin-bottom: 0pt; margin-top: 4.32pt; text-align: left; unicode-bidi: embed; vertical-align: baseline;&quot;&gt;&lt;span style=&quot;font-family: &amp;quot;Courier New&amp;quot;; font-weight: bold;&quot;&gt; &lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;color: blue; direction: ltr; margin-bottom: 0pt; margin-top: 4.32pt; text-align: left; unicode-bidi: embed; vertical-align: baseline;&quot;&gt;&lt;br /&gt;&lt;/div&gt;&lt;div style=&quot;color: blue; direction: ltr; margin-bottom: 0pt; margin-top: 4.32pt; text-align: left; unicode-bidi: embed; vertical-align: baseline;&quot;&gt;&lt;span style=&quot;font-family: &amp;quot;Courier New&amp;quot;; font-weight: bold;&quot;&gt;ptr1 = &amp;amp;i1;//ptr1 points to address 0x1000&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;color: blue; direction: ltr; margin-bottom: 0pt; margin-top: 4.32pt; text-align: left; unicode-bidi: embed; vertical-align: baseline;&quot;&gt;&lt;br /&gt;&lt;/div&gt;&lt;div style=&quot;color: blue; direction: ltr; margin-bottom: 0pt; margin-top: 4.32pt; text-align: left; unicode-bidi: embed; vertical-align: baseline;&quot;&gt;&lt;span style=&quot;font-family: &amp;quot;Courier New&amp;quot;; font-weight: bold;&quot;&gt;ptr2 = ptr1;//ptr2 takes address of ptr1 and so &lt;/span&gt;&lt;span style=&quot;font-family: &amp;quot;Courier New&amp;quot;; font-weight: bold;&quot;&gt;ptr2 points to&amp;nbsp;&amp;nbsp; address 0x1000&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;color: blue; direction: ltr; margin-bottom: 0pt; margin-top: 4.32pt; text-align: left; unicode-bidi: embed; vertical-align: baseline;&quot;&gt;&lt;span style=&quot;font-family: &amp;quot;Courier New&amp;quot;; font-weight: bold;&quot;&gt; &lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;color: blue; direction: ltr; margin-bottom: 0pt; margin-top: 4.32pt; text-align: left; unicode-bidi: embed; vertical-align: baseline;&quot;&gt;&lt;br /&gt;&lt;/div&gt;&lt;div style=&quot;color: blue; direction: ltr; margin-bottom: 0pt; margin-top: 4.32pt; text-align: left; unicode-bidi: embed; vertical-align: baseline;&quot;&gt;&lt;span style=&quot;font-family: &amp;quot;Courier New&amp;quot;; font-weight: bold;&quot;&gt;*ptr1 = 3;//value of i1(to which ptr1 pointed becomes 3&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;color: blue; direction: ltr; margin-bottom: 0pt; margin-top: 4.32pt; text-align: left; unicode-bidi: embed; vertical-align: baseline;&quot;&gt;&lt;br /&gt;&lt;/div&gt;&lt;div style=&quot;color: blue; direction: ltr; margin-bottom: 0pt; margin-top: 4.32pt; text-align: left; unicode-bidi: embed; vertical-align: baseline;&quot;&gt;&lt;span style=&quot;font-family: &amp;quot;Courier New&amp;quot;; font-weight: bold;&quot;&gt;i2 = *ptr2;//as i1=3,*ptr2=*ptr1=3,so i2 becomes 3&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;color: blue; direction: ltr; margin-bottom: 0pt; margin-top: 4.32pt; text-align: left; unicode-bidi: embed; vertical-align: baseline;&quot;&gt;&lt;br /&gt;&lt;/div&gt;&lt;div style=&quot;color: blue; direction: ltr; margin-bottom: 0pt; margin-top: 4.32pt; text-align: left; unicode-bidi: embed; vertical-align: baseline;&quot;&gt;&lt;span style=&quot;font-family: &amp;quot;Courier New&amp;quot;; font-weight: bold;&quot;&gt; &lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;color: red; direction: ltr; margin-bottom: 0pt; margin-top: 4.32pt; text-align: left; unicode-bidi: embed; vertical-align: baseline;&quot;&gt;&lt;br /&gt;&lt;/div&gt;&lt;/div&gt;&lt;div class=&quot;blogger-post-footer&quot;&gt;For more detailed version visit http://programmingwithme.blogspot.com&lt;/div&gt;</description><link>http://programmingwithme.blogspot.com/2011/03/using-pointers.html</link><author>noreply@blogger.com (THE Author)</author><media:thumbnail xmlns:media="http://search.yahoo.com/mrss/" url="https://lh3.googleusercontent.com/-W59fDJgQsls/TYXfntXrw4I/AAAAAAAAABI/4tI2yMo-fbo/s72-c/pointer.png" height="72" width="72"/><thr:total>0</thr:total></item><item><guid isPermaLink="false">tag:blogger.com,1999:blog-2916649872140425333.post-2053536185959963551</guid><pubDate>Sun, 20 Mar 2011 10:50:00 +0000</pubDate><atom:updated>2011-09-30T21:06:49.033+05:30</atom:updated><title>Pointer Operations in C</title><description>&lt;div dir=&quot;ltr&quot; style=&quot;text-align: left;&quot; trbidi=&quot;on&quot;&gt;  &lt;br /&gt;&lt;div style=&quot;color: lime; direction: ltr; margin-bottom: 0pt; margin-left: 0.19in; margin-top: 5.76pt; text-align: left; text-indent: -0.19in; unicode-bidi: embed; vertical-align: baseline;&quot;&gt;&lt;span style=&quot;font-size: small;&quot;&gt;&lt;span style=&quot;font-family: Verdana; font-weight: bold;&quot;&gt;Creation&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;direction: ltr; margin-bottom: 0pt; margin-left: 0.7in; margin-top: 4.8pt; text-align: left; text-indent: -0.32in; unicode-bidi: embed; vertical-align: baseline;&quot;&gt;&lt;span style=&quot;font-size: small;&quot;&gt;&lt;span style=&quot;color: #000066; font-family: &amp;quot;Courier New&amp;quot;; font-weight: normal;&quot;&gt;&amp;amp;&lt;/span&gt;&lt;span style=&quot;color: #000066; font-family: Verdana; font-weight: bold;&quot;&gt; &lt;/span&gt;&lt;span style=&quot;color: #000066; font-family: Verdana; font-style: italic; font-weight: bold;&quot;&gt;variable&lt;/span&gt;&lt;span style=&quot;color: #000066; font-family: Verdana; font-weight: bold;&quot;&gt;&lt;span&gt;&amp;nbsp; &lt;/span&gt;Returns variable’s memory address&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;color: lime; direction: ltr; margin-bottom: 0pt; margin-left: 0.19in; margin-top: 5.76pt; text-align: left; text-indent: -0.19in; unicode-bidi: embed; vertical-align: baseline;&quot;&gt;&lt;span style=&quot;font-size: small;&quot;&gt;&lt;span style=&quot;font-family: Verdana; font-weight: bold;&quot;&gt;Dereference&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;direction: ltr; margin-bottom: 0pt; margin-left: 0.7in; margin-top: 4.8pt; text-align: left; text-indent: -0.32in; unicode-bidi: embed; vertical-align: baseline;&quot;&gt;&lt;span style=&quot;font-size: small;&quot;&gt;&lt;span style=&quot;color: #000066; font-family: &amp;quot;Courier New&amp;quot;; font-weight: normal;&quot;&gt;*&lt;/span&gt;&lt;span style=&quot;color: #000066; font-family: Verdana; font-weight: bold;&quot;&gt; &lt;/span&gt;&lt;span style=&quot;color: #000066; font-family: Verdana; font-style: italic; font-weight: bold;&quot;&gt;pointer&lt;/span&gt;&lt;span style=&quot;color: #000066; font-family: Verdana; font-weight: bold;&quot;&gt;&lt;span&gt;&amp;nbsp; &lt;/span&gt;Returns contents stored at address&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;color: lime; direction: ltr; margin-bottom: 0pt; margin-left: 0.19in; margin-top: 5.76pt; text-align: left; text-indent: -0.19in; unicode-bidi: embed; vertical-align: baseline;&quot;&gt;&lt;span style=&quot;font-size: small;&quot;&gt;&lt;span style=&quot;font-family: Verdana; font-weight: bold;&quot;&gt;Indirect assignment&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;direction: ltr; margin-bottom: 0pt; margin-left: 0.7in; margin-top: 4.8pt; text-align: left; text-indent: -0.32in; unicode-bidi: embed; vertical-align: baseline;&quot;&gt;&lt;span style=&quot;font-size: small;&quot;&gt;&lt;span style=&quot;color: #000066; font-family: &amp;quot;Courier New&amp;quot;; font-weight: normal;&quot;&gt;*&lt;/span&gt;&lt;span style=&quot;color: #000066; font-family: Verdana; font-weight: bold;&quot;&gt; &lt;/span&gt;&lt;span style=&quot;color: #000066; font-family: Verdana; font-style: italic; font-weight: bold;&quot;&gt;pointer&lt;/span&gt;&lt;span style=&quot;color: #000066; font-family: Verdana; font-weight: bold;&quot;&gt; &lt;/span&gt;&lt;span style=&quot;color: #000066; font-family: &amp;quot;Courier New&amp;quot;; font-weight: normal;&quot;&gt;=&lt;/span&gt;&lt;span style=&quot;color: #000066; font-family: Verdana; font-weight: bold;&quot;&gt; &lt;/span&gt;&lt;span style=&quot;color: #000066; font-family: Verdana; font-style: italic; font-weight: bold;&quot;&gt;val&lt;/span&gt;&lt;span style=&quot;color: #000066; font-family: Verdana; font-style: italic; font-weight: bold;&quot;&gt;&lt;span&gt;&amp;nbsp; &lt;/span&gt;&lt;/span&gt;&lt;span style=&quot;color: #000066; font-family: Verdana; font-weight: bold;&quot;&gt;Stores value at address&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;direction: ltr; margin-bottom: 0pt; margin-left: 0.19in; margin-top: 5.76pt; text-align: left; text-indent: -0.19in; unicode-bidi: embed; vertical-align: baseline;&quot;&gt;&lt;span style=&quot;font-size: small;&quot;&gt;&lt;span style=&quot;color: #006600; font-family: Verdana; font-weight: bold;&quot;&gt; &lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;direction: ltr; margin-bottom: 0pt; margin-left: 0.19in; margin-top: 5.76pt; text-align: left; text-indent: -0.19in; unicode-bidi: embed; vertical-align: baseline;&quot;&gt;&lt;span style=&quot;font-size: small;&quot;&gt;&lt;span style=&quot;color: #006600; font-family: Verdana; font-weight: bold;&quot;&gt; &lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;color: lime; direction: ltr; margin-bottom: 0pt; margin-left: 0.19in; margin-top: 5.76pt; text-align: left; text-indent: -0.19in; unicode-bidi: embed; vertical-align: baseline;&quot;&gt;&lt;span style=&quot;font-size: small;&quot;&gt;&lt;span style=&quot;font-family: Verdana; font-weight: bold;&quot;&gt;Assignment&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;direction: ltr; margin-bottom: 0pt; margin-left: 0.7in; margin-top: 4.8pt; text-align: left; text-indent: -0.32in; unicode-bidi: embed; vertical-align: baseline;&quot;&gt;&lt;span style=&quot;font-size: small;&quot;&gt;&lt;span style=&quot;color: #000066; font-family: Verdana; font-style: italic; font-weight: bold;&quot;&gt;pointer&lt;/span&gt;&lt;span style=&quot;color: #000066; font-family: Verdana; font-weight: bold;&quot;&gt; &lt;/span&gt;&lt;span style=&quot;color: #000066; font-family: &amp;quot;Courier New&amp;quot;; font-weight: normal;&quot;&gt;=&lt;/span&gt;&lt;span style=&quot;color: #000066; font-family: Verdana; font-weight: bold;&quot;&gt; &lt;/span&gt;&lt;span style=&quot;color: #000066; font-family: Verdana; font-style: italic; font-weight: bold;&quot;&gt;ptr&lt;/span&gt;&lt;span style=&quot;color: #000066; font-family: Verdana; font-weight: bold;&quot;&gt;&lt;span&gt;&amp;nbsp; &lt;/span&gt;Stores pointer in another variable&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;direction: ltr; margin-bottom: 0pt; margin-left: 0.7in; margin-top: 4.8pt; text-align: left; text-indent: -0.32in; unicode-bidi: embed; vertical-align: baseline;&quot;&gt;&lt;br /&gt;&lt;/div&gt;&lt;div style=&quot;direction: ltr; margin-bottom: 0pt; margin-left: 0.7in; margin-top: 4.8pt; text-align: left; text-indent: -0.32in; unicode-bidi: embed; vertical-align: baseline;&quot;&gt;&lt;span style=&quot;font-size: small;&quot;&gt;&lt;span style=&quot;color: #000066; font-family: Verdana; font-weight: bold;&quot;&gt;eg.&amp;nbsp;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;direction: ltr; margin-bottom: 0pt; margin-left: 0.7in; margin-top: 4.8pt; text-align: left; text-indent: -0.32in; unicode-bidi: embed; vertical-align: baseline;&quot;&gt;&lt;span style=&quot;font-size: small;&quot;&gt;&lt;span style=&quot;color: #000066; font-family: Verdana; font-weight: bold;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; if a variable&amp;nbsp; is a=24 and it is stored at memory address 2000.Consider we want to point a pointer named p at that variable,do following things.&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;direction: ltr; margin-bottom: 0pt; margin-left: 0.7in; margin-top: 4.8pt; text-align: left; text-indent: -0.32in; unicode-bidi: embed; vertical-align: baseline;&quot;&gt;&lt;span style=&quot;font-size: small;&quot;&gt;&lt;span style=&quot;color: #000066; font-family: Verdana; font-weight: bold;&quot;&gt;int *p,a=24,b,c;//initializing the pointers &lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;direction: ltr; margin-bottom: 0pt; margin-left: 0.7in; margin-top: 4.8pt; text-align: left; text-indent: -0.32in; unicode-bidi: embed; vertical-align: baseline;&quot;&gt;&lt;span style=&quot;font-size: small;&quot;&gt;&lt;span style=&quot;color: #000066; font-family: Verdana; font-weight: bold;&quot;&gt;*p=&amp;amp;a;//stores 2000 address to the pointer&#39;s address&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;direction: ltr; margin-bottom: 0pt; margin-left: 0.7in; margin-top: 4.8pt; text-align: left; text-indent: -0.32in; unicode-bidi: embed; vertical-align: baseline;&quot;&gt;&lt;span style=&quot;font-size: small;&quot;&gt;&lt;span style=&quot;color: #000066; font-family: Verdana; font-weight: bold;&quot;&gt;b=*p;//outputs as &#39;24&#39; as it returns content of pointer&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;direction: ltr; margin-bottom: 0pt; margin-left: 0.7in; margin-top: 4.8pt; text-align: left; text-indent: -0.32in; unicode-bidi: embed; vertical-align: baseline;&quot;&gt;&lt;span style=&quot;font-size: small;&quot;&gt;&lt;span style=&quot;color: #000066; font-family: Verdana; font-weight: bold;&quot;&gt;*p=55;//directly stores the value at address 2000&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;direction: ltr; margin-bottom: 0pt; margin-left: 0.7in; margin-top: 4.8pt; text-align: left; text-indent: -0.32in; unicode-bidi: embed; vertical-align: baseline;&quot;&gt;&lt;span style=&quot;font-size: small;&quot;&gt;&lt;span style=&quot;color: #000066; font-family: Verdana; font-weight: bold;&quot;&gt;c=p;//stores the pointer&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;direction: ltr; margin-bottom: 0pt; margin-left: 0.7in; margin-top: 4.8pt; text-align: left; text-indent: -0.32in; unicode-bidi: embed; vertical-align: baseline;&quot;&gt;&lt;span style=&quot;font-size: small;&quot;&gt;&lt;span style=&quot;color: #000066; font-family: Verdana; font-weight: bold;&quot;&gt;&amp;nbsp;&lt;/span&gt;&lt;/span&gt;&lt;span style=&quot;font-size: small;&quot;&gt;&lt;span style=&quot;color: #000066; font-family: Verdana; font-weight: bold;&quot;&gt;&amp;nbsp;&lt;/span&gt;&lt;span style=&quot;color: #000066; font-family: Verdana; font-weight: bold;&quot;&gt; &lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;/div&gt;&lt;div class=&quot;blogger-post-footer&quot;&gt;For more detailed version visit http://programmingwithme.blogspot.com&lt;/div&gt;</description><link>http://programmingwithme.blogspot.com/2011/03/pointer-operations-in-c.html</link><author>noreply@blogger.com (THE Author)</author><thr:total>0</thr:total></item><item><guid isPermaLink="false">tag:blogger.com,1999:blog-2916649872140425333.post-2279114173670436256</guid><pubDate>Sun, 20 Mar 2011 10:29:00 +0000</pubDate><atom:updated>2011-09-30T21:06:49.059+05:30</atom:updated><title>Pointers</title><description>&lt;div dir=&quot;ltr&quot; style=&quot;text-align: left;&quot; trbidi=&quot;on&quot;&gt;  &lt;div style=&quot;direction: ltr; margin-bottom: 0pt; margin-left: 0.19in; margin-top: 5.76pt; text-align: left; text-indent: -0.19in; unicode-bidi: embed; vertical-align: baseline;&quot;&gt;&lt;span style=&quot;font-size: small;&quot;&gt;&lt;span style=&quot;color: #006600; font-family: Verdana; font-weight: bold;&quot;&gt;Special case of bounded-size natural numbers&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;O1&quot; style=&quot;direction: ltr; margin-bottom: 0pt; margin-left: 0.7in; margin-top: 4.8pt; text-align: left; text-indent: -0.32in; unicode-bidi: embed; vertical-align: baseline;&quot;&gt;&lt;span style=&quot;font-size: small;&quot;&gt;&lt;span&gt;&lt;span style=&quot;font-family: Wingdings;&quot;&gt;&lt;/span&gt;&lt;/span&gt;&lt;span style=&quot;color: #000066; font-family: Verdana; font-weight: bold;&quot;&gt;Maximum memory limited by processor word-size&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;O1&quot; style=&quot;direction: ltr; margin-bottom: 0pt; margin-left: 0.7in; margin-top: 4.8pt; text-align: left; text-indent: -0.32in; unicode-bidi: embed; vertical-align: baseline;&quot;&gt;&lt;span style=&quot;font-size: small;&quot;&gt;&lt;span&gt;&lt;span style=&quot;font-family: Wingdings;&quot;&gt;&lt;/span&gt;&lt;/span&gt;&lt;span style=&quot;color: #000066; font-family: Verdana; font-weight: bold;&quot;&gt;2&lt;/span&gt;&lt;span style=&quot;color: #000066; font-family: Verdana; font-weight: bold; vertical-align: super;&quot;&gt;32&lt;/span&gt;&lt;span style=&quot;color: #000066; font-family: Verdana; font-weight: bold;&quot;&gt; bytes = 4GB, 2&lt;/span&gt;&lt;span style=&quot;color: #000066; font-family: Verdana; font-weight: bold; vertical-align: super;&quot;&gt;64&lt;/span&gt;&lt;span style=&quot;color: #000066; font-family: Verdana; font-weight: bold;&quot;&gt; bytes = 16 &lt;/span&gt;&lt;span style=&quot;color: #000066; font-family: Verdana; font-weight: bold;&quot;&gt;exabytes&lt;/span&gt;&lt;span style=&quot;color: #000066; font-family: Verdana; font-weight: bold;&quot;&gt; &lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;direction: ltr; margin-bottom: 0pt; margin-left: 0.19in; margin-top: 5.76pt; text-align: left; text-indent: -0.19in; unicode-bidi: embed; vertical-align: baseline;&quot;&gt;&lt;span style=&quot;font-size: small;&quot;&gt;&lt;span style=&quot;color: #006600; font-family: Verdana; font-weight: bold;&quot;&gt; &lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;direction: ltr; margin-bottom: 0pt; margin-left: 0.19in; margin-top: 5.76pt; text-align: left; text-indent: -0.19in; unicode-bidi: embed; vertical-align: baseline;&quot;&gt;&lt;span style=&quot;font-size: small;&quot;&gt;&lt;span style=&quot;color: #006600; font-family: Verdana; font-weight: bold;&quot;&gt;A pointer is just another kind of value&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;O1&quot; style=&quot;direction: ltr; margin-bottom: 0pt; margin-left: 0.7in; margin-top: 4.8pt; text-align: left; text-indent: -0.32in; unicode-bidi: embed; vertical-align: baseline;&quot;&gt;&lt;span style=&quot;font-size: small;&quot;&gt;&lt;span&gt;&lt;span style=&quot;font-family: Wingdings;&quot;&gt;&lt;/span&gt;&lt;/span&gt;&lt;span style=&quot;color: #000066; font-family: Verdana; font-weight: bold;&quot;&gt;A basic type in C&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;O1&quot; style=&quot;direction: ltr; margin-bottom: 0pt; margin-left: 0.7in; margin-top: 4.8pt; text-align: left; text-indent: -0.32in; unicode-bidi: embed; vertical-align: baseline;&quot;&gt;&lt;span style=&quot;font-size: small;&quot;&gt;&lt;span style=&quot;color: #000066; font-family: Verdana; font-weight: bold;&quot;&gt;&amp;nbsp;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;O1&quot; style=&quot;direction: ltr; margin-bottom: 0pt; margin-left: 0.7in; margin-top: 4.8pt; text-align: left; text-indent: -0.32in; unicode-bidi: embed; vertical-align: baseline;&quot;&gt;&lt;span style=&quot;font-size: small;&quot;&gt;&lt;span style=&quot;color: #000066; font-family: Verdana; font-weight: bold;&quot;&gt;eg. int *ptr&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;O1&quot; style=&quot;direction: ltr; margin-bottom: 0pt; margin-left: 0.7in; margin-top: 4.8pt; text-align: left; text-indent: -0.32in; unicode-bidi: embed; vertical-align: baseline;&quot;&gt;  &lt;div style=&quot;direction: ltr; margin-bottom: 0pt; margin-top: 0pt; text-align: left; unicode-bidi: embed; vertical-align: baseline;&quot;&gt;&lt;span style=&quot;color: #006600; font-family: Arial;&quot;&gt;The variable “&lt;/span&gt;&lt;span style=&quot;color: #006600; font-family: Arial;&quot;&gt;ptr&lt;/span&gt;&lt;span style=&quot;color: #006600; font-family: Arial;&quot;&gt;” is a pointer to an “&lt;/span&gt;&lt;span style=&quot;color: #006600; font-family: Arial;&quot;&gt;int&lt;/span&gt;&lt;span style=&quot;color: #006600; font-family: Arial;&quot;&gt;”,the datatype.&lt;/span&gt;&lt;/div&gt;&lt;/div&gt;&lt;div style=&quot;direction: ltr; margin-bottom: 0pt; margin-left: 0.19in; margin-top: 5.76pt; text-align: left; text-indent: -0.19in; unicode-bidi: embed; vertical-align: baseline;&quot;&gt;&lt;span style=&quot;font-size: small;&quot;&gt;&lt;span style=&quot;color: #006600; font-family: Verdana; font-weight: bold;&quot;&gt; &lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;/div&gt;&lt;div class=&quot;blogger-post-footer&quot;&gt;For more detailed version visit http://programmingwithme.blogspot.com&lt;/div&gt;</description><link>http://programmingwithme.blogspot.com/2011/03/pointers.html</link><author>noreply@blogger.com (THE Author)</author><thr:total>0</thr:total></item><item><guid isPermaLink="false">tag:blogger.com,1999:blog-2916649872140425333.post-2895030491652401753</guid><pubDate>Sun, 20 Mar 2011 10:26:00 +0000</pubDate><atom:updated>2011-09-30T21:06:49.074+05:30</atom:updated><category domain="http://www.blogger.com/atom/ns#">memory address</category><title>Memory Addresses</title><description>&lt;div dir=&quot;ltr&quot; style=&quot;text-align: left;&quot; trbidi=&quot;on&quot;&gt;  &lt;span style=&quot;font-size: small;&quot;&gt;&lt;br /&gt;&lt;/span&gt;&lt;div style=&quot;text-align: left;&quot;&gt;&lt;span style=&quot;font-size: small;&quot;&gt;&lt;span style=&quot;color: #006600; font-family: Verdana; font-weight: bold;&quot;&gt;1.Storage cells are typically viewed as being byte-sized&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;color: #000066; font-family: Verdana; font-weight: bold;&quot;&gt;&amp;nbsp;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;text-align: left;&quot;&gt;&lt;span style=&quot;font-size: small;&quot;&gt;&lt;span style=&quot;color: #000066; font-family: Verdana; font-weight: bold;&quot;&gt;Usually the smallest addressable unit of memory&lt;/span&gt;&lt;br /&gt;&lt;span&gt;&amp;nbsp;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;text-align: left;&quot;&gt;&lt;span style=&quot;font-size: small;&quot;&gt;&lt;span&gt;•&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Verdana; font-weight: bold;&quot;&gt;Few machines can directly access bits individually&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;color: #000066; font-family: Verdana; font-weight: bold;&quot;&gt;&amp;nbsp;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;text-align: left;&quot;&gt;&lt;span style=&quot;font-size: small;&quot;&gt;&lt;span style=&quot;color: #000066; font-family: Verdana; font-weight: bold;&quot;&gt;Such addresses are sometimes called &lt;/span&gt;&lt;span style=&quot;color: #000066; font-family: Verdana; font-style: italic; font-weight: bold;&quot;&gt;byte-addresses&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;color: #006600; font-family: Verdana; font-weight: bold;&quot;&gt;&amp;nbsp;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;text-align: left;&quot;&gt;&lt;span style=&quot;font-size: small;&quot;&gt;&lt;span style=&quot;color: #006600; font-family: Verdana; font-weight: bold;&quot;&gt;2.Memory is often accessed as words&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;text-align: left;&quot;&gt;&lt;span style=&quot;font-size: small;&quot;&gt;&lt;span style=&quot;color: #006600; font-family: Verdana; font-weight: bold;&quot;&gt;&amp;nbsp;&lt;/span&gt;&lt;span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;text-align: left;&quot;&gt;&lt;span style=&quot;font-size: small;&quot;&gt;&lt;span&gt;&lt;span style=&quot;font-family: Wingdings;&quot;&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;text-align: left;&quot;&gt;&lt;span style=&quot;font-size: small;&quot;&gt;&lt;span&gt;&lt;span style=&quot;font-family: Wingdings;&quot;&gt;&lt;/span&gt;&lt;/span&gt;&lt;span style=&quot;color: #000066; font-family: Verdana; font-weight: bold;&quot;&gt;Usually a word is the largest unit of memory access by a single machine instruction&lt;/span&gt;&lt;br /&gt;&lt;span&gt;&amp;nbsp;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;text-align: left;&quot;&gt;&lt;span style=&quot;font-size: small;&quot;&gt;&lt;span&gt;&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Verdana; font-weight: bold;&quot;&gt;CLEAR’s word size is 8 bytes (= &lt;/span&gt;&lt;span style=&quot;color: black; font-family: &amp;quot;Courier New&amp;quot;; font-weight: bold;&quot;&gt;sizeof&lt;/span&gt;&lt;span style=&quot;color: black; font-family: &amp;quot;Courier New&amp;quot;; font-weight: bold;&quot;&gt;(long)&lt;/span&gt;&lt;span style=&quot;color: black; font-family: Verdana; font-weight: bold;&quot;&gt;)&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;text-align: left;&quot;&gt;&lt;span style=&quot;font-size: small;&quot;&gt;&lt;span style=&quot;color: black; font-family: Verdana; font-weight: bold;&quot;&gt;&amp;nbsp;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;text-align: left;&quot;&gt;&lt;span style=&quot;font-size: small;&quot;&gt;&lt;span style=&quot;color: black; font-family: Verdana; font-weight: bold;&quot;&gt;&amp;nbsp;&lt;/span&gt;&lt;span&gt;&lt;span style=&quot;font-family: Wingdings;&quot;&gt;&lt;/span&gt;&lt;/span&gt;&lt;span style=&quot;color: #000066; font-family: Verdana; font-weight: bold;&quot;&gt;A &lt;/span&gt;&lt;span style=&quot;color: #000066; font-family: Verdana; font-style: italic; font-weight: bold;&quot;&gt;word-address&lt;/span&gt;&lt;span style=&quot;color: #000066; font-family: Verdana; font-weight: bold;&quot;&gt; is simply the byte-address of the word’s first byte&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;/div&gt;&lt;div class=&quot;blogger-post-footer&quot;&gt;For more detailed version visit http://programmingwithme.blogspot.com&lt;/div&gt;</description><link>http://programmingwithme.blogspot.com/2011/03/memory-addresses.html</link><author>noreply@blogger.com (THE Author)</author><thr:total>0</thr:total></item><item><guid isPermaLink="false">tag:blogger.com,1999:blog-2916649872140425333.post-1487649237153433805</guid><pubDate>Sun, 20 Mar 2011 10:21:00 +0000</pubDate><atom:updated>2011-09-30T21:06:48.995+05:30</atom:updated><title>Expressions</title><description>&lt;div dir=&quot;ltr&quot; style=&quot;text-align: left;&quot; trbidi=&quot;on&quot;&gt;•Constant&lt;br /&gt;–25+5&lt;br /&gt;&lt;br /&gt;•Integral&lt;br /&gt;–M*x assume M and x are both integer&lt;br /&gt;&lt;br /&gt;•Float&lt;br /&gt;–Sum/9&lt;br /&gt;&lt;br /&gt;•Pointer&lt;br /&gt;–Ptr++&lt;br /&gt;&lt;br /&gt;•Relational&lt;br /&gt;–X&amp;lt;=y&lt;br /&gt;&lt;br /&gt;•Logical&lt;br /&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;–A&amp;gt;b &amp;amp;&amp;amp; b&amp;lt;c&lt;/div&gt;&lt;/div&gt;&lt;div class=&quot;blogger-post-footer&quot;&gt;For more detailed version visit http://programmingwithme.blogspot.com&lt;/div&gt;</description><link>http://programmingwithme.blogspot.com/2011/03/expressions.html</link><author>noreply@blogger.com (THE Author)</author><thr:total>0</thr:total></item><item><guid isPermaLink="false">tag:blogger.com,1999:blog-2916649872140425333.post-937167676269688143</guid><pubDate>Sun, 20 Mar 2011 10:20:00 +0000</pubDate><atom:updated>2011-09-30T21:06:49.235+05:30</atom:updated><title>Data types and operators</title><description>&lt;div dir=&quot;ltr&quot; style=&quot;text-align: left;&quot; trbidi=&quot;on&quot;&gt;&lt;br /&gt;•Built-in type&lt;br /&gt;–Integer,float,charetc.&lt;br /&gt;•Derived data types&lt;br /&gt;–Array,pointeretc.&lt;br /&gt;•User defined data type&lt;br /&gt;–Structure, union, class, enumeration.&lt;br /&gt;•Operators&lt;br /&gt;–Arithmetic&lt;br /&gt;–Assignment&lt;br /&gt;–Increment/decrement&lt;br /&gt;–Unary&lt;br /&gt;–Relational&lt;br /&gt;–Ternary&lt;br /&gt;–Logical&lt;br /&gt;–bitwise&lt;br /&gt;&lt;/div&gt;&lt;div class=&quot;blogger-post-footer&quot;&gt;For more detailed version visit http://programmingwithme.blogspot.com&lt;/div&gt;</description><link>http://programmingwithme.blogspot.com/2011/03/data-types-and-operators.html</link><author>noreply@blogger.com (THE Author)</author><thr:total>0</thr:total></item><item><guid isPermaLink="false">tag:blogger.com,1999:blog-2916649872140425333.post-9144311744536396477</guid><pubDate>Sun, 20 Mar 2011 10:18:00 +0000</pubDate><atom:updated>2011-09-30T21:06:49.219+05:30</atom:updated><title>Basic Commands</title><description>&lt;div dir=&quot;ltr&quot; style=&quot;text-align: left;&quot; trbidi=&quot;on&quot;&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;C statement&lt;/div&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;Printf(“%d”,a); //to print variable &quot;a&quot;&lt;/div&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;&lt;br /&gt;&lt;/div&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;Equivalent C++ statement &lt;/div&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;Cout&amp;lt;&amp;lt;a;&lt;/div&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;&lt;br /&gt;C statement &lt;/div&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;Scanf(“%f”,&amp;amp;average); //to get the value and store in vaiable &quot;average&quot;&lt;/div&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;&lt;br /&gt;Equivalent C++ statement &lt;/div&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;Cin&amp;gt;&amp;gt;average;&lt;/div&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;&lt;br /&gt;&lt;/div&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;C statement&lt;br /&gt;Printf(“total is %d this ”,sum);//to print the variable &#39;sum&#39;&lt;/div&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;&lt;br /&gt;Equivalent C++ statement &lt;/div&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;Cout&amp;lt;&amp;lt;“totalis“&amp;lt;&amp;lt;sum&amp;lt;&amp;lt;“ this”;&lt;/div&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;&lt;br /&gt;&lt;/div&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;&lt;/div&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;C statement&lt;br /&gt;Scanf(“%d %f”,&amp;amp;a,&amp;amp;x);//to get and store the value of vaeiables &#39;a&#39; and &#39;x&#39;&lt;/div&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;&lt;br /&gt;Equivalent C++ statement &lt;/div&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;Cin&amp;gt;&amp;gt;a&amp;gt;&amp;gt;x;&lt;/div&gt;&lt;/div&gt;&lt;div class=&quot;blogger-post-footer&quot;&gt;For more detailed version visit http://programmingwithme.blogspot.com&lt;/div&gt;</description><link>http://programmingwithme.blogspot.com/2011/03/basic-commands.html</link><author>noreply@blogger.com (THE Author)</author><thr:total>0</thr:total></item><item><guid isPermaLink="false">tag:blogger.com,1999:blog-2916649872140425333.post-2159825280271456735</guid><pubDate>Sun, 20 Mar 2011 10:07:00 +0000</pubDate><atom:updated>2011-09-30T21:06:49.051+05:30</atom:updated><title>GTU syllabus for OOCP</title><description>&lt;div dir=&quot;ltr&quot; style=&quot;text-align: left;&quot; trbidi=&quot;on&quot;&gt;Dear friends,if you are a GTU 4th sem student and OOCP is one of your subject,here is a link of your subject syllabus.Click &lt;a href=&quot;http://gtu.ac.in/syllabus/BE_IV_Elective/IT%20group.pdf&quot;&gt;here&lt;/a&gt; to download it.&lt;/div&gt;&lt;div class=&quot;blogger-post-footer&quot;&gt;For more detailed version visit http://programmingwithme.blogspot.com&lt;/div&gt;</description><link>http://programmingwithme.blogspot.com/2011/03/gtu-syllabus-for-oocp.html</link><author>noreply@blogger.com (THE Author)</author><thr:total>0</thr:total></item><item><guid isPermaLink="false">tag:blogger.com,1999:blog-2916649872140425333.post-2941670432568122104</guid><pubDate>Sun, 20 Mar 2011 09:59:00 +0000</pubDate><atom:updated>2011-09-30T21:06:49.079+05:30</atom:updated><title>Introduction of C++</title><description>&lt;div dir=&quot;ltr&quot; style=&quot;text-align: left;&quot; trbidi=&quot;on&quot;&gt;C++ was developed by Bjarne Stroustrup of AT&amp;amp;T to add objectoriented&lt;br /&gt;constructs to the C language. Because object-oriented&lt;br /&gt;methodology was relatively new at the time, and all existing&lt;br /&gt;implementations of object-oriented languages were rather slow and&lt;br /&gt;inefficient (most were interpreters), one goal of C++ was to maintain&lt;br /&gt;the efficiency of C.&lt;/div&gt;&lt;div class=&quot;blogger-post-footer&quot;&gt;For more detailed version visit http://programmingwithme.blogspot.com&lt;/div&gt;</description><link>http://programmingwithme.blogspot.com/2011/03/introduction-of-c.html</link><author>noreply@blogger.com (THE Author)</author><thr:total>0</thr:total></item><item><guid isPermaLink="false">tag:blogger.com,1999:blog-2916649872140425333.post-7663775033363539472</guid><pubDate>Sat, 19 Mar 2011 16:32:00 +0000</pubDate><atom:updated>2011-09-30T21:06:49.202+05:30</atom:updated><title>Write a program to create linear linked list interactively and print out the list and total number of items in the list.</title><description>&lt;div dir=&quot;ltr&quot; style=&quot;text-align: left;&quot; trbidi=&quot;on&quot;&gt;&lt;br /&gt;#include&amp;lt;stdio.h&amp;gt;&lt;br /&gt;#include&amp;lt;conio.h&amp;gt;&lt;br /&gt;#include&amp;lt;process.h&amp;gt;&lt;br /&gt;#include&amp;lt;stdlib.h&amp;gt;&lt;br /&gt;struct node&lt;br /&gt;{&lt;br /&gt;int info;&lt;br /&gt;struct node *next;&lt;br /&gt;}*head,*last,*temp,*n;&lt;br /&gt;void menu(); // to select the choise&lt;br /&gt;void create(); // insert at last&lt;br /&gt;void display(); // to print the link list&lt;br /&gt;int i;&lt;br /&gt;void main()&lt;br /&gt;{&lt;br /&gt;i=0;&lt;br /&gt;clrscr();&lt;br /&gt;menu();&lt;br /&gt;getch();&lt;br /&gt;}&lt;br /&gt;void menu()&lt;br /&gt;{&lt;br /&gt;int ch;&lt;br /&gt;printf(&quot;1. Create\n&quot;);&lt;br /&gt;printf(&quot;2. Display\n&quot;);&lt;br /&gt;printf(&quot;3. Exit\n&quot;);&lt;br /&gt;printf(&quot;Enter choise : &quot;);&lt;br /&gt;scanf(&quot;%d&quot;,&amp;amp;ch);&lt;br /&gt;switch(ch)&lt;br /&gt;{&lt;br /&gt;case 1 : create();&lt;br /&gt;case 2 : display();&lt;br /&gt;case 3 : printf(&quot;You have choose to exit\n&quot;);&lt;br /&gt;getch(); exit(0);&lt;br /&gt;default : printf(&quot;Invalid choise\n&quot;); menu();&lt;br /&gt;}&lt;br /&gt;}&lt;br /&gt;void create()&lt;br /&gt;{&lt;br /&gt;n= new node;&lt;br /&gt;printf(&quot;Enter the information : &quot;);&lt;br /&gt;scanf(&quot;%d&quot;,&amp;amp;n-&amp;gt;info);&lt;br /&gt;if(i==0)&lt;br /&gt;{&lt;br /&gt;head=n;&lt;br /&gt;i++;&lt;br /&gt;}&lt;br /&gt;else&lt;br /&gt;{&lt;br /&gt;last-&amp;gt;next=n;&lt;br /&gt;i++;&lt;br /&gt;}&lt;br /&gt;last=n;&lt;br /&gt;last-&amp;gt;next=NULL;&lt;br /&gt;menu();&lt;br /&gt;}&lt;br /&gt;void display()&lt;br /&gt;{&lt;br /&gt;if(head==NULL)&lt;br /&gt;{&lt;br /&gt;printf(&quot;No information in list\n&quot;);&lt;br /&gt;menu();&lt;br /&gt;}&lt;br /&gt;temp=head;&lt;br /&gt;while(temp!=NULL)&lt;br /&gt;{&lt;br /&gt;printf(&quot;%d-&amp;gt;&quot;,temp-&amp;gt;info);&lt;br /&gt;temp=temp-&amp;gt;next;&lt;br /&gt;}&lt;br /&gt;printf(&quot;\n&quot;);&lt;br /&gt;printf(&quot;Total number of elements in the link list are : %d\n&quot;,i);&lt;br /&gt;menu();&lt;br /&gt;}&lt;br /&gt;Output:&lt;br /&gt;1. Create&lt;br /&gt;2. Display&lt;br /&gt;3. Exit&lt;br /&gt;Enter choise : 1&lt;br /&gt;Enter the information : 12&lt;br /&gt;1. Create&lt;br /&gt;2. Display&lt;br /&gt;3. Exit&lt;br /&gt;Enter choise : 1&lt;br /&gt;Enter the information : 23&lt;br /&gt;1. Create&lt;br /&gt;2. Display&lt;br /&gt;3. Exit&lt;br /&gt;Enter choise : 1&lt;br /&gt;Enter the information : 45&lt;br /&gt;1. Create&lt;br /&gt;2. Display&lt;br /&gt;3. Exit&lt;br /&gt;Enter choise : 2&lt;br /&gt;12-&amp;gt;23-&amp;gt;45-&amp;gt;&lt;br /&gt;Total number of elements in the link list are : 3&lt;br /&gt;1. Create&lt;br /&gt;2. Display&lt;br /&gt;3. Exit&lt;br /&gt;Enter choise : 3&lt;br /&gt;You have choose to exit&lt;br /&gt;&lt;/div&gt;&lt;div class=&quot;blogger-post-footer&quot;&gt;For more detailed version visit http://programmingwithme.blogspot.com&lt;/div&gt;</description><link>http://programmingwithme.blogspot.com/2011/03/write-program-to-create-linear-linked.html</link><author>noreply@blogger.com (THE Author)</author><thr:total>0</thr:total></item><item><guid isPermaLink="false">tag:blogger.com,1999:blog-2916649872140425333.post-573935660251011205</guid><pubDate>Sat, 19 Mar 2011 16:31:00 +0000</pubDate><atom:updated>2011-09-30T21:06:49.149+05:30</atom:updated><title>Write a program to read data from keyboard, write it to a file named STUDENT again read the same data from STUDENT file and write it into DATA file. Same data should be displayed on the screen</title><description>&lt;div dir=&quot;ltr&quot; style=&quot;text-align: left;&quot; trbidi=&quot;on&quot;&gt;&lt;br /&gt;#include&amp;lt;stdio.h&amp;gt;&lt;br /&gt;#include&amp;lt;conio.h&amp;gt;&lt;br /&gt;#include&amp;lt;process.h&amp;gt;&lt;br /&gt;struct stud&lt;br /&gt;{&lt;br /&gt;int rno;&lt;br /&gt;char *nm;&lt;br /&gt;};&lt;br /&gt;void main()&lt;br /&gt;{&lt;br /&gt;struct stud *s;&lt;br /&gt;int n,i;&lt;br /&gt;FILE *fp,*fp1;&lt;br /&gt;clrscr();&lt;br /&gt;printf(&quot;Enter how many record you want to input : &quot;);&lt;br /&gt;scanf(&quot;%d&quot;,&amp;amp;n);&lt;br /&gt;s=(struct stud *)malloc(n*sizeof(struct stud));&lt;br /&gt;fp=fopen(&quot;STUD.txt&quot;,&quot;w&quot;);&lt;br /&gt;for(i=0;i&amp;lt;n;i++)&lt;br /&gt;{&lt;br /&gt;printf(&quot;\n\tInformation for student : %d\n&quot;,i+1);&lt;br /&gt;printf(&quot;Enter Roll No : &quot;);&lt;br /&gt;scanf(&quot;%d&quot;,&amp;amp;s[i].rno);&lt;br /&gt;printf(&quot;Enter Name : &quot;);&lt;br /&gt;fflush(stdin);&lt;br /&gt;gets(s[i].nm);&lt;br /&gt;fprintf(fp,&quot;%5d %-20s\n&quot;,s[i].rno,s[i].nm);&lt;br /&gt;}&lt;br /&gt;fclose(fp);&lt;br /&gt;fp=fopen(&quot;STUD.txt&quot;,&quot;r&quot;);&lt;br /&gt;fp1=fopen(&quot;DATA.txt&quot;,&quot;w&quot;);&lt;br /&gt;printf(&quot;\nContent of the STUD.txt file is\n&quot;);&lt;br /&gt;printf(&quot;Roll No Name\n&quot;);&lt;br /&gt;printf(&quot;---------------------------\n&quot;);&lt;br /&gt;while(!feof(fp))&lt;br /&gt;{&lt;br /&gt;fscanf(fp,&quot;%5d %20s\n&quot;,&amp;amp;s[i].rno,s[i].nm);&lt;br /&gt;fprintf(fp1,&quot;%5d %-20s\n&quot;,s[i].rno,s[i].nm);&lt;br /&gt;printf(&quot;%7d %-20s\n&quot;,s[i].rno,s[i].nm);&lt;br /&gt;}&lt;br /&gt;fcloseall();&lt;br /&gt;getch();&lt;br /&gt;}&lt;br /&gt;Output:&lt;br /&gt;Enter how many record you want to input : 3&lt;br /&gt;Information for student : 1&lt;br /&gt;Enter Roll No : 1&lt;br /&gt;Enter Name : happy&lt;br /&gt;Information for student : 2&lt;br /&gt;Enter Roll No : 2&lt;br /&gt;Enter Name : Umesh&lt;br /&gt;Information for student : 3&lt;br /&gt;Enter Roll No : 3&lt;br /&gt;Enter Name : Mehul&lt;br /&gt;Content of the STUD.txt file is&lt;br /&gt;Roll No Name&lt;br /&gt;---------------------------&lt;br /&gt;1 happy&lt;br /&gt;2 Umesh&lt;br /&gt;3 Mehul&lt;br /&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;/div&gt;&lt;div class=&quot;blogger-post-footer&quot;&gt;For more detailed version visit http://programmingwithme.blogspot.com&lt;/div&gt;</description><link>http://programmingwithme.blogspot.com/2011/03/write-program-to-read-data-from.html</link><author>noreply@blogger.com (THE Author)</author><thr:total>0</thr:total></item><item><guid isPermaLink="false">tag:blogger.com,1999:blog-2916649872140425333.post-4650897333434995414</guid><pubDate>Sat, 19 Mar 2011 16:29:00 +0000</pubDate><atom:updated>2011-09-30T21:06:49.115+05:30</atom:updated><title>Write a function using pointers to add two matrices and to return the resultant matrix to the calling function.</title><description>&lt;div dir=&quot;ltr&quot; style=&quot;text-align: left;&quot; trbidi=&quot;on&quot;&gt;&lt;br /&gt;#include&amp;lt;stdio.h&amp;gt;&lt;br /&gt;#include&amp;lt;conio.h&amp;gt;&lt;br /&gt;int a[5][5],b[5][5],row,col;&lt;br /&gt;void add(int(*)[5]);&lt;br /&gt;int main()&lt;br /&gt;{&lt;br /&gt;int c[5][5],i,j;&lt;br /&gt;clrscr();&lt;br /&gt;printf(&quot;Enter row : &quot;);&lt;br /&gt;scanf(&quot;%d&quot;,&amp;amp;row);&lt;br /&gt;printf(&quot;Enter column : &quot;);&lt;br /&gt;scanf(&quot;%d&quot;,&amp;amp;col);&lt;br /&gt;printf(&quot;Enter matrix A :\n&quot;);&lt;br /&gt;for(i=0;i&amp;lt;row;i++)&lt;br /&gt;{&lt;br /&gt;for(j=0;j&amp;lt;col;j++)&lt;br /&gt;{&lt;br /&gt;scanf(&quot;%d&quot;,&amp;amp;a[i][j]);&lt;br /&gt;}&lt;br /&gt;}&lt;br /&gt;printf(&quot;Enter matrix B :\n&quot;);&lt;br /&gt;for(i=0;i&amp;lt;row;i++)&lt;br /&gt;{&lt;br /&gt;for(j=0;j&amp;lt;col;j++)&lt;br /&gt;{&lt;br /&gt;scanf(&quot;%d&quot;,&amp;amp;b[i][j]);&lt;br /&gt;}&lt;br /&gt;}&lt;br /&gt;add(c);&lt;br /&gt;printf(&quot;Addition :\n&quot;);&lt;br /&gt;for(i=0;i&amp;lt;row;i++)&lt;br /&gt;{&lt;br /&gt;for(j=0;j&amp;lt;col;j++)&lt;br /&gt;{&lt;br /&gt;printf(&quot;%d\t&quot;,c[i][j]);&lt;br /&gt;}&lt;br /&gt;printf(&quot;\n&quot;);&lt;br /&gt;}&lt;br /&gt;getch();&lt;br /&gt;return 0;&lt;br /&gt;}&lt;br /&gt;void add(int c[5][5])&lt;br /&gt;{&lt;br /&gt;int i,j;&lt;br /&gt;for(i=0;i&amp;lt;row;i++)&lt;br /&gt;{&lt;br /&gt;for(j=0;j&amp;lt;col;j++)&lt;br /&gt;{&lt;br /&gt;c[i][j]=a[i][j]+b[i][j];&lt;br /&gt;}&lt;br /&gt;}&lt;br /&gt;}&lt;br /&gt;/*&lt;br /&gt;Enter row : 3&lt;br /&gt;Enter column : 3&lt;br /&gt;Enter matrix A :&lt;br /&gt;333&lt;br /&gt;333&lt;br /&gt;333&lt;br /&gt;Enter matrix B :&lt;br /&gt;555&lt;br /&gt;555&lt;br /&gt;555&lt;br /&gt;Addition :&lt;br /&gt;8&lt;br /&gt;8&lt;br /&gt;8&lt;br /&gt;8&lt;br /&gt;8&lt;br /&gt;8&lt;br /&gt;8&lt;br /&gt;8&lt;br /&gt;8&lt;br /&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;/div&gt;&lt;div class=&quot;blogger-post-footer&quot;&gt;For more detailed version visit http://programmingwithme.blogspot.com&lt;/div&gt;</description><link>http://programmingwithme.blogspot.com/2011/03/write-function-using-pointers-to-add.html</link><author>noreply@blogger.com (THE Author)</author><thr:total>0</thr:total></item><item><guid isPermaLink="false">tag:blogger.com,1999:blog-2916649872140425333.post-433883848461473747</guid><pubDate>Sat, 12 Mar 2011 10:31:00 +0000</pubDate><atom:updated>2011-09-30T21:06:49.104+05:30</atom:updated><title>Write a function to calculate the roots of the quadratic equation. The function must use two pointer parameters, one to receive the coefficients a, b, and c, and the other to send the roots to the calling function</title><description>&lt;div dir=&quot;ltr&quot; style=&quot;text-align: left;&quot; trbidi=&quot;on&quot;&gt;#include&amp;lt;stdio.h&amp;gt;&lt;br /&gt;#include&amp;lt;conio.h&amp;gt;&lt;br /&gt;void solve(int*,float*);&lt;br /&gt;int main()&lt;br /&gt;{&lt;br /&gt;int a[3];&lt;br /&gt;float *root;&lt;br /&gt;clrscr();&lt;br /&gt;printf(&quot;Enter the value of A : &quot;);&lt;br /&gt;scanf(&quot;%d&quot;,&amp;amp;a[0]);&lt;br /&gt;printf(&quot;Enter the value of B : &quot;);&lt;br /&gt;scanf(&quot;%d&quot;,&amp;amp;a[1]);&lt;br /&gt;printf(&quot;Enter the value of C : &quot;);&lt;br /&gt;scanf(&quot;%d&quot;,&amp;amp;a[2]);&lt;br /&gt;solve(a,root);&lt;br /&gt;if(root==NULL)&lt;br /&gt;printf(&quot;The root is not possible\n&quot;);&lt;br /&gt;else if(root[0]==root[1])&lt;br /&gt;printf(&quot;The root is %.2f\n&quot;,root[0]);&lt;br /&gt;else&lt;br /&gt;printf(&quot;The roots are %.2f &amp;amp; %.2f\n&quot;,root[0],root[1]);&lt;br /&gt;getch();&lt;br /&gt;return 0;&lt;br /&gt;}&lt;br /&gt;void solve(int *a,float *r)&lt;br /&gt;{&lt;br /&gt;float d;&lt;br /&gt;d=a[1]*a[1]-4*a[0]*a[2];&lt;br /&gt;if(d&amp;lt;0)&lt;br /&gt;{&lt;br /&gt;r=NULL;&lt;br /&gt;}&lt;br /&gt;else if(d==0)&lt;br /&gt;{&lt;br /&gt;r[0]=r[1]=-a[1]/(2*a[0]);&lt;br /&gt;}&lt;br /&gt;else&lt;br /&gt;{&lt;br /&gt;r[0]=-a[1]/(2*a[0]);&lt;br /&gt;r[1]=-a[1]/(2*a[0]);&lt;br /&gt;}&lt;br /&gt;}&lt;br /&gt;Output:&lt;br /&gt;Enter the value of A : 1&lt;br /&gt;Enter the value of B : -4&lt;br /&gt;Enter the value of C : 4&lt;br /&gt;The root is 2.00&lt;/div&gt;&lt;div class=&quot;blogger-post-footer&quot;&gt;For more detailed version visit http://programmingwithme.blogspot.com&lt;/div&gt;</description><link>http://programmingwithme.blogspot.com/2011/03/write-function-to-calculate-roots-of.html</link><author>noreply@blogger.com (THE Author)</author><thr:total>0</thr:total></item><item><guid isPermaLink="false">tag:blogger.com,1999:blog-2916649872140425333.post-6235581999891734163</guid><pubDate>Sat, 12 Mar 2011 10:24:00 +0000</pubDate><atom:updated>2011-09-30T21:06:49.172+05:30</atom:updated><title>Write a program using pointers to read an array of integers and print its elements in reverse order</title><description>&lt;div dir=&quot;ltr&quot; style=&quot;text-align: left;&quot; trbidi=&quot;on&quot;&gt;#include&amp;lt;conio.h&amp;gt;&lt;br /&gt;#include&amp;lt;stdio.h&amp;gt;&lt;br /&gt;#include&amp;lt;stdlib.h&amp;gt;&lt;br /&gt;int main()&lt;br /&gt;{&lt;br /&gt;int *ptr,i,n;&lt;br /&gt;clrscr();&lt;br /&gt;printf(&quot;Enter the no of elements:&quot;);&lt;br /&gt;scanf(&quot;%d&quot;,&amp;amp;n);&lt;br /&gt;ptr=(int *)malloc(sizeof(int)*n);&lt;br /&gt;if(ptr==NULL)&lt;br /&gt;{&lt;br /&gt;printf(&quot;Not enough memory&quot;);&lt;br /&gt;exit(1);&lt;br /&gt;}&lt;br /&gt;for(i=0; i&amp;lt;n; i++)&lt;br /&gt;{&lt;br /&gt;printf(&quot;Enter %d element : &quot;,i+1);&lt;br /&gt;scanf(&quot;%d&quot;,&amp;amp;ptr[i]);&lt;br /&gt;}&lt;br /&gt;printf(&quot;Array in original order\n&quot;);&lt;br /&gt;for(i=0; i&amp;lt;n; i++)&lt;br /&gt;{&lt;br /&gt;printf(&quot;%d\n&quot;,ptr[i]);&lt;br /&gt;}&lt;br /&gt;printf(&quot;Array in reverse order\n&quot;);&lt;br /&gt;for(i=n-1; i&amp;gt;=0; i--)&lt;br /&gt;{&lt;br /&gt;printf(&quot;%d\n&quot;,ptr[i]);&lt;br /&gt;}&lt;br /&gt;getch();&lt;br /&gt;return 0;&lt;br /&gt;}&lt;br /&gt;Output:&lt;br /&gt;Enter the no of elements:5&lt;br /&gt;Enter 1 element : 12&lt;br /&gt;Enter 2 element : 56&lt;br /&gt;Enter 3 element : 89&lt;br /&gt;Enter 4 element : 45&lt;br /&gt;Enter 5 element : 23&lt;br /&gt;Array in original order&lt;br /&gt;12&lt;br /&gt;56&lt;br /&gt;89&lt;br /&gt;45&lt;br /&gt;23&lt;br /&gt;Array in reverse order&lt;br /&gt;23&lt;br /&gt;45&lt;br /&gt;89&lt;br /&gt;56&lt;br /&gt;12&lt;/div&gt;&lt;div class=&quot;blogger-post-footer&quot;&gt;For more detailed version visit http://programmingwithme.blogspot.com&lt;/div&gt;</description><link>http://programmingwithme.blogspot.com/2011/03/write-program-using-pointers-to-read.html</link><author>noreply@blogger.com (THE Author)</author><thr:total>0</thr:total></item><item><guid isPermaLink="false">tag:blogger.com,1999:blog-2916649872140425333.post-7299175571420910300</guid><pubDate>Sat, 12 Mar 2011 10:22:00 +0000</pubDate><atom:updated>2011-09-30T21:06:49.197+05:30</atom:updated><title>In a program declare following structure member: name, code, age, weight and height. Read all members of the structure for 100 persons and find list of persons with all related data whose weight &gt; 50 and height &gt; 40 and print the same with suitable format and title</title><description>&lt;div dir=&quot;ltr&quot; style=&quot;text-align: left;&quot; trbidi=&quot;on&quot;&gt;#include&amp;lt;stdio.h&amp;gt;&lt;br /&gt;#include&amp;lt;conio.h&amp;gt;&lt;br /&gt;#define size 3&lt;br /&gt;struct&lt;br /&gt;{&lt;br /&gt;char nm[20],cd;&lt;br /&gt;int height,age,weight;&lt;br /&gt;}s[size];&lt;br /&gt;int main()&lt;br /&gt;{&lt;br /&gt;int i;&lt;br /&gt;clrscr();&lt;br /&gt;for(i=0;i&amp;lt;size;i++)&lt;br /&gt;{&lt;br /&gt;printf(&quot;For person %d\n&quot;,i+1);&lt;br /&gt;printf(&quot;Enter the name : &quot;);&lt;br /&gt;fflush(stdin);&lt;br /&gt;gets(s[i].nm);&lt;br /&gt;printf(&quot;Enter the code : &quot;);&lt;br /&gt;flushall(.);&lt;br /&gt;s[i].cd=getc(stdin);&lt;br /&gt;printf(&quot;Enter the age : &quot;);&lt;br /&gt;fflush(stdin);&lt;br /&gt;scanf(&quot;%d&quot;,&amp;amp;s[i].age);&lt;br /&gt;printf(&quot;Enter the weight : &quot;);&lt;br /&gt;fflush(stdin);&lt;br /&gt;scanf(&quot;%d&quot;,&amp;amp;s[i].weight);&lt;br /&gt;printf(&quot;Enter the height : &quot;);&lt;br /&gt;fflush(stdin);&lt;br /&gt;scanf(&quot;%d&quot;,&amp;amp;s[i].height);&lt;br /&gt;}&lt;br /&gt;printf(&quot;\n\nData having weight&amp;gt;50 &amp;amp; height&amp;gt;40\n&quot;);&lt;br /&gt;printf(&quot;\nName Code Age Height Weight\n&quot;);&lt;br /&gt;printf(&quot;--------------------------------\n&quot;);&lt;br /&gt;for(i=0;i&amp;lt;size;i++)&lt;br /&gt;{&lt;br /&gt;if(s[i].weight&amp;gt;50 &amp;amp;&amp;amp; s[i].height&amp;gt;40)&lt;br /&gt;printf(&quot;%-10s%-5c%3d%7d%7d\n&quot;,&lt;br /&gt;s[i].nm,s[i].cd,s[i].age,s[i].height,s[i].weight);&lt;br /&gt;}&lt;br /&gt;getch();&lt;br /&gt;return 0;&lt;br /&gt;}&lt;br /&gt;Output:&lt;br /&gt;For person 1&lt;br /&gt;Enter the name : radhe&lt;br /&gt;Enter the code : D&lt;br /&gt;Enter the age : 21&lt;br /&gt;Enter the weight : 65&lt;br /&gt;Enter the height : 144&lt;br /&gt;For person 2&lt;br /&gt;Enter the name : Mehul&lt;br /&gt;Enter the code : R&lt;br /&gt;Enter the age : 22&lt;br /&gt;Enter the weight : 42&lt;br /&gt;Enter the height : 45&lt;br /&gt;For person 3&lt;br /&gt;Enter the name : Umesh&lt;br /&gt;Enter the code : S&lt;br /&gt;Enter the age : 21&lt;br /&gt;Enter the weight : 55&lt;br /&gt;Enter the height : 35&lt;br /&gt;Data having weight&amp;gt;50 &amp;amp; height&amp;gt;40&lt;br /&gt;Name Code Age Height Weight&lt;br /&gt;--------------------------------&lt;br /&gt;radhe D 21 144 65&lt;/div&gt;&lt;div class=&quot;blogger-post-footer&quot;&gt;For more detailed version visit http://programmingwithme.blogspot.com&lt;/div&gt;</description><link>http://programmingwithme.blogspot.com/2011/03/in-program-declare-following-structure.html</link><author>noreply@blogger.com (THE Author)</author><thr:total>0</thr:total></item><item><guid isPermaLink="false">tag:blogger.com,1999:blog-2916649872140425333.post-1444656175897545697</guid><pubDate>Sat, 12 Mar 2011 10:20:00 +0000</pubDate><atom:updated>2011-09-30T21:06:48.973+05:30</atom:updated><title>Define a structure called cricket that will describe the following information: Player name Team name Batting average Using cricket, declare an array player with 50 elements and wire a program to read the information about all the 50 players and print a list.</title><description>&lt;div dir=&quot;ltr&quot; style=&quot;text-align: left;&quot; trbidi=&quot;on&quot;&gt;#include&amp;lt;stdio.h&amp;gt;&lt;br /&gt;#include&amp;lt;conio.h&amp;gt;&lt;br /&gt;#include&amp;lt;string.h&amp;gt;&lt;br /&gt;struct cricket&lt;br /&gt;{&lt;br /&gt;char nm[20],team[20];&lt;br /&gt;int avg;&lt;br /&gt;};&lt;br /&gt;#define total 5&lt;br /&gt;int main()&lt;br /&gt;{&lt;br /&gt;struct cricket player[total],temp;&lt;br /&gt;int i,j;&lt;br /&gt;clrscr();&lt;br /&gt;for(i=0;i&amp;lt;total;i++)&lt;br /&gt;{&lt;br /&gt;printf(&quot;For player %d\n&quot;,i+1);&lt;br /&gt;printf(&quot;Enter the name of player : &quot;);&lt;br /&gt;fflush(stdin);&lt;br /&gt;gets(player[i].nm);&lt;br /&gt;printf(&quot;Enter the team : &quot;);&lt;br /&gt;fflush(stdin);&lt;br /&gt;gets(player[i].team);&lt;br /&gt;printf(&quot;Enter the batting average : &quot;);&lt;br /&gt;fflush(stdin);&lt;br /&gt;scanf(&quot;%d&quot;,&amp;amp;player[i].avg);&lt;br /&gt;}&lt;br /&gt;printf(&quot;\nTeam Name Average\n&quot;);&lt;br /&gt;printf(&quot; \n&quot;);&lt;br /&gt;for(i=0;i&amp;lt;total;i++)&lt;br /&gt;{&lt;br /&gt;printf(&quot;%-10s %-10s %7d\n&quot;,player[i].team,player[i].nm,player[i].avg);&lt;br /&gt;}&lt;br /&gt;getch();&lt;br /&gt;return 0;&lt;br /&gt;}&lt;br /&gt;Output:&lt;br /&gt;For player 1&lt;br /&gt;Enter the name of player : radhe&lt;br /&gt;Enter the team : India&lt;br /&gt;Enter the batting average : 100&lt;br /&gt;For player 2&lt;br /&gt;Enter the name of player : Tiwari&lt;br /&gt;Enter the team : Pakistan&lt;br /&gt;Enter the batting average : 5&lt;br /&gt;For player 3&lt;br /&gt;Enter the name of player : Tendulkar&lt;br /&gt;Enter the team : India&lt;br /&gt;Enter the batting average : 45&lt;br /&gt;For player 4&lt;br /&gt;Enter the name of player : Dhoni&lt;br /&gt;Enter the team : India&lt;br /&gt;Enter the batting average : 48&lt;br /&gt;For player 5&lt;br /&gt;Enter the name of player : Yuvi&lt;br /&gt;Enter the team : India&lt;br /&gt;Enter the batting average : 39&lt;br /&gt;Team Name Average&lt;br /&gt;-----------------------------&lt;br /&gt;India radhe 100&lt;br /&gt;Pakistan Tiwari 5&lt;br /&gt;India Tendulkar 45&lt;br /&gt;India Dhoni 48&lt;br /&gt;India Yuvi 39&lt;/div&gt;&lt;div class=&quot;blogger-post-footer&quot;&gt;For more detailed version visit http://programmingwithme.blogspot.com&lt;/div&gt;</description><link>http://programmingwithme.blogspot.com/2011/03/define-structure-called-cricket-that.html</link><author>noreply@blogger.com (THE Author)</author><thr:total>0</thr:total></item><item><guid isPermaLink="false">tag:blogger.com,1999:blog-2916649872140425333.post-1031090645283161991</guid><pubDate>Sat, 12 Mar 2011 10:18:00 +0000</pubDate><atom:updated>2011-09-30T21:06:48.944+05:30</atom:updated><title>Write a program that search an item from array of string</title><description>&lt;div dir=&quot;ltr&quot; style=&quot;text-align: left;&quot; trbidi=&quot;on&quot;&gt;#include&amp;lt;stdio.h&amp;gt;&lt;br /&gt;#include&amp;lt;conio.h&amp;gt;&lt;br /&gt;#include&amp;lt;string.h&amp;gt;&lt;br /&gt;int string(char[],char[]);&lt;br /&gt;int main()&lt;br /&gt;{&lt;br /&gt;char str[100],find[20];&lt;br /&gt;int i;&lt;br /&gt;clrscr();&lt;br /&gt;printf(&quot;Enter the string :&quot;);&lt;br /&gt;gets(str);&lt;br /&gt;printf(&quot;Enter the srting that you want to find : &quot;);&lt;br /&gt;gets(find);&lt;br /&gt;i=string(str,find);&lt;br /&gt;if(i==1)&lt;br /&gt;printf(&quot;%s is found in %s&quot;,find,str);&lt;br /&gt;else&lt;br /&gt;printf(&quot;%s is not found in %s&quot;,find,str);&lt;br /&gt;getch();&lt;br /&gt;return 0;&lt;br /&gt;}&lt;br /&gt;int string(char str[20], char find[20])&lt;br /&gt;{&lt;br /&gt;int i,j,flag;&lt;br /&gt;for(i=0;str[i];i++)&lt;br /&gt;{&lt;br /&gt;if(str[i]==find[0])&lt;br /&gt;{&lt;br /&gt;flag=1;&lt;br /&gt;for(j=1;find[j];j++)&lt;br /&gt;{&lt;br /&gt;if(str[i+j]!=find[j])&lt;br /&gt;{&lt;br /&gt;flag=0;&lt;br /&gt;break;&lt;br /&gt;}&lt;br /&gt;}&lt;br /&gt;if(flag==1)&lt;br /&gt;break;&lt;br /&gt;}&lt;br /&gt;}&lt;br /&gt;return flag;&lt;br /&gt;}&lt;br /&gt;Output:&lt;br /&gt;Enter the string :radhe&lt;br /&gt;Enter the string that you want to find : r&lt;br /&gt;r is found in string&lt;br /&gt;Enter the string :kano&lt;br /&gt;Enter the string that you want to find : z&lt;br /&gt;z is not found in kano&lt;/div&gt;&lt;div class=&quot;blogger-post-footer&quot;&gt;For more detailed version visit http://programmingwithme.blogspot.com&lt;/div&gt;</description><link>http://programmingwithme.blogspot.com/2011/03/write-program-that-search-item-from.html</link><author>noreply@blogger.com (THE Author)</author><thr:total>0</thr:total></item><item><guid isPermaLink="false">tag:blogger.com,1999:blog-2916649872140425333.post-1621683864487872654</guid><pubDate>Sat, 12 Mar 2011 10:16:00 +0000</pubDate><atom:updated>2011-09-30T21:06:49.020+05:30</atom:updated><title>Write a function to upper the string</title><description>&lt;div dir=&quot;ltr&quot; style=&quot;text-align: left;&quot; trbidi=&quot;on&quot;&gt;#include&amp;lt;stdio.h&amp;gt;&lt;br /&gt;#include&amp;lt;conio.h&amp;gt;&lt;br /&gt;void reverse(char[]);&lt;br /&gt;int main()&lt;br /&gt;{&lt;br /&gt;char str[20];&lt;br /&gt;clrscr();&lt;br /&gt;printf(&quot;Enter string : &quot;);&lt;br /&gt;gets(str);&lt;br /&gt;reverse(str);&lt;br /&gt;getch();&lt;br /&gt;return 0;&lt;br /&gt;}&lt;br /&gt;void reverse(char str[20])&lt;br /&gt;{&lt;br /&gt;int i;&lt;br /&gt;printf(&quot;%s in reverse order is &quot;,str);&lt;br /&gt;for(i=strlen(str)-1;i&amp;gt;=0;i--)&lt;br /&gt;printf(&quot;%c&quot;,str[i]);&lt;br /&gt;}&lt;br /&gt;Output:&lt;br /&gt;Enter string : radhe&lt;br /&gt;radhe in reverse order is ehdar&lt;/div&gt;&lt;div class=&quot;blogger-post-footer&quot;&gt;For more detailed version visit http://programmingwithme.blogspot.com&lt;/div&gt;</description><link>http://programmingwithme.blogspot.com/2011/03/write-function-to-upper-string.html</link><author>noreply@blogger.com (THE Author)</author><thr:total>0</thr:total></item><item><guid isPermaLink="false">tag:blogger.com,1999:blog-2916649872140425333.post-6776274927112298573</guid><pubDate>Sat, 12 Mar 2011 10:15:00 +0000</pubDate><atom:updated>2011-09-30T21:06:49.191+05:30</atom:updated><title>Write a function that will scan a character string passed as an argument and convert all lower-case character into their upper-case equivalent</title><description>&lt;div dir=&quot;ltr&quot; style=&quot;text-align: left;&quot; trbidi=&quot;on&quot;&gt;#include&amp;lt;stdio.h&amp;gt;&lt;br /&gt;#include&amp;lt;conio.h&amp;gt;&lt;br /&gt;void upper(char[]);&lt;br /&gt;int main()&lt;br /&gt;{&lt;br /&gt;char str[20];&lt;br /&gt;clrscr();&lt;br /&gt;printf(&quot;Enter string : &quot;);&lt;br /&gt;gets(str);&lt;br /&gt;upper(str);&lt;br /&gt;getch();&lt;br /&gt;return 0;&lt;br /&gt;}&lt;br /&gt;void upper(char str[20])&lt;br /&gt;{&lt;br /&gt;int i;&lt;br /&gt;printf(&quot;%s in upper case is &quot;,str);&lt;br /&gt;for(i=0;str[i];i++)&lt;br /&gt;{&lt;br /&gt;if(str[i]&amp;gt;96 &amp;amp;&amp;amp; str[i]&amp;lt;123)&lt;br /&gt;str[i]-=32;&lt;br /&gt;}&lt;br /&gt;printf(&quot;%s&quot;,str);&lt;br /&gt;}&lt;br /&gt;Output:&lt;br /&gt;Enter string :string&lt;br /&gt;string in upper case is STRING&lt;/div&gt;&lt;div class=&quot;blogger-post-footer&quot;&gt;For more detailed version visit http://programmingwithme.blogspot.com&lt;/div&gt;</description><link>http://programmingwithme.blogspot.com/2011/03/write-function-that-will-scan-character.html</link><author>noreply@blogger.com (THE Author)</author><thr:total>0</thr:total></item><item><guid isPermaLink="false">tag:blogger.com,1999:blog-2916649872140425333.post-1103545915906506983</guid><pubDate>Sat, 12 Mar 2011 10:14:00 +0000</pubDate><atom:updated>2011-09-30T21:06:48.956+05:30</atom:updated><title>Write a function which returns 1 if the given number is palindrome otherwise returns 0</title><description>&lt;div dir=&quot;ltr&quot; style=&quot;text-align: left;&quot; trbidi=&quot;on&quot;&gt;#include&amp;lt;stdio.h&amp;gt;&lt;br /&gt;#include&amp;lt;conio.h&amp;gt;&lt;br /&gt;int pelindrome(int);&lt;br /&gt;int main()&lt;br /&gt;{&lt;br /&gt;int n,p;&lt;br /&gt;clrscr();&lt;br /&gt;printf(&quot;Enter a number : &quot;);&lt;br /&gt;scanf(&quot;%d&quot;,&amp;amp;n);&lt;br /&gt;p=pelindrome(n);&lt;br /&gt;if(p==1)&lt;br /&gt;printf(&quot;%d is pelindrome&quot;,n);&lt;br /&gt;else&lt;br /&gt;printf(&quot;%d is not pelindrome&quot;,n);&lt;br /&gt;getch();&lt;br /&gt;return 0;&lt;br /&gt;}&lt;br /&gt;int pelindrome(int n)&lt;br /&gt;{&lt;br /&gt;char a[6],b[6];&lt;br /&gt;itoa(n,a,10);&lt;br /&gt;strcpy(b,a);&lt;br /&gt;strrev(b);&lt;br /&gt;if(strcmp(a,b)==0)&lt;br /&gt;return 1;&lt;br /&gt;else&lt;br /&gt;return 0;&lt;br /&gt;}&lt;br /&gt;Output:&lt;br /&gt;Enter a number : 123&lt;br /&gt;123 is not pelindrome&lt;br /&gt;Enter a number : 121&lt;br /&gt;121 is palindrome&lt;/div&gt;&lt;div class=&quot;blogger-post-footer&quot;&gt;For more detailed version visit http://programmingwithme.blogspot.com&lt;/div&gt;</description><link>http://programmingwithme.blogspot.com/2011/03/write-function-which-returns-1-if-given.html</link><author>noreply@blogger.com (THE Author)</author><thr:total>0</thr:total></item><item><guid isPermaLink="false">tag:blogger.com,1999:blog-2916649872140425333.post-6347382853711741727</guid><pubDate>Sat, 12 Mar 2011 10:13:00 +0000</pubDate><atom:updated>2011-09-30T21:06:49.177+05:30</atom:updated><title>Write a function prime that returns 1 if its argument is a prime no. and returns 0 otherwise</title><description>&lt;div dir=&quot;ltr&quot; style=&quot;text-align: left;&quot; trbidi=&quot;on&quot;&gt;#include&amp;lt;stdio.h&amp;gt;&lt;br /&gt;#include&amp;lt;conio.h&amp;gt;&lt;br /&gt;int prime(int);&lt;br /&gt;int main()&lt;br /&gt;{&lt;br /&gt;int n,p;&lt;br /&gt;clrscr();&lt;br /&gt;printf(&quot;Enter a number : &quot;);&lt;br /&gt;scanf(&quot;%d&quot;,&amp;amp;n);&lt;br /&gt;p=prime(n);&lt;br /&gt;if(p==1)&lt;br /&gt;printf(&quot;%d is prime\n&quot;,n);&lt;br /&gt;else&lt;br /&gt;printf(&quot;%d is not prime\n&quot;,n);&lt;br /&gt;getch();&lt;br /&gt;return 0;&lt;br /&gt;}&lt;br /&gt;int prime(int n)&lt;br /&gt;{&lt;br /&gt;int i;&lt;br /&gt;for(i=2;i&amp;lt;n;i++)&lt;br /&gt;{&lt;br /&gt;if(n%i==0)&lt;br /&gt;return 0;&lt;br /&gt;}&lt;br /&gt;return 1;&lt;br /&gt;}&lt;br /&gt;Output:&lt;br /&gt;Enter a number : 18&lt;br /&gt;18 is not prime&lt;br /&gt;Enter a number : 5&lt;br /&gt;5 is prime&lt;/div&gt;&lt;div class=&quot;blogger-post-footer&quot;&gt;For more detailed version visit http://programmingwithme.blogspot.com&lt;/div&gt;</description><link>http://programmingwithme.blogspot.com/2011/03/write-function-prime-that-returns-1-if.html</link><author>noreply@blogger.com (THE Author)</author><thr:total>0</thr:total></item><item><guid isPermaLink="false">tag:blogger.com,1999:blog-2916649872140425333.post-8796073195703657273</guid><pubDate>Sat, 12 Mar 2011 10:11:00 +0000</pubDate><atom:updated>2011-09-30T21:07:13.129+05:30</atom:updated><title>Use recursive calls to evaluate f(x) = x – x3/3! + x5/5! – x7/7! + ……</title><description>&lt;div dir=&quot;ltr&quot; style=&quot;text-align: left;&quot; trbidi=&quot;on&quot;&gt;#include&amp;lt;stdio.h&amp;gt;&lt;br /&gt;#include&amp;lt;conio.h&amp;gt;&lt;br /&gt;int main()&lt;br /&gt;{&lt;br /&gt;float series(float,int),x;&lt;br /&gt;int n;&lt;br /&gt;clrscr();&lt;br /&gt;printf(&quot;\nEnter X:&quot;);&lt;br /&gt;scanf(&quot;%f&quot;,&amp;amp;x);&lt;br /&gt;printf(&quot;\nEnter n:&quot;);&lt;br /&gt;scanf(&quot;%d&quot;,&amp;amp;n);&lt;br /&gt;printf(&quot;\nAns %f&quot;,series(x,n));&lt;br /&gt;getch();&lt;br /&gt;return 0;&lt;br /&gt;}&lt;br /&gt;float series(float x,int n)&lt;br /&gt;{&lt;br /&gt;long factorial(int);&lt;br /&gt;float power(float,int);&lt;br /&gt;float sum=0;&lt;br /&gt;int i,s=1;&lt;br /&gt;for(i=1;i&amp;lt;=n;i+=2)&lt;br /&gt;{&lt;br /&gt;sum+=(power(x,i)/factorial(i))*s;&lt;br /&gt;s*=-1;&lt;br /&gt;}&lt;br /&gt;return sum;&lt;br /&gt;}&lt;br /&gt;float power(float x, int y)&lt;br /&gt;{&lt;br /&gt;float p=1;&lt;br /&gt;int i;&lt;br /&gt;for(i=1;i&amp;lt;=y;i++)p*=x;&lt;br /&gt;return p;&lt;br /&gt;}&lt;br /&gt;long factorial(int p)&lt;br /&gt;{&lt;br /&gt;long f=1;&lt;br /&gt;int i;&lt;br /&gt;for(i=1;i&amp;lt;=p;i++)f*=i;&lt;br /&gt;return f;&lt;br /&gt;}&lt;br /&gt;Output&lt;br /&gt;Enter X:1.2&lt;br /&gt;Enter n:5&lt;br /&gt;Ans 0.932736&lt;/div&gt;&lt;div class=&quot;blogger-post-footer&quot;&gt;For more detailed version visit http://programmingwithme.blogspot.com&lt;/div&gt;</description><link>http://programmingwithme.blogspot.com/2011/03/use-recursive-calls-to-evaluate-fx-x.html</link><author>noreply@blogger.com (THE Author)</author><thr:total>0</thr:total></item></channel></rss>