<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	xmlns:georss="http://www.georss.org/georss" xmlns:geo="http://www.w3.org/2003/01/geo/wgs84_pos#" xmlns:media="http://search.yahoo.com/mrss/"
	>

<channel>
	<title>Jurnalnya Wawa</title>
	<atom:link href="http://wa24z.wordpress.com/feed/" rel="self" type="application/rss+xml" />
	<link>http://wa24z.wordpress.com</link>
	<description>Mudah Dikenal Sulit Untuk Dilupakan</description>
	<lastBuildDate>Thu, 26 Jan 2012 11:03:32 +0000</lastBuildDate>
	<language>id</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.com/</generator>
<cloud domain='wa24z.wordpress.com' port='80' path='/?rsscloud=notify' registerProcedure='' protocol='http-post' />
<image>
		<url>http://0.gravatar.com/blavatar/23bc69e6154e9a90f48510700b1ac22a?s=96&#038;d=http%3A%2F%2Fs2.wp.com%2Fi%2Fbuttonw-com.png</url>
		<title>Jurnalnya Wawa</title>
		<link>http://wa24z.wordpress.com</link>
	</image>
	<atom:link rel="search" type="application/opensearchdescription+xml" href="http://wa24z.wordpress.com/osd.xml" title="Jurnalnya Wawa" />
	<atom:link rel='hub' href='http://wa24z.wordpress.com/?pushpress=hub'/>
		<item>
		<title>Input Tree (C++)</title>
		<link>http://wa24z.wordpress.com/2012/01/26/input-tree-c/</link>
		<comments>http://wa24z.wordpress.com/2012/01/26/input-tree-c/#comments</comments>
		<pubDate>Thu, 26 Jan 2012 11:03:31 +0000</pubDate>
		<dc:creator>wa24z</dc:creator>
				<category><![CDATA[Kumpulan Modul-modul]]></category>

		<guid isPermaLink="false">http://wa24z.wordpress.com/?p=110</guid>
		<description><![CDATA[&#160; #include&#60;iostream.h&#62; #include&#60;conio.h&#62; #include&#60;stdio.h&#62; #include&#60;stdlib.h&#62; struct node { int data; node *left; node *right; }; node *tree=NULL; node *insert(node *tree,int ele); void preorder(node *tree); void inorder(node *tree); void postorder(node *tree); int count=1; void main() { clrscr(); int ch,ele; do { clrscr(); cout&#60;&#60;&#8221;\n\t\a\a1-&#62; INSERT A NODE IN A BINARY TREE.\a\a&#8221;; cout&#60;&#60;&#8221;\n\t\a\a2-&#62; PRE-ORDER TRAVERSAL.\a\a&#8221;; cout&#60;&#60;&#8221;\n\t\a\a3-&#62; IN-ORDER TRAVERSAL.\a\a&#8221;; [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=wa24z.wordpress.com&amp;blog=7824022&amp;post=110&amp;subd=wa24z&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p><a href="http://wa24z.files.wordpress.com/2012/01/insert.jpg"><img class="aligncenter  wp-image-111" title="insert" src="http://wa24z.files.wordpress.com/2012/01/insert.jpg?w=311&#038;h=187" alt="" width="311" height="187" /></a></p>
<p>&nbsp;</p>
<p>#include&lt;iostream.h&gt;<br />
#include&lt;conio.h&gt;<br />
#include&lt;stdio.h&gt;<br />
#include&lt;stdlib.h&gt;<br />
struct node<br />
{<br />
int data;<br />
node *left;<br />
node *right;<br />
};</p>
<p>node *tree=NULL;<br />
node *insert(node *tree,int ele);</p>
<p>void preorder(node *tree);<br />
void inorder(node *tree);<br />
void postorder(node *tree);<br />
int count=1;</p>
<p>void main()<br />
{<br />
clrscr();<br />
int ch,ele;<br />
do<br />
{<br />
clrscr();<br />
cout&lt;&lt;&#8221;\n\t\a\a1-&gt; INSERT A NODE IN A BINARY TREE.\a\a&#8221;;<br />
cout&lt;&lt;&#8221;\n\t\a\a2-&gt; PRE-ORDER TRAVERSAL.\a\a&#8221;;<br />
cout&lt;&lt;&#8221;\n\t\a\a3-&gt; IN-ORDER TRAVERSAL.\a\a&#8221;;<br />
cout&lt;&lt;&#8221;\n\t\a\a4-&gt; POST-ORDER TRAVERSAL.\a\a&#8221;;<br />
cout&lt;&lt;&#8221;\n\t\a\a5-&gt; EXIT.\a\a&#8221;;<br />
cout&lt;&lt;&#8221;\n\t\a\aENTER CHOICE :\a\a&#8221;;<br />
cin&gt;&gt;ch;<span id="more-110"></span><br />
switch(ch)<br />
{<br />
case 1:<br />
cout&lt;&lt;&#8221;\n\t\a\aENTER THE ELEMENT :\a\a&#8221;;<br />
cin&gt;&gt;ele;<br />
tree=insert(tree,ele);<br />
break;</p>
<p>case 2:<br />
cout&lt;&lt;&#8221;\n\t\a\a****PRE-ORDER TRAVERSAL OF A TREE : \a\a&#8221;;<br />
preorder(tree);<br />
break;</p>
<p>case 3:<br />
cout&lt;&lt;&#8221;\n\t\a\a****IN-ORDER TRAVERSAL OF A TREE : \a\a&#8221;;<br />
inorder(tree);<br />
break;</p>
<p>case 4:<br />
cout&lt;&lt;&#8221;\n\t\a\a****POST-ORDER TRAVERSAL OF A TREE : \a\a&#8221;;<br />
postorder(tree);<br />
break;</p>
<p>case 5:<br />
exit(0);<br />
}<br />
}while(ch!=5);<br />
}</p>
<p>node *insert(node *tree,int ele)<br />
{<br />
if(tree==NULL)<br />
{<br />
tree=new node;<br />
tree-&gt;left=tree-&gt;right=NULL;<br />
tree-&gt;data=ele;<br />
count++;<br />
}<br />
else<br />
if(count%2==0)<br />
tree-&gt;left=insert(tree-&gt;left,ele);<br />
else<br />
tree-&gt;right=insert(tree-&gt;right,ele);<br />
return(tree);<br />
}</p>
<p>void preorder(node *tree)<br />
{<br />
if(tree!=NULL)<br />
{<br />
cout&lt;&lt; tree -&gt; data;<br />
preorder(tree-&gt;left);<br />
preorder(tree-&gt;right);<br />
getch();<br />
}<br />
}</p>
<p>void inorder(node *tree)<br />
{<br />
if(tree!=NULL)<br />
{<br />
inorder(tree-&gt;left);<br />
cout&lt;&lt;tree -&gt; data;<br />
inorder(tree-&gt;right);<br />
getch();<br />
}<br />
}</p>
<p>void postorder(node *tree)<br />
{<br />
if(tree!=NULL)<br />
{<br />
postorder(tree-&gt;left);<br />
postorder(tree-&gt;right);<br />
cout&lt;&lt;tree -&gt; data;<br />
getch();<br />
}<br />
}</p>
<br />  <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/wa24z.wordpress.com/110/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/wa24z.wordpress.com/110/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/wa24z.wordpress.com/110/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/wa24z.wordpress.com/110/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/wa24z.wordpress.com/110/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/wa24z.wordpress.com/110/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/wa24z.wordpress.com/110/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/wa24z.wordpress.com/110/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/wa24z.wordpress.com/110/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/wa24z.wordpress.com/110/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/wa24z.wordpress.com/110/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/wa24z.wordpress.com/110/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/wa24z.wordpress.com/110/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/wa24z.wordpress.com/110/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=wa24z.wordpress.com&amp;blog=7824022&amp;post=110&amp;subd=wa24z&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://wa24z.wordpress.com/2012/01/26/input-tree-c/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
	
		<media:content url="http://0.gravatar.com/avatar/4e88b03fb372745a45d2e750ca4f3ff0?s=96&#38;d=identicon&#38;r=G" medium="image">
			<media:title type="html">wa24z</media:title>
		</media:content>

		<media:content url="http://wa24z.files.wordpress.com/2012/01/insert.jpg?w=300" medium="image">
			<media:title type="html">insert</media:title>
		</media:content>
	</item>
		<item>
		<title>Queue (Antrian) C++</title>
		<link>http://wa24z.wordpress.com/2011/12/14/queue-antrian-c/</link>
		<comments>http://wa24z.wordpress.com/2011/12/14/queue-antrian-c/#comments</comments>
		<pubDate>Wed, 14 Dec 2011 09:22:06 +0000</pubDate>
		<dc:creator>wa24z</dc:creator>
				<category><![CDATA[Kumpulan Tugas-tugas kuliah]]></category>

		<guid isPermaLink="false">http://wa24z.wordpress.com/?p=105</guid>
		<description><![CDATA[&#160; #include&#60;stdio.h&#62; #include&#60;conio.h&#62; #define MAX 8 typedef struct{ int data[MAX]; int head; int tail; } Queue; Queue antrian; void Create(){ antrian.head=antrian.tail=-1; } int IsEmpty(){ if (antrian.tail==-1) return 1; else return 0; } int IsFull(){ if(antrian.tail==MAX-1) return 1; else return 0; } void Enqueue(int data){ if(IsEmpty()==1){ antrian.head=antrian.tail=0; antrian.data[antrian.tail]=data; printf(&#8220;%d masuk!!&#8221;, antrian.data[antrian.tail]); }else if(IsFull()==0){ antrian.tail++; antrian.data[antrian.tail]=data; printf(&#8220;%d [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=wa24z.wordpress.com&amp;blog=7824022&amp;post=105&amp;subd=wa24z&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p><a href="http://wa24z.files.wordpress.com/2011/12/queue1.jpg"><img class="aligncenter  wp-image-107" title="queue" src="http://wa24z.files.wordpress.com/2011/12/queue1.jpg?w=331&#038;h=184" alt="" width="331" height="184" /></a></p>
<p>&nbsp;</p>
<p>#include&lt;stdio.h&gt;<br />
#include&lt;conio.h&gt;</p>
<p>#define MAX 8<br />
typedef struct{<br />
int data[MAX];<br />
int head;<br />
int tail;<br />
}<br />
Queue;</p>
<p>Queue antrian;<br />
void Create(){<br />
antrian.head=antrian.tail=-1;<br />
}<br />
int IsEmpty(){<br />
if (antrian.tail==-1)<br />
return 1;<br />
else<br />
return 0;<br />
}<br />
int IsFull(){<br />
if(antrian.tail==MAX-1) return 1;<br />
else return 0;<br />
}</p>
<p>void Enqueue(int data){<br />
if(IsEmpty()==1){<br />
antrian.head=antrian.tail=0;<br />
antrian.data[antrian.tail]=data;<br />
printf(&#8220;%d masuk!!&#8221;, antrian.data[antrian.tail]);<br />
}else<br />
if(IsFull()==0){<br />
antrian.tail++;<br />
antrian.data[antrian.tail]=data;<br />
printf(&#8220;%d masuk!&#8221;, antrian.data[antrian.tail]);<br />
}<span id="more-105"></span><br />
}<br />
int Dequeue(){<br />
int i;<br />
int e = antrian.data[antrian.head];<br />
for(i = antrian.head;i&lt;=antrian.tail-1;i++){<br />
antrian.data[i] = antrian.data[i+1];<br />
}<br />
antrian.tail&#8211;;<br />
return e;<br />
}<br />
void Clear(){<br />
antrian.head=antrian.tail=-1;<br />
printf(&#8220;data clear&#8221;);<br />
}<br />
void Tampil(){<br />
if(IsEmpty()==0){<br />
for(int i=antrian.head;i&lt;=antrian.tail;i++){<br />
printf(&#8220;%d &#8220;, antrian.data[i]);<br />
}<br />
}else printf(&#8220;Data kosong!\n&#8221;);<br />
}<br />
void main(){<br />
int pil;<br />
int data;<br />
Create();<br />
do{<br />
clrscr();<br />
printf(&#8220;1. Enqueue\n&#8221;);<br />
printf(&#8220;2. Dequeue\n&#8221;);<br />
printf(&#8220;3. Tampil\n&#8221;);<br />
printf(&#8220;4. Clear\n&#8221;);<br />
printf(&#8220;5. Exit\n&#8221;);<br />
printf(&#8220;Pilih : &#8220;);scanf(&#8220;%d&#8221;,&amp;pil);<br />
switch(pil){<br />
case 1: printf(&#8220;Data : &#8220;);scanf(&#8220;%d&#8221;,&amp;data);<br />
Enqueue(data);<br />
break;<br />
case 2: printf(&#8220;Elemen yang keluar : %d&#8221;, Dequeue());<br />
break;<br />
case 3:<br />
Tampil();<br />
break;<br />
case 4:<br />
Clear();<br />
break;<br />
}<br />
getch();<br />
} while(pil!=5);<br />
}</p>
<br />  <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/wa24z.wordpress.com/105/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/wa24z.wordpress.com/105/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/wa24z.wordpress.com/105/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/wa24z.wordpress.com/105/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/wa24z.wordpress.com/105/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/wa24z.wordpress.com/105/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/wa24z.wordpress.com/105/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/wa24z.wordpress.com/105/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/wa24z.wordpress.com/105/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/wa24z.wordpress.com/105/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/wa24z.wordpress.com/105/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/wa24z.wordpress.com/105/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/wa24z.wordpress.com/105/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/wa24z.wordpress.com/105/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=wa24z.wordpress.com&amp;blog=7824022&amp;post=105&amp;subd=wa24z&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://wa24z.wordpress.com/2011/12/14/queue-antrian-c/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
	
		<media:content url="http://0.gravatar.com/avatar/4e88b03fb372745a45d2e750ca4f3ff0?s=96&#38;d=identicon&#38;r=G" medium="image">
			<media:title type="html">wa24z</media:title>
		</media:content>

		<media:content url="http://wa24z.files.wordpress.com/2011/12/queue1.jpg?w=300" medium="image">
			<media:title type="html">queue</media:title>
		</media:content>
	</item>
	</channel>
</rss>
