<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en-GB">
	<id>https://wiki.kram.nz/index.php?action=history&amp;feed=atom&amp;title=SE250%3Alab-7%3Arthu009</id>
	<title>SE250:lab-7:rthu009 - Revision history</title>
	<link rel="self" type="application/atom+xml" href="https://wiki.kram.nz/index.php?action=history&amp;feed=atom&amp;title=SE250%3Alab-7%3Arthu009"/>
	<link rel="alternate" type="text/html" href="https://wiki.kram.nz/index.php?title=SE250:lab-7:rthu009&amp;action=history"/>
	<updated>2026-04-29T16:19:56Z</updated>
	<subtitle>Revision history for this page on the wiki</subtitle>
	<generator>MediaWiki 1.45.3</generator>
	<entry>
		<id>https://wiki.kram.nz/index.php?title=SE250:lab-7:rthu009&amp;diff=7745&amp;oldid=prev</id>
		<title>Mark: 12 revision(s)</title>
		<link rel="alternate" type="text/html" href="https://wiki.kram.nz/index.php?title=SE250:lab-7:rthu009&amp;diff=7745&amp;oldid=prev"/>
		<updated>2008-11-03T05:20:18Z</updated>

		<summary type="html">&lt;p&gt;12 revision(s)&lt;/p&gt;
&lt;p&gt;&lt;b&gt;New page&lt;/b&gt;&lt;/p&gt;&lt;div&gt;== Lab 7 rthu009 ==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Ahhh the code didn&amp;#039;t compile on visual studio gave me tons of errors so i used cygdrive program to compile the code and ran it and the code work fine lol........&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Trying the program out for the first time ==&lt;br /&gt;
&lt;br /&gt;
After compiling the code the program came out with the symbol &amp;quot;&amp;gt;&amp;quot;. I have typed Help and it came up with the list of commands I can use to work the program.&lt;br /&gt;
&lt;br /&gt;
 *insert command : &amp;quot;insert str&amp;quot;,&amp;quot;i str&amp;quot; &lt;br /&gt;
 I have entered &amp;quot;i 4&amp;quot; to start with and the program displayed &amp;quot;4&amp;quot;&lt;br /&gt;
 At that point i assumed that the program selected the &amp;quot;4&amp;quot; to be the parent node and so I went on and added more elements.&lt;br /&gt;
&lt;br /&gt;
 Inserting 6 elements into the tree&lt;br /&gt;
 *i 4,i 6,i 2, i 01, i 5,i 2.5 [4,2,1,5,2.5,8]&lt;br /&gt;
 &lt;br /&gt;
 After inserting these elements my tree looked like this:&lt;br /&gt;
 &lt;br /&gt;
       01&lt;br /&gt;
    2&lt;br /&gt;
       2.5&lt;br /&gt;
 4&lt;br /&gt;
       5&lt;br /&gt;
    6&lt;br /&gt;
       8&lt;br /&gt;
 &lt;br /&gt;
 &lt;br /&gt;
 This proves that the tree is created properly using 4 as the main node and adding elements into its left and right branches respectively&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Navigating through the tree ==&lt;br /&gt;
&lt;br /&gt;
Using left right and root commands I was able to navigate the tree branches and also able to delete a specific node my selecting it through left right commands &lt;br /&gt;
&lt;br /&gt;
 e.g&lt;br /&gt;
 &lt;br /&gt;
        01&lt;br /&gt;
    2&lt;br /&gt;
       2.5&lt;br /&gt;
 4&lt;br /&gt;
       5&lt;br /&gt;
    6&lt;br /&gt;
       8(*)    &amp;lt;------ Currently selected branch node&lt;br /&gt;
&lt;br /&gt;
 &amp;gt;delete will delete eight from the branch&lt;br /&gt;
&lt;br /&gt;
*** A bug was found on the program is that using the command clear tree will make the program to crash and also if you need to insert the element &amp;quot;1&amp;quot; to the tree it must be entered as &amp;quot;01&amp;quot; not &amp;quot;1&amp;quot; because the program assume &amp;quot;1&amp;quot; to be as &amp;quot;10&amp;quot; i think.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Rotating the nodes ==&lt;br /&gt;
&lt;br /&gt;
The command rr or rotate right and rl or rotate left will rotate the selected node to either left or right.&lt;br /&gt;
&lt;br /&gt;
 e.g &lt;br /&gt;
 &lt;br /&gt;
 &lt;br /&gt;
       01&lt;br /&gt;
    2&lt;br /&gt;
       2.5&lt;br /&gt;
 4&lt;br /&gt;
         4.5&lt;br /&gt;
       5&lt;br /&gt;
    6(*)       &amp;lt;------ Currently selected node*&lt;br /&gt;
       8&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
 The command rotate right(rr) will rotate the tree: &lt;br /&gt;
 &lt;br /&gt;
 &lt;br /&gt;
        01&lt;br /&gt;
    2&lt;br /&gt;
       2.5&lt;br /&gt;
 4&lt;br /&gt;
       4.5&lt;br /&gt;
    5&lt;br /&gt;
       6(*)       &amp;lt;------ Currently selected node*&lt;br /&gt;
         8&lt;/div&gt;</summary>
		<author><name>Mark</name></author>
	</entry>
</feed>