Difference between revisions of "CSC231 Homwork 2 Solution 2010"

From dftwiki3
Jump to: navigation, search
(Mystery Program)
 
(2 intermediate revisions by the same user not shown)
Line 4: Line 4:
 
__TOC__
 
__TOC__
  
 +
<onlysmith>
 
=Number Systems=
 
=Number Systems=
 
<code><pre>
 
<code><pre>
Line 206: Line 207:
 
</pre></code>
 
</pre></code>
  
 +
==Testing the Mystery Program==
 
<br />
 
<br />
 
* To test the programs, the hexadecimal dump of the object file of the original program was compared to the hexadecimal dump of the object file of your version.  
 
* To test the programs, the hexadecimal dump of the object file of the original program was compared to the hexadecimal dump of the object file of your version.  
Line 217: Line 219:
 
   
 
   
 
  diff -y hw2_mystery.solution.lst  hw2c.lst
 
  diff -y hw2_mystery.solution.lst  hw2c.lst
 +
 +
* The output is shown below.  When only 1 vertical bar separates the two columns, then the program on the left matches the program on the right.  When double vertical bars appear, there is a difference between the two programs.  Visual inspection will indicate where the problem bytes are...
  
 
  000001f0  04 00 00 00 08 00 00 00  00 00 00 00 00 00 00 00  | 000001f0  04 00 00 00 08 00 00 00  00 00 00 00 00 00 00 00  |
 
  000001f0  04 00 00 00 08 00 00 00  00 00 00 00 00 00 00 00  | 000001f0  04 00 00 00 08 00 00 00  00 00 00 00 00 00 00 00  |
Line 239: Line 243:
 
<br />
 
<br />
 
<br />
 
<br />
 +
</onlysmith>
 
<br />
 
<br />
 
<br />
 
<br />

Latest revision as of 12:21, 14 December 2010

--D. Thiebaut 21:35, 6 October 2010 (UTC)




This section is only visible to computers located at Smith College