<?xml version='1.0' encoding='UTF-8'?><?xml-stylesheet href="http://www.blogger.com/styles/atom.css" type="text/css"?><feed xmlns='http://www.w3.org/2005/Atom' xmlns:openSearch='http://a9.com/-/spec/opensearchrss/1.0/' xmlns:georss='http://www.georss.org/georss' xmlns:gd='http://schemas.google.com/g/2005' xmlns:thr='http://purl.org/syndication/thread/1.0'><id>tag:blogger.com,1999:blog-21595493</id><updated>2012-01-24T18:49:44.290-06:00</updated><category term='linux tips'/><category term='vedio'/><category term='tricks'/><category term='vi'/><category term='Chinese input related'/><category term='Programming related'/><category term='Mac'/><title type='text'>Linux for research</title><subtitle type='html'></subtitle><link rel='http://schemas.google.com/g/2005#feed' type='application/atom+xml' href='http://linux4research.blogspot.com/feeds/posts/default'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/21595493/posts/default?max-results=100'/><link rel='alternate' type='text/html' href='http://linux4research.blogspot.com/'/><link rel='hub' href='http://pubsubhubbub.appspot.com/'/><link rel='next' type='application/atom+xml' href='http://www.blogger.com/feeds/21595493/posts/default?start-index=101&amp;max-results=100'/><author><name>Dave</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><generator version='7.00' uri='http://www.blogger.com'>Blogger</generator><openSearch:totalResults>177</openSearch:totalResults><openSearch:startIndex>1</openSearch:startIndex><openSearch:itemsPerPage>100</openSearch:itemsPerPage><entry><id>tag:blogger.com,1999:blog-21595493.post-5791917640828163020</id><published>2011-09-19T14:06:00.001-05:00</published><updated>2011-09-19T14:06:54.239-05:00</updated><title type='text'>Comment in .vimrc</title><content type='html'>It is unusual. It is ".&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/21595493-5791917640828163020?l=linux4research.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://linux4research.blogspot.com/feeds/5791917640828163020/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=21595493&amp;postID=5791917640828163020' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/21595493/posts/default/5791917640828163020'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/21595493/posts/default/5791917640828163020'/><link rel='alternate' type='text/html' href='http://linux4research.blogspot.com/2011/09/comment-in-vimrc.html' title='Comment in .vimrc'/><author><name>Dave</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-21595493.post-6639287463405561555</id><published>2011-07-31T22:10:00.000-05:00</published><updated>2011-07-31T22:10:02.645-05:00</updated><title type='text'>matlab mex</title><content type='html'>1. be careful with the data type. It messes up instead of telling you that there is some implicit conversion.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/21595493-6639287463405561555?l=linux4research.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://linux4research.blogspot.com/feeds/6639287463405561555/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=21595493&amp;postID=6639287463405561555' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/21595493/posts/default/6639287463405561555'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/21595493/posts/default/6639287463405561555'/><link rel='alternate' type='text/html' href='http://linux4research.blogspot.com/2011/07/matlab-mex.html' title='matlab mex'/><author><name>Dave</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-21595493.post-8840726689593073521</id><published>2011-07-26T20:49:00.005-05:00</published><updated>2011-07-26T20:53:13.611-05:00</updated><title type='text'>use vi to open two files at the same time.</title><content type='html'>&lt;span class="Apple-style-span" style="color: black; font-size: 13px; font-weight: normal; line-height: normal;"&gt;from &lt;a href="http://www.philchen.com/2007/04/13/using-vi-to-edit-two-files-in-a-split-screen"&gt;here&lt;/a&gt;&lt;/span&gt;&lt;br /&gt;&lt;h2 style="background-attachment: initial; background-clip: initial; background-color: transparent; background-image: initial; background-origin: initial; border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; color: #ec7529; font-size: 22px; line-height: 20px; margin-bottom: 10px; margin-left: 0px; margin-right: 0px; margin-top: 0px; outline-color: initial; outline-style: initial; outline-width: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 10px; vertical-align: baseline;"&gt;&lt;span class="Apple-style-span" style="color: black; font-family: Arial, Helvetica, sans-serif; font-size: 13px; font-weight: normal; line-height: normal;"&gt;Sometimes you need to edit a new or existing file while looking at a separate file using VI. This can be very useful and a powerful time saver. Fortunately you can do this using some simple commands.&lt;/span&gt;&lt;/h2&gt;&lt;div class="entry" style="background-attachment: initial; background-clip: initial; background-color: transparent; background-image: initial; background-origin: initial; background-position: initial initial; background-repeat: initial initial; border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; font-size: 13px; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; outline-color: initial; outline-style: initial; outline-width: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; vertical-align: baseline;"&gt;&lt;div style="background-attachment: initial; background-clip: initial; background-color: transparent; background-image: initial; background-origin: initial; border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; font-size: 13px; margin-bottom: 10px; outline-color: initial; outline-style: initial; outline-width: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; vertical-align: baseline;"&gt;&lt;span id="more-32" style="background-attachment: initial; background-clip: initial; background-color: transparent; background-image: initial; background-origin: initial; border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; font-size: 13px; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; outline-color: initial; outline-style: initial; outline-width: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; vertical-align: baseline;"&gt;&lt;/span&gt;&lt;br /&gt;First go ahead and edit a file with VI&lt;/div&gt;&lt;div class="wp_syntax" style="background-attachment: initial; background-clip: initial; background-color: #f9f9f9; background-image: initial; background-origin: initial; background-position: initial initial; background-repeat: initial initial; border-bottom-color: silver; border-bottom-style: solid; border-bottom-width: 1px; border-color: initial; border-left-color: silver; border-left-style: solid; border-left-width: 1px; border-right-color: silver; border-right-style: solid; border-right-width: 1px; border-style: initial; border-top-color: silver; border-top-style: solid; border-top-width: 1px; color: #110000; font-size: 13px; margin-bottom: 1.5em; margin-left: 0px; margin-right: 0px; margin-top: 0px; outline-color: initial; outline-style: initial; outline-width: 0px; overflow-x: auto; overflow-y: hidden; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; vertical-align: baseline; width: 655px;"&gt;&lt;div class="code" style="background-attachment: initial; background-clip: initial; background-color: transparent; background-image: initial; background-origin: initial; background-position: initial initial; background-repeat: initial initial; border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; font-size: 13px; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; outline-color: initial; outline-style: initial; outline-width: 0px; padding-bottom: 2px; padding-left: 4px; padding-right: 4px; padding-top: 2px; vertical-align: top;"&gt;&lt;pre class="text" style="background-attachment: initial; background-clip: initial; background-color: transparent; background-image: initial; background-origin: initial; border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; clear: none; float: none; font-family: monospace; font-size: 12px; line-height: 1.333; outline-color: initial; outline-style: initial; outline-width: 0px; overflow-x: visible; overflow-y: visible; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; vertical-align: baseline; white-space: pre; width: auto;"&gt;shellprompt$ vi test-1.txt&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;&lt;div style="background-attachment: initial; background-clip: initial; background-color: transparent; background-image: initial; background-origin: initial; border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; font-size: 13px; margin-bottom: 10px; outline-color: initial; outline-style: initial; outline-width: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; vertical-align: baseline;"&gt;while in VI enter the following&lt;/div&gt;&lt;div class="wp_syntax" style="background-attachment: initial; background-clip: initial; background-color: #f9f9f9; background-image: initial; background-origin: initial; background-position: initial initial; background-repeat: initial initial; border-bottom-color: silver; border-bottom-style: solid; border-bottom-width: 1px; border-color: initial; border-left-color: silver; border-left-style: solid; border-left-width: 1px; border-right-color: silver; border-right-style: solid; border-right-width: 1px; border-style: initial; border-top-color: silver; border-top-style: solid; border-top-width: 1px; color: #110000; font-size: 13px; margin-bottom: 1.5em; margin-left: 0px; margin-right: 0px; margin-top: 0px; outline-color: initial; outline-style: initial; outline-width: 0px; overflow-x: auto; overflow-y: hidden; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; vertical-align: baseline; width: 655px;"&gt;&lt;div class="code" style="background-attachment: initial; background-clip: initial; background-color: transparent; background-image: initial; background-origin: initial; background-position: initial initial; background-repeat: initial initial; border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; font-size: 13px; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; outline-color: initial; outline-style: initial; outline-width: 0px; padding-bottom: 2px; padding-left: 4px; padding-right: 4px; padding-top: 2px; vertical-align: top;"&gt;&lt;pre class="text" style="background-attachment: initial; background-clip: initial; background-color: transparent; background-image: initial; background-origin: initial; border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; clear: none; float: none; font-family: monospace; font-size: 12px; line-height: 1.333; outline-color: initial; outline-style: initial; outline-width: 0px; overflow-x: visible; overflow-y: visible; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; vertical-align: baseline; white-space: pre; width: auto;"&gt;:new&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;&lt;div style="background-attachment: initial; background-clip: initial; background-color: transparent; background-image: initial; background-origin: initial; border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; font-size: 13px; margin-bottom: 10px; outline-color: initial; outline-style: initial; outline-width: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; vertical-align: baseline;"&gt;This will open a new split screen session, in order to navigate between the two windows in VI do the following&lt;/div&gt;&lt;div class="wp_syntax" style="background-attachment: initial; background-clip: initial; background-color: #f9f9f9; background-image: initial; background-origin: initial; background-position: initial initial; background-repeat: initial initial; border-bottom-color: silver; border-bottom-style: solid; border-bottom-width: 1px; border-color: initial; border-left-color: silver; border-left-style: solid; border-left-width: 1px; border-right-color: silver; border-right-style: solid; border-right-width: 1px; border-style: initial; border-top-color: silver; border-top-style: solid; border-top-width: 1px; color: #110000; font-size: 13px; margin-bottom: 1.5em; margin-left: 0px; margin-right: 0px; margin-top: 0px; outline-color: initial; outline-style: initial; outline-width: 0px; overflow-x: auto; overflow-y: hidden; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; vertical-align: baseline; width: 655px;"&gt;&lt;div class="code" style="background-attachment: initial; background-clip: initial; background-color: transparent; background-image: initial; background-origin: initial; background-position: initial initial; background-repeat: initial initial; border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; font-size: 13px; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; outline-color: initial; outline-style: initial; outline-width: 0px; padding-bottom: 2px; padding-left: 4px; padding-right: 4px; padding-top: 2px; vertical-align: top;"&gt;&lt;pre class="text" style="background-attachment: initial; background-clip: initial; background-color: transparent; background-image: initial; background-origin: initial; border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; clear: none; float: none; font-family: monospace; font-size: 12px; line-height: 1.333; outline-color: initial; outline-style: initial; outline-width: 0px; overflow-x: visible; overflow-y: visible; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; vertical-align: baseline; white-space: pre; width: auto;"&gt;&lt;ctrl-w&gt;ctr-w&lt;br /&gt;j&lt;/ctrl-w&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;&lt;div style="background-attachment: initial; background-clip: initial; background-color: transparent; background-image: initial; background-origin: initial; border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; font-size: 13px; margin-bottom: 10px; outline-color: initial; outline-style: initial; outline-width: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; vertical-align: baseline;"&gt;Or&lt;/div&gt;&lt;div class="wp_syntax" style="background-attachment: initial; background-clip: initial; background-color: #f9f9f9; background-image: initial; background-origin: initial; background-position: initial initial; background-repeat: initial initial; border-bottom-color: silver; border-bottom-style: solid; border-bottom-width: 1px; border-color: initial; border-left-color: silver; border-left-style: solid; border-left-width: 1px; border-right-color: silver; border-right-style: solid; border-right-width: 1px; border-style: initial; border-top-color: silver; border-top-style: solid; border-top-width: 1px; color: #110000; font-size: 13px; margin-bottom: 1.5em; margin-left: 0px; margin-right: 0px; margin-top: 0px; outline-color: initial; outline-style: initial; outline-width: 0px; overflow-x: auto; overflow-y: hidden; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; vertical-align: baseline; width: 655px;"&gt;&lt;div class="code" style="background-attachment: initial; background-clip: initial; background-color: transparent; background-image: initial; background-origin: initial; background-position: initial initial; background-repeat: initial initial; border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; font-size: 13px; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; outline-color: initial; outline-style: initial; outline-width: 0px; padding-bottom: 2px; padding-left: 4px; padding-right: 4px; padding-top: 2px; vertical-align: top;"&gt;&lt;pre class="text" style="background-attachment: initial; background-clip: initial; background-color: transparent; background-image: initial; background-origin: initial; border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; clear: none; float: none; font-family: monospace; font-size: 12px; line-height: 1.333; outline-color: initial; outline-style: initial; outline-width: 0px; overflow-x: visible; overflow-y: visible; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; vertical-align: baseline; white-space: pre; width: auto;"&gt;&lt;ctrl-w&gt;ctr-w&lt;br /&gt;k&lt;/ctrl-w&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;&lt;div style="background-attachment: initial; background-clip: initial; background-color: transparent; background-image: initial; background-origin: initial; border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; font-size: 13px; margin-bottom: 10px; outline-color: initial; outline-style: initial; outline-width: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; vertical-align: baseline;"&gt;Using the first will move you to the lower window and using the latter will move you to the upper window.&lt;/div&gt;&lt;div style="background-attachment: initial; background-clip: initial; background-color: transparent; background-image: initial; background-origin: initial; border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; font-size: 13px; margin-bottom: 10px; outline-color: initial; outline-style: initial; outline-width: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; vertical-align: baseline;"&gt;To make one of the windows full screen and out of the dual screen mode use the following&lt;/div&gt;&lt;div class="wp_syntax" style="background-attachment: initial; background-clip: initial; background-color: #f9f9f9; background-image: initial; background-origin: initial; background-position: initial initial; background-repeat: initial initial; border-bottom-color: silver; border-bottom-style: solid; border-bottom-width: 1px; border-color: initial; border-left-color: silver; border-left-style: solid; border-left-width: 1px; border-right-color: silver; border-right-style: solid; border-right-width: 1px; border-style: initial; border-top-color: silver; border-top-style: solid; border-top-width: 1px; color: #110000; font-size: 13px; margin-bottom: 1.5em; margin-left: 0px; margin-right: 0px; margin-top: 0px; outline-color: initial; outline-style: initial; outline-width: 0px; overflow-x: auto; overflow-y: hidden; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; vertical-align: baseline; width: 655px;"&gt;&lt;div class="code" style="background-attachment: initial; background-clip: initial; background-color: transparent; background-image: initial; background-origin: initial; background-position: initial initial; background-repeat: initial initial; border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; font-size: 13px; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; outline-color: initial; outline-style: initial; outline-width: 0px; padding-bottom: 2px; padding-left: 4px; padding-right: 4px; padding-top: 2px; vertical-align: top;"&gt;&lt;pre class="text" style="background-attachment: initial; background-clip: initial; background-color: transparent; background-image: initial; background-origin: initial; border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; clear: none; float: none; font-family: monospace; font-size: 12px; line-height: 1.333; outline-color: initial; outline-style: initial; outline-width: 0px; overflow-x: visible; overflow-y: visible; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; vertical-align: baseline; white-space: pre; width: auto;"&gt;:only&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;&lt;div style="background-attachment: initial; background-clip: initial; background-color: transparent; background-image: initial; background-origin: initial; border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; font-size: 13px; margin-bottom: 10px; outline-color: initial; outline-style: initial; outline-width: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; vertical-align: baseline;"&gt;*Important Side Notes&lt;/div&gt;&lt;div style="background-attachment: initial; background-clip: initial; background-color: transparent; background-image: initial; background-origin: initial; border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; font-size: 13px; margin-bottom: 10px; outline-color: initial; outline-style: initial; outline-width: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; vertical-align: baseline;"&gt;If you used :new and opened up a new window session it will not have a name so you cannot save it without entering the following&lt;/div&gt;&lt;div class="wp_syntax" style="background-attachment: initial; background-clip: initial; background-color: #f9f9f9; background-image: initial; background-origin: initial; background-position: initial initial; background-repeat: initial initial; border-bottom-color: silver; border-bottom-style: solid; border-bottom-width: 1px; border-color: initial; border-left-color: silver; border-left-style: solid; border-left-width: 1px; border-right-color: silver; border-right-style: solid; border-right-width: 1px; border-style: initial; border-top-color: silver; border-top-style: solid; border-top-width: 1px; color: #110000; font-size: 13px; margin-bottom: 1.5em; margin-left: 0px; margin-right: 0px; margin-top: 0px; outline-color: initial; outline-style: initial; outline-width: 0px; overflow-x: auto; overflow-y: hidden; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; vertical-align: baseline; width: 655px;"&gt;&lt;div class="code" style="background-attachment: initial; background-clip: initial; background-color: transparent; background-image: initial; background-origin: initial; background-position: initial initial; background-repeat: initial initial; border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; font-size: 13px; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; outline-color: initial; outline-style: initial; outline-width: 0px; padding-bottom: 2px; padding-left: 4px; padding-right: 4px; padding-top: 2px; vertical-align: top;"&gt;&lt;pre class="text" style="background-attachment: initial; background-clip: initial; background-color: transparent; background-image: initial; background-origin: initial; border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; clear: none; float: none; font-family: monospace; font-size: 12px; line-height: 1.333; outline-color: initial; outline-style: initial; outline-width: 0px; overflow-x: visible; overflow-y: visible; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; vertical-align: baseline; white-space: pre; width: auto;"&gt;:wq whatevername.txt&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;&lt;div style="background-attachment: initial; background-clip: initial; background-color: transparent; background-image: initial; background-origin: initial; border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; font-size: 13px; margin-bottom: 10px; outline-color: initial; outline-style: initial; outline-width: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; vertical-align: baseline;"&gt;Also if you want to open a file in split screen mode that is not new and exists you can enter the following&lt;/div&gt;&lt;div class="wp_syntax" style="background-attachment: initial; background-clip: initial; background-color: #f9f9f9; background-image: initial; background-origin: initial; background-position: initial initial; background-repeat: initial initial; border-bottom-color: silver; border-bottom-style: solid; border-bottom-width: 1px; border-color: initial; border-left-color: silver; border-left-style: solid; border-left-width: 1px; border-right-color: silver; border-right-style: solid; border-right-width: 1px; border-style: initial; border-top-color: silver; border-top-style: solid; border-top-width: 1px; color: #110000; font-size: 13px; margin-bottom: 1.5em; margin-left: 0px; margin-right: 0px; margin-top: 0px; outline-color: initial; outline-style: initial; outline-width: 0px; overflow-x: auto; overflow-y: hidden; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; vertical-align: baseline; width: 655px;"&gt;&lt;div class="code" style="background-attachment: initial; background-clip: initial; background-color: transparent; background-image: initial; background-origin: initial; background-position: initial initial; background-repeat: initial initial; border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; font-size: 13px; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; outline-color: initial; outline-style: initial; outline-width: 0px; padding-bottom: 2px; padding-left: 4px; padding-right: 4px; padding-top: 2px; vertical-align: top;"&gt;&lt;pre class="text" style="background-attachment: initial; background-clip: initial; background-color: transparent; background-image: initial; background-origin: initial; border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; clear: none; float: none; font-family: monospace; font-size: 12px; line-height: 1.333; outline-color: initial; outline-style: initial; outline-width: 0px; overflow-x: visible; overflow-y: visible; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; vertical-align: baseline; white-space: pre; width: auto;"&gt;:new /path/to/whateverfile&lt;/pre&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;/div&gt;&lt;/div&gt;&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/21595493-8840726689593073521?l=linux4research.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://linux4research.blogspot.com/feeds/8840726689593073521/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=21595493&amp;postID=8840726689593073521' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/21595493/posts/default/8840726689593073521'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/21595493/posts/default/8840726689593073521'/><link rel='alternate' type='text/html' href='http://linux4research.blogspot.com/2011/07/use-vi-to-open-two-files-at-same-time.html' title='use vi to open two files at the same time.'/><author><name>Dave</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-21595493.post-6293648205248645589</id><published>2011-07-16T23:45:00.002-05:00</published><updated>2011-07-16T23:45:21.268-05:00</updated><title type='text'>list only direcoties</title><content type='html'>&amp;gt;&amp;gt; ls -d */&lt;br /&gt;&lt;br /&gt;to list hidden direcotories:&lt;br /&gt;&lt;br /&gt;&amp;gt;&amp;gt; ls -d .*/&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/21595493-6293648205248645589?l=linux4research.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://linux4research.blogspot.com/feeds/6293648205248645589/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=21595493&amp;postID=6293648205248645589' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/21595493/posts/default/6293648205248645589'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/21595493/posts/default/6293648205248645589'/><link rel='alternate' type='text/html' href='http://linux4research.blogspot.com/2011/07/list-only-direcoties.html' title='list only direcoties'/><author><name>Dave</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-21595493.post-8425827870660480949</id><published>2011-07-05T21:09:00.000-05:00</published><updated>2011-07-05T21:09:28.801-05:00</updated><title type='text'>mac: move applications to different spaces.</title><content type='html'>&lt;span class="Apple-style-span" style="background-color: white; font-family: verdana, tahoma, helvetica, arial, sans-serif; font-size: 12px; line-height: 16px;"&gt;You do not have to view all Spaces to move windows between them (That is, by pressing F8, then using your mouse to drag and drop the desired window to the desire Space location). Nor do you have to drag to a screen edge, wait, then drop. If you like to use your keyboard, here's a fast way to do it.&lt;/span&gt;&lt;br /&gt;&lt;ol&gt;&lt;li&gt;Using your mouse, click and hold the window you want to move to another Space.&lt;/li&gt;&lt;li&gt;While still holding your mouse button down, use your Spaces keyboard shortcut to move to the desired Space. This is usually done by pressing Control and one of the arrow keys.&lt;/li&gt;&lt;/ol&gt;The window you are holding will be moving with you as you change your Spaces. Once you reach your destination, release the mouse button.&lt;br /&gt;&lt;br /&gt;[&lt;b&gt;robg adds:&lt;/b&gt;&amp;nbsp;You can also use this method to move the window directly to a numbered space -- just select the window, then press Control-1, -2, -3, etc. This is my preferred method of moving a window to a space, as it seems by far the quickest.]&lt;br /&gt;&lt;span class="Apple-style-span" style="background-color: white; font-family: verdana, tahoma, helvetica, arial, sans-serif; font-size: 12px; line-height: 16px;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;br /&gt;&lt;span class="Apple-style-span" style="background-color: white; font-family: verdana, tahoma, helvetica, arial, sans-serif; font-size: 12px; line-height: 16px;"&gt;source from &lt;a href="http://hints.macworld.com/article.php?story=20071027122153453"&gt;here&lt;/a&gt;&lt;/span&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/21595493-8425827870660480949?l=linux4research.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://linux4research.blogspot.com/feeds/8425827870660480949/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=21595493&amp;postID=8425827870660480949' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/21595493/posts/default/8425827870660480949'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/21595493/posts/default/8425827870660480949'/><link rel='alternate' type='text/html' href='http://linux4research.blogspot.com/2011/07/mac-move-applications-to-different.html' title='mac: move applications to different spaces.'/><author><name>Dave</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-21595493.post-6119028995366536156</id><published>2011-05-20T22:29:00.000-05:00</published><updated>2011-05-20T22:29:17.789-05:00</updated><title type='text'>rsync exclude files.</title><content type='html'>To exclude some directory, check the following:&lt;br /&gt;&lt;br /&gt;http://www.thegeekstuff.com/2011/01/rsync-exclude-files-and-folders/&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/21595493-6119028995366536156?l=linux4research.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://linux4research.blogspot.com/feeds/6119028995366536156/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=21595493&amp;postID=6119028995366536156' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/21595493/posts/default/6119028995366536156'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/21595493/posts/default/6119028995366536156'/><link rel='alternate' type='text/html' href='http://linux4research.blogspot.com/2011/05/rsync-exclude-files.html' title='rsync exclude files.'/><author><name>Dave</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-21595493.post-1975166697886095023</id><published>2011-05-06T16:08:00.002-05:00</published><updated>2011-05-06T16:08:17.836-05:00</updated><title type='text'>uninstall Qt</title><content type='html'>&lt;span class="Apple-style-span" style="font-family: verdana, geneva, lucida, 'lucida grande', arial, helvetica, sans-serif; font-size: 13px;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;table align="center" border="0" cellpadding="6" cellspacing="0" class="tborder" id="post6624920" style="background-attachment: initial; background-clip: initial; background-color: #bbbbbb; background-image: initial; background-origin: initial; background-position: initial initial; background-repeat: initial initial; border-bottom-color: rgb(102, 102, 102); border-bottom-style: solid; border-bottom-width: 1px; border-left-color: rgb(102, 102, 102); border-left-style: solid; border-left-width: 1px; border-right-color: rgb(102, 102, 102); border-right-style: solid; border-right-width: 1px; border-top-color: rgb(102, 102, 102); border-top-style: solid; border-top-width: 1px; color: black;"&gt;&lt;tbody&gt;&lt;tr valign="top"&gt;&lt;td class="alt1" id="td_post_6624920" style="background-attachment: initial; background-clip: initial; background-color: #fafafa; background-image: initial; background-origin: initial; background-position: initial initial; background-repeat: initial initial; border-right-color: rgb(187, 187, 187); border-right-style: solid; border-right-width: 1px; color: black; font: normal normal normal 10pt/normal verdana, geneva, lucida, 'lucida grande', arial, helvetica, sans-serif;"&gt;&lt;div id="post_message_6624920"&gt;sudo /Developer/Tools/uninstall-qt.py&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr&gt;&lt;/tr&gt;&lt;/tbody&gt;&lt;/table&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/21595493-1975166697886095023?l=linux4research.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://linux4research.blogspot.com/feeds/1975166697886095023/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=21595493&amp;postID=1975166697886095023' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/21595493/posts/default/1975166697886095023'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/21595493/posts/default/1975166697886095023'/><link rel='alternate' type='text/html' href='http://linux4research.blogspot.com/2011/05/uninstall-qt.html' title='uninstall Qt'/><author><name>Dave</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-21595493.post-4193962933923652399</id><published>2011-03-22T13:52:00.000-05:00</published><updated>2011-03-22T13:52:20.776-05:00</updated><title type='text'>ITK directory</title><content type='html'>To configure cmake&lt;br /&gt;ITK_DIR&lt;br /&gt;It should be "/Users/xxxx/software/InsightToolKitCompiled", where you put your compiled ITK.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/21595493-4193962933923652399?l=linux4research.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://linux4research.blogspot.com/feeds/4193962933923652399/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=21595493&amp;postID=4193962933923652399' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/21595493/posts/default/4193962933923652399'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/21595493/posts/default/4193962933923652399'/><link rel='alternate' type='text/html' href='http://linux4research.blogspot.com/2011/03/itk-directory.html' title='ITK directory'/><author><name>Dave</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-21595493.post-3667064351361546465</id><published>2011-03-21T09:14:00.000-05:00</published><updated>2011-03-21T09:14:17.135-05:00</updated><title type='text'>Problem with ITK: library not loaded.</title><content type='html'>&lt;b&gt;&lt;span class="Apple-style-span" style="color: red;"&gt;Problem:&amp;nbsp;&lt;/span&gt;&lt;/b&gt;&lt;br /&gt;&lt;b&gt;dyld: Library not loaded: libITKCommon.3.16.dylib&lt;/b&gt;&lt;br /&gt;&lt;b&gt;&lt;br /&gt;&lt;/b&gt;&lt;br /&gt;&lt;b&gt;&lt;span class="Apple-style-span" style="color: red;"&gt;Solution:&lt;/span&gt;&lt;/b&gt;&lt;br /&gt;&lt;b&gt;export DYLD_LIBRARY_PATH=$DYLD_LIBRARY_PATH:/usr/local/lib/InsightToolkit&lt;/b&gt;&lt;br /&gt;&lt;b&gt;&lt;br /&gt;&lt;/b&gt;&lt;br /&gt;/usr/local/lib/InsightToolkit is where the "libITKCommon.3.16.dylib" lives in.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/21595493-3667064351361546465?l=linux4research.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://linux4research.blogspot.com/feeds/3667064351361546465/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=21595493&amp;postID=3667064351361546465' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/21595493/posts/default/3667064351361546465'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/21595493/posts/default/3667064351361546465'/><link rel='alternate' type='text/html' href='http://linux4research.blogspot.com/2011/03/problem-with-itk-library-not-loaded.html' title='Problem with ITK: library not loaded.'/><author><name>Dave</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-21595493.post-2269682665062197073</id><published>2010-12-28T09:20:00.000-06:00</published><updated>2010-12-28T09:20:43.638-06:00</updated><title type='text'>use grep</title><content type='html'>Recently I am using Mercurial to manage my Matlab codes. I need combine commands "hg" with "grep" to see which files are updated. Here is how it is working:&lt;br /&gt;&lt;br /&gt;&amp;gt;&amp;gt; hg status | grep '\.m$'&lt;br /&gt;&lt;br /&gt;The above command will give all the .m files without any other junks, such as "*.m~" and other image files.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/21595493-2269682665062197073?l=linux4research.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://linux4research.blogspot.com/feeds/2269682665062197073/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=21595493&amp;postID=2269682665062197073' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/21595493/posts/default/2269682665062197073'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/21595493/posts/default/2269682665062197073'/><link rel='alternate' type='text/html' href='http://linux4research.blogspot.com/2010/12/use-grep.html' title='use grep'/><author><name>Dave</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-21595493.post-1299695846167599804</id><published>2010-12-23T22:55:00.001-06:00</published><updated>2010-12-24T06:13:51.148-06:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='Mac'/><title type='text'>Install python packages.</title><content type='html'>Python provides a easy solution to install packages and resolve package dependencies.&lt;br /&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;&amp;gt;&amp;gt; sudo easy_install simplejson&amp;nbsp;&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;This works very well!!!&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/21595493-1299695846167599804?l=linux4research.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://linux4research.blogspot.com/feeds/1299695846167599804/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=21595493&amp;postID=1299695846167599804' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/21595493/posts/default/1299695846167599804'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/21595493/posts/default/1299695846167599804'/><link rel='alternate' type='text/html' href='http://linux4research.blogspot.com/2010/12/install-python-packages.html' title='Install python packages.'/><author><name>Dave</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-21595493.post-8878660297077053366</id><published>2010-11-17T20:00:00.001-06:00</published><updated>2010-11-17T20:01:05.714-06:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='linux tips'/><title type='text'>Debian Lenny.</title><content type='html'>Have not used Linux (Debian) for a while. Today, my old computer for my son showed some problem with X windows. I could not start the X server. Tried to reconfigure the Xorg. The Wiki from Debian is very helpful. Followings are the steps I followed.&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;div class="line862" style="font-family: Arial, 'Lucida Grande', sans-serif; font-size: 16px;"&gt;Switch to a&amp;nbsp;&lt;strong&gt;console&lt;/strong&gt;&amp;nbsp;as root (&lt;strong&gt;not&lt;/strong&gt;&amp;nbsp;a terminal emulator in X), then run:&lt;span class="anchor" id="line-46"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-47"&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class="line867" style="font-family: Arial, 'Lucida Grande', sans-serif; font-size: 16px;"&gt;&lt;span class="anchor" id="line-48"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-49"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-50"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-51"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-52"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-53"&gt;&lt;/span&gt;&lt;/div&gt;&lt;span class="Apple-style-span" style="font-family: Arial, 'Lucida Grande', sans-serif; font-size: 16px;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;pre style="background-color: #f3f5f7; border-bottom-color: rgb(174, 189, 204); border-bottom-style: solid; border-bottom-width: 1pt; border-left-color: rgb(174, 189, 204); border-left-style: solid; border-left-width: 1pt; border-right-color: rgb(174, 189, 204); border-right-style: solid; border-right-width: 1pt; border-top-color: rgb(174, 189, 204); border-top-style: solid; border-top-width: 1pt; font-family: courier, monospace; padding-bottom: 5pt; padding-left: 5pt; padding-right: 5pt; padding-top: 5pt; white-space: pre-wrap; word-wrap: break-word;"&gt;&lt;span class="Apple-style-span" style="font-family: Arial, 'Lucida Grande', sans-serif; font-size: 16px;"&gt;/etc/init.d/kdm stop&lt;br /&gt;/etc/init.d/gdm stop&lt;br /&gt;/etc/init.d/xdm stop&lt;br /&gt;cd /etc/X11/&lt;br /&gt;Xorg -configure&lt;/span&gt;&lt;/pre&gt;&lt;span class="Apple-style-span" style="font-family: Arial, 'Lucida Grande', sans-serif; font-size: 16px;"&gt;&lt;span class="anchor" id="line-54"&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class="Apple-style-span" style="font-family: Arial, 'Lucida Grande', sans-serif; font-size: 16px;"&gt;&lt;span class="anchor" id="line-55"&gt;&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;&lt;div class="line874" style="font-family: Arial, 'Lucida Grande', sans-serif; font-size: 16px;"&gt;Alternatively, reboot the machine in single user mode, then run:&lt;span class="anchor" id="line-56"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-57"&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class="line867" style="font-family: Arial, 'Lucida Grande', sans-serif; font-size: 16px;"&gt;&lt;span class="anchor" id="line-58"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-59"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-60"&gt;&lt;/span&gt;&lt;/div&gt;&lt;span class="Apple-style-span" style="font-family: Arial, 'Lucida Grande', sans-serif; font-size: 16px;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;pre style="background-color: #f3f5f7; border-bottom-color: rgb(174, 189, 204); border-bottom-style: solid; border-bottom-width: 1pt; border-left-color: rgb(174, 189, 204); border-left-style: solid; border-left-width: 1pt; border-right-color: rgb(174, 189, 204); border-right-style: solid; border-right-width: 1pt; border-top-color: rgb(174, 189, 204); border-top-style: solid; border-top-width: 1pt; font-family: courier, monospace; padding-bottom: 5pt; padding-left: 5pt; padding-right: 5pt; padding-top: 5pt; white-space: pre-wrap; word-wrap: break-word;"&gt;&lt;span class="Apple-style-span" style="font-family: Arial, 'Lucida Grande', sans-serif; font-size: 16px;"&gt;cd /etc/X11/&lt;br /&gt;Xorg -configure&lt;/span&gt;&lt;/pre&gt;&lt;span class="Apple-style-span" style="font-family: Arial, 'Lucida Grande', sans-serif; font-size: 16px;"&gt;&lt;span class="anchor" id="line-61"&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class="Apple-style-span" style="font-family: Arial, 'Lucida Grande', sans-serif; font-size: 16px;"&gt;&lt;span class="anchor" id="line-62"&gt;&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;&lt;div class="line874" style="font-family: Arial, 'Lucida Grande', sans-serif; font-size: 16px;"&gt;Follow the on-screen instructions. This should give you something to work with.&lt;span class="anchor" id="line-63"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-64"&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class="line867" style="font-family: Arial, 'Lucida Grande', sans-serif; font-size: 16px;"&gt;&lt;/div&gt;&lt;h2 id="RunX" style="font-family: Arial, 'Lucida Grande', sans-serif; font-size: 16px;"&gt;Run X&lt;/h2&gt;&lt;span class="Apple-style-span" style="font-family: Arial, 'Lucida Grande', sans-serif; font-size: 16px;"&gt;&lt;span class="anchor" id="line-65"&gt;&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;&lt;div class="line874" style="font-family: Arial, 'Lucida Grande', sans-serif; font-size: 16px;"&gt;After installation run:&lt;span class="anchor" id="line-66"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-67"&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class="line867" style="font-family: Arial, 'Lucida Grande', sans-serif; font-size: 16px;"&gt;&lt;span class="anchor" id="line-68"&gt;&lt;/span&gt;&lt;span class="anchor" id="line-69"&gt;&lt;/span&gt;&lt;/div&gt;&lt;span class="Apple-style-span" style="font-family: Arial, 'Lucida Grande', sans-serif; font-size: 16px;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;pre style="background-color: #f3f5f7; border-bottom-color: rgb(174, 189, 204); border-bottom-style: solid; border-bottom-width: 1pt; border-left-color: rgb(174, 189, 204); border-left-style: solid; border-left-width: 1pt; border-right-color: rgb(174, 189, 204); border-right-style: solid; border-right-width: 1pt; border-top-color: rgb(174, 189, 204); border-top-style: solid; border-top-width: 1pt; font-family: courier, monospace; padding-bottom: 5pt; padding-left: 5pt; padding-right: 5pt; padding-top: 5pt; white-space: pre-wrap; word-wrap: break-word;"&gt;&lt;span class="Apple-style-span" style="font-family: Arial, 'Lucida Grande', sans-serif; font-size: 16px;"&gt;startx&lt;/span&gt;&lt;/pre&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/21595493-8878660297077053366?l=linux4research.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://linux4research.blogspot.com/feeds/8878660297077053366/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=21595493&amp;postID=8878660297077053366' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/21595493/posts/default/8878660297077053366'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/21595493/posts/default/8878660297077053366'/><link rel='alternate' type='text/html' href='http://linux4research.blogspot.com/2010/11/debian-lenny.html' title='Debian Lenny.'/><author><name>Dave</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-21595493.post-6969939188576790281</id><published>2010-10-11T09:37:00.001-05:00</published><updated>2010-10-11T09:38:21.478-05:00</updated><title type='text'>apple page customize dictionary</title><content type='html'>copied from: http://discussions.apple.com/thread.jspa?threadID=531999&lt;br /&gt;&lt;br /&gt;I've converted the all.dic from Medic.zip in the format you need with Pages. A quick test showed that it works.&lt;br /&gt;&lt;br /&gt;If you send me your e-mail address, I'll send you the new dictionary file. Click on my name above the atavar and use the e-mail address in the Biography field.&lt;br /&gt;&lt;br /&gt;You then only need to join your &lt;b&gt;&lt;span class="Apple-style-span" style="color: red;"&gt;~/Library/Spelling/en&lt;/span&gt;&lt;/b&gt; with the new medic.en:&lt;br /&gt;&lt;br /&gt;* Either open both en and medic.en in TextEdit and copy medic.en to the en window, then save the file&lt;br /&gt;Or, if you're familiar with Terminal.all, you could cd to ~/Library/Spelling and use this command:&lt;br /&gt;&lt;br /&gt;&lt;span class="Apple-style-span" style="color: red;"&gt;cat ~/Desktop/medic.en &amp;gt;&amp;gt; en&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;(I assume that you unzipped the file to your desktop)&lt;br /&gt;---&lt;br /&gt;&lt;br /&gt;If you want to change all.dic by yourself, then you have to replace the line endings with a special character from the en file. The character looks like "^@" but is in fact one character. In the resulting file, the words are all in one line separated by the special character. TextEdit doesn't show this character, so to change all.dic you should use something like emacs that comes with Mac OS X. You can launch emacs in Terminal.app.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/21595493-6969939188576790281?l=linux4research.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://linux4research.blogspot.com/feeds/6969939188576790281/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=21595493&amp;postID=6969939188576790281' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/21595493/posts/default/6969939188576790281'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/21595493/posts/default/6969939188576790281'/><link rel='alternate' type='text/html' href='http://linux4research.blogspot.com/2010/10/apple-page-customize-dictionary.html' title='apple page customize dictionary'/><author><name>Dave</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-21595493.post-6141931114003689370</id><published>2010-09-22T05:48:00.003-05:00</published><updated>2011-07-17T00:11:16.154-05:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='vi'/><title type='text'>vi editor: multiline comment</title><content type='html'>&lt;span class="Apple-style-span" style="font-family: Verdana, Arial, Helvetica, sans-serif; font-size: 13px;"&gt;1. :x,y s/^/# /&lt;br /&gt;&lt;br /&gt;The colon is command mode, obviously&lt;br /&gt;x and y is a range of line numbers you want to affect&lt;br /&gt;s is a sed substitution, the caret (^) means the beginning of the line&lt;br /&gt;The sharp (#) is the comment character, again obviously&lt;br /&gt;I put a space after the comment, but it isn't necessary, substitute any string that suits you.&lt;/span&gt;&lt;br /&gt;&lt;span class="Apple-style-span" style="font-family: Verdana, Arial, Helvetica, sans-serif; font-size: small;"&gt;&lt;span class="Apple-style-span" style="font-size: 13px;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;&lt;span class="Apple-style-span" style="font-family: Verdana, Arial, Helvetica, sans-serif; font-size: small;"&gt;&lt;span class="Apple-style-span" style="font-size: 13px;"&gt;2.&amp;nbsp;&lt;/span&gt;&lt;/span&gt;&lt;span class="Apple-style-span" style="font-family: Verdana, Arial, Helvetica, sans-serif; font-size: 13px;"&gt;Another way to do do this is to visually select the lines you want to comment with shift-v and up and down arrows, then type&lt;/span&gt;&lt;br /&gt;&lt;span class="Apple-style-span" style="font-family: Verdana, Arial, Helvetica, sans-serif; font-size: 13px;"&gt;&lt;br /&gt;:s/^/# /&lt;br /&gt;&lt;br /&gt;Easier for blocks of fewer lines.&lt;br /&gt;&lt;br /&gt;NB: When you press : vim will add '&amp;lt;,'&amp;gt; to the command line so the final command is:&lt;br /&gt;&lt;br /&gt;:'&amp;lt;,'&amp;gt;s/^/# /&lt;/span&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/21595493-6141931114003689370?l=linux4research.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://linux4research.blogspot.com/feeds/6141931114003689370/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=21595493&amp;postID=6141931114003689370' title='2 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/21595493/posts/default/6141931114003689370'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/21595493/posts/default/6141931114003689370'/><link rel='alternate' type='text/html' href='http://linux4research.blogspot.com/2010/09/vi-editor-multiline-comment.html' title='vi editor: multiline comment'/><author><name>Dave</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>2</thr:total></entry><entry><id>tag:blogger.com,1999:blog-21595493.post-1646966134451368554</id><published>2010-09-20T14:10:00.001-05:00</published><updated>2010-09-20T14:10:03.522-05:00</updated><title type='text'>Vim: comment multiple lines</title><content type='html'>&lt;span class="Apple-style-span" style="color: #333333; font-family: Georgia, 'Bitstream Charter', serif; font-size: 14px; line-height: 23px;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;h1 class="entry-title" style="border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; color: black; font-family: 'Helvetica Neue', Arial, Helvetica, 'Nimbus Sans L', sans-serif; font-size: 20px; font-style: inherit; font-weight: bold; letter-spacing: 0px; line-height: 24px; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; outline-color: initial; outline-style: initial; outline-width: 0px; padding-bottom: 8px; padding-left: 0px; padding-right: 0px; padding-top: 0px; text-rendering: optimizelegibility; vertical-align: baseline;"&gt;Vim Tip: Comment out multiple&amp;nbsp;lines&lt;/h1&gt;&lt;div class="entry-meta" style="border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; color: #888888; font-family: inherit; font-style: inherit; font-weight: inherit; font: normal normal normal 12px/normal 'Helvetica Neue', Arial, Helvetica, 'Nimbus Sans L', sans-serif; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; outline-color: initial; outline-style: initial; outline-width: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; vertical-align: baseline;"&gt;&lt;span class="meta-prep meta-prep-author" style="border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; font-family: inherit; font-style: inherit; font-weight: inherit; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; outline-color: initial; outline-style: initial; outline-width: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; vertical-align: baseline;"&gt;Posted on&lt;/span&gt;&amp;nbsp;&lt;a href="http://hurley.wordpress.com/2007/06/13/vim-tip-comment-out-multiple-lines/" rel="bookmark" style="border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; color: #888888; font-family: inherit; font-style: inherit; font-weight: inherit; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; outline-color: initial; outline-style: initial; outline-width: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; vertical-align: baseline;" title="6:39 pm"&gt;&lt;span class="entry-date" style="border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; font-family: inherit; font-style: inherit; font-weight: inherit; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; outline-color: initial; outline-style: initial; outline-width: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; vertical-align: baseline;"&gt;June 13, 2007&lt;/span&gt;&lt;/a&gt;&amp;nbsp;&lt;span class="byline" style="border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; display: block; font-family: inherit; font-style: inherit; font-weight: inherit; left: -9000px; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; outline-color: initial; outline-style: initial; outline-width: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; position: absolute; vertical-align: baseline;"&gt;&lt;span class="meta-sep" style="border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; font-family: inherit; font-style: inherit; font-weight: inherit; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; outline-color: initial; outline-style: initial; outline-width: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; vertical-align: baseline;"&gt;by&lt;/span&gt;&amp;nbsp;&lt;span class="author vcard" style="border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; font-family: inherit; font-style: inherit; font-weight: inherit; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; outline-color: initial; outline-style: initial; outline-width: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; vertical-align: baseline;"&gt;&lt;a class="url fn n" href="http://hurley.wordpress.com/author/hurley/" style="border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; color: #888888; font-family: inherit; font-style: inherit; font-weight: inherit; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; outline-color: initial; outline-style: initial; outline-width: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; vertical-align: baseline;" title="View all posts by Mark"&gt;Mark&lt;/a&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class="comments-link" style="border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; font-family: inherit; font-style: inherit; font-weight: inherit; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; outline-color: initial; outline-style: initial; outline-width: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; vertical-align: baseline;"&gt;&lt;span class="meta-sep" style="border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; font-family: inherit; font-style: inherit; font-weight: inherit; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; outline-color: initial; outline-style: initial; outline-width: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; vertical-align: baseline;"&gt;|&lt;/span&gt;&amp;nbsp;&lt;a href="http://hurley.wordpress.com/2007/06/13/vim-tip-comment-out-multiple-lines/#comments" style="border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; color: #888888; font-family: inherit; font-style: inherit; font-weight: inherit; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; outline-color: initial; outline-style: initial; outline-width: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; vertical-align: baseline;" title="Comment on Vim Tip: Comment out multiple lines"&gt;25 Comments&lt;/a&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class="entry-content" style="border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; font-family: inherit; font-style: inherit; font-weight: inherit; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0.85em; outline-color: initial; outline-style: initial; outline-width: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; vertical-align: baseline;"&gt;&lt;div class="snap_preview" style="border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; font-family: inherit; font-style: inherit; font-weight: inherit; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; outline-color: initial; outline-style: initial; outline-width: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; vertical-align: baseline;"&gt;&lt;div style="border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; font-family: inherit; font-style: inherit; font-weight: inherit; margin-bottom: 1.7em; margin-left: 0px; margin-right: 0px; margin-top: 0px; outline-color: initial; outline-style: initial; outline-width: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; vertical-align: baseline;"&gt;Commenting out a bunch of lines without a vim plugin:&lt;/div&gt;&lt;div style="border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; font-family: inherit; font-style: inherit; font-weight: inherit; margin-bottom: 1.7em; margin-left: 0px; margin-right: 0px; margin-top: 0px; outline-color: initial; outline-style: initial; outline-width: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; vertical-align: baseline;"&gt;Select your lines with VISUAL BLOCK (&lt;strong style="border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; font-family: inherit; font-style: inherit; font-weight: bold; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; outline-color: initial; outline-style: initial; outline-width: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; vertical-align: baseline;"&gt;CTRL-V&lt;/strong&gt;), then press&amp;nbsp;&lt;strong style="border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; font-family: inherit; font-style: inherit; font-weight: bold; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; outline-color: initial; outline-style: initial; outline-width: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; vertical-align: baseline;"&gt;I&lt;/strong&gt;&amp;nbsp;to insert before all highlighted lines. Next type your comment character,&amp;nbsp;&lt;strong style="border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; font-family: inherit; font-style: inherit; font-weight: bold; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; outline-color: initial; outline-style: initial; outline-width: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; vertical-align: baseline;"&gt;#&lt;/strong&gt;&amp;nbsp;(for python, shell, etc). Last press&amp;nbsp;&lt;strong style="border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; font-family: inherit; font-style: inherit; font-weight: bold; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; outline-color: initial; outline-style: initial; outline-width: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; vertical-align: baseline;"&gt;ESC&lt;/strong&gt;.&lt;/div&gt;&lt;div style="border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; font-family: inherit; font-style: inherit; font-weight: inherit; margin-bottom: 1.7em; margin-left: 0px; margin-right: 0px; margin-top: 0px; outline-color: initial; outline-style: initial; outline-width: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; vertical-align: baseline;"&gt;&lt;em style="border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; font-family: inherit; font-style: italic; font-weight: inherit; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; outline-color: initial; outline-style: initial; outline-width: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; vertical-align: baseline;"&gt;I forget not frequently used, but helpful VIM commands from time to time. Why not blog it?&lt;/em&gt;&lt;/div&gt;&lt;div style="border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; font-family: inherit; font-style: inherit; font-weight: inherit; margin-bottom: 1.7em; margin-left: 0px; margin-right: 0px; margin-top: 0px; outline-color: initial; outline-style: initial; outline-width: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; vertical-align: baseline;"&gt;You can alternatively select your lines with VISUAL LINE (&lt;strong style="border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; font-family: inherit; font-style: inherit; font-weight: bold; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; outline-color: initial; outline-style: initial; outline-width: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; vertical-align: baseline;"&gt;SHIFT-V&lt;/strong&gt;), then type&amp;nbsp;&lt;strong style="border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; font-family: inherit; font-style: inherit; font-weight: bold; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; outline-color: initial; outline-style: initial; outline-width: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; vertical-align: baseline;"&gt;: s/^/#&lt;/strong&gt;&lt;br /&gt;This tells the selected lines that you wish to&amp;nbsp;&lt;em style="border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; font-family: inherit; font-style: italic; font-weight: inherit; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; outline-color: initial; outline-style: initial; outline-width: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; vertical-align: baseline;"&gt;substitute the start of the line with the # char.&lt;/em&gt;&lt;/div&gt;&lt;/div&gt;&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/21595493-1646966134451368554?l=linux4research.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://linux4research.blogspot.com/feeds/1646966134451368554/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=21595493&amp;postID=1646966134451368554' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/21595493/posts/default/1646966134451368554'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/21595493/posts/default/1646966134451368554'/><link rel='alternate' type='text/html' href='http://linux4research.blogspot.com/2010/09/vim-comment-multiple-lines.html' title='Vim: comment multiple lines'/><author><name>Dave</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-21595493.post-8250222739873883323</id><published>2010-09-20T13:42:00.001-05:00</published><updated>2010-10-18T15:31:48.535-05:00</updated><title type='text'>vim cut past; copy and past</title><content type='html'>Ever try to cut (or copy) some lines and paste to another place? If you need to count the lines first, then try these to eliminate counting task.&lt;br /&gt;&lt;b&gt;&lt;br /&gt;&lt;/b&gt;&lt;br /&gt;&lt;b&gt;Cut and Paste:&lt;/b&gt;&lt;br /&gt;1. Place the cursor at the beginning of the block you want to CUT.&lt;br /&gt;2. Mark it with md&lt;br /&gt;3. Go to the end of the block.&lt;br /&gt;4. Cut it with d'd&lt;br /&gt;5. Go to the new location that you want to PASTE those text.&lt;br /&gt;Press P.&lt;br /&gt;&lt;br /&gt;&lt;b&gt;Copy and Paste:&lt;/b&gt;&lt;br /&gt;1. Place the cursor at the beginning of the block you want to COPY.&lt;br /&gt;2. Mark it with my&lt;br /&gt;3. Go to the end of the block.&lt;br /&gt;4. Copy it with y'y&lt;br /&gt;5. Go to the new location that you want to PASTE those text.&lt;br /&gt;Press P.&lt;br /&gt;&lt;br /&gt;The name of the mark used is related to the operation (d:delete or y:yank).&lt;br /&gt;I found that those mark names requires minimal movement of my finger.&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;Visual line mode (by shift+v):&lt;br /&gt;delete by: d&lt;br /&gt;Visual block mode (by ctrl + v):&lt;br /&gt;delete by: c&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/21595493-8250222739873883323?l=linux4research.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://linux4research.blogspot.com/feeds/8250222739873883323/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=21595493&amp;postID=8250222739873883323' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/21595493/posts/default/8250222739873883323'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/21595493/posts/default/8250222739873883323'/><link rel='alternate' type='text/html' href='http://linux4research.blogspot.com/2010/09/vim-cut-past-copy-and-past.html' title='vim cut past; copy and past'/><author><name>Dave</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-21595493.post-7094628753689366467</id><published>2010-08-12T19:44:00.002-05:00</published><updated>2010-08-12T19:44:18.573-05:00</updated><title type='text'>Cool vi</title><content type='html'>Start to vi as my editor on Mac. It is very cool. Here I just record some of the very useful notes for myself. &lt;br /&gt;&lt;br /&gt;1. show line numbers&lt;br /&gt;     :set number&lt;br /&gt;one can hide the numbers by :set nonumber&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/21595493-7094628753689366467?l=linux4research.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://linux4research.blogspot.com/feeds/7094628753689366467/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=21595493&amp;postID=7094628753689366467' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/21595493/posts/default/7094628753689366467'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/21595493/posts/default/7094628753689366467'/><link rel='alternate' type='text/html' href='http://linux4research.blogspot.com/2010/08/cool-vi.html' title='Cool vi'/><author><name>Dave</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-21595493.post-2537983572846766452</id><published>2010-05-12T13:58:00.000-05:00</published><updated>2010-05-25T22:06:02.420-05:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='Programming related'/><title type='text'>Sharing Data Among a GUI's Callbacks</title><content type='html'>http://www.mathworks.com/access/helpdesk/help/techdoc/creating_guis/f13-998449.html&lt;br /&gt;&lt;br /&gt;The first method, nested functions, seems to work only when you write the GUI programmatically. If you use GUIDE, this may not be easy to implement. In such case, use application data is better.&lt;br /&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/21595493-2537983572846766452?l=linux4research.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://linux4research.blogspot.com/feeds/2537983572846766452/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=21595493&amp;postID=2537983572846766452' title='1 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/21595493/posts/default/2537983572846766452'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/21595493/posts/default/2537983572846766452'/><link rel='alternate' type='text/html' href='http://linux4research.blogspot.com/2010/05/sharing-data-among-guis-callbacks.html' title='Sharing Data Among a GUI&apos;s Callbacks'/><author><name>Dave</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>1</thr:total></entry><entry><id>tag:blogger.com,1999:blog-21595493.post-6279364590125147395</id><published>2010-05-02T21:56:00.000-05:00</published><updated>2010-05-25T22:06:02.420-05:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='Programming related'/><title type='text'>compile Qt from source code.</title><content type='html'>Decided to compile from source because I want to have -arch x86_64 -cocoa and -qt-tiff&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;This target is using the GNU C++ compiler (macx-g++).&lt;br /&gt;&lt;br /&gt;&amp;nbsp;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;Recent versions of this compiler automatically include code for&lt;br /&gt;&amp;nbsp;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;exceptions, which increase both the size of the Qt libraries and&lt;br /&gt;&amp;nbsp;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;the amount of memory taken by your applications.&lt;br /&gt;&lt;br /&gt;&amp;nbsp;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;You may choose to re-run configure with the -no-exceptions&lt;br /&gt;&amp;nbsp;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;option to compile Qt without exceptions. This is completely binary&lt;br /&gt;&amp;nbsp;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;compatible, and existing applications will continue to work.&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;Build type: &amp;nbsp; &amp;nbsp;macx-g++&lt;br /&gt;Architecture: &amp;nbsp;macosx ( x86_64 )&lt;br /&gt;Using framework: Cocoa&lt;br /&gt;&lt;br /&gt;Build ............... libs tools examples demos docs translations&lt;br /&gt;Configuration ....... &amp;nbsp;build_all debug shared dll largefile stl precompile_header mmx 3dnow sse sse2 &amp;nbsp;x86_64 absolute_library_soname &amp;nbsp;minimal-config small-config medium-config large-config full-config dwarf2 qt3support phonon phonon-backend accessibility opengl reduce_exports ipv6 getaddrinfo ipv6ifname getifaddrs png gif no-freetype system-zlib nis cups openssl xmlpatterns multimedia audio-backend svg webkit script scripttools release debug qt_framework &amp;nbsp;x86_64&lt;br /&gt;Debug ............... yes (combined)&lt;br /&gt;Default Link ........ debug&lt;br /&gt;Qt 3 compatibility .. yes&lt;br /&gt;QtDBus module ....... no&lt;br /&gt;QtConcurrent code.... yes&lt;br /&gt;QtScript module ..... yes&lt;br /&gt;QtScriptTools module &amp;nbsp;yes&lt;br /&gt;QtXmlPatterns module &amp;nbsp;yes&lt;br /&gt;Phonon module ....... yes&lt;br /&gt;Multimedia module ... yes&lt;br /&gt;SVG module .......... yes&lt;br /&gt;WebKit module ....... yes&lt;br /&gt;JavaScriptCore JIT .. To be decided by JavaScriptCore&lt;br /&gt;Declarative module .. no&lt;br /&gt;STL support ......... yes&lt;br /&gt;PCH support ......... yes&lt;br /&gt;MMX/3DNOW/SSE/SSE2.. &amp;nbsp;yes/yes/yes/yes&lt;br /&gt;Graphics System ..... default&lt;br /&gt;IPv6 support ........ yes&lt;br /&gt;IPv6 ifname support . yes&lt;br /&gt;getaddrinfo support . yes&lt;br /&gt;getifaddrs support .. yes&lt;br /&gt;Accessibility ....... yes&lt;br /&gt;NIS support ......... yes&lt;br /&gt;CUPS support ........ yes&lt;br /&gt;Iconv support ....... no&lt;br /&gt;Glib support ........ auto&lt;br /&gt;GStreamer support ... auto&lt;br /&gt;Large File support .. yes&lt;br /&gt;GIF support ......... yes&lt;br /&gt;&lt;b&gt;TIFF support ........ plugin (qt)&lt;/b&gt;&lt;br /&gt;&lt;b&gt;JPEG support ........ plugin (qt)&lt;/b&gt;&lt;br /&gt;&lt;b&gt;PNG support ......... yes (qt)&lt;/b&gt;&lt;br /&gt;&lt;b&gt;MNG support ......... plugin (qt)&lt;/b&gt;&lt;br /&gt;zlib support ........ system&lt;br /&gt;Session management .. auto&lt;br /&gt;OpenGL support ...... yes (Desktop OpenGL)&lt;br /&gt;OpenVG support ...... no&lt;br /&gt;ODBC support ........ plugin&lt;br /&gt;SQLite support ...... plugin (qt)&lt;br /&gt;OpenSSL support ..... yes (run-time)&lt;br /&gt;alsa support ........ no&lt;br /&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/21595493-6279364590125147395?l=linux4research.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://linux4research.blogspot.com/feeds/6279364590125147395/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=21595493&amp;postID=6279364590125147395' title='1 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/21595493/posts/default/6279364590125147395'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/21595493/posts/default/6279364590125147395'/><link rel='alternate' type='text/html' href='http://linux4research.blogspot.com/2010/05/compile-qt-from-source-code.html' title='compile Qt from source code.'/><author><name>Dave</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>1</thr:total></entry><entry><id>tag:blogger.com,1999:blog-21595493.post-8346927014816465700</id><published>2010-05-02T21:07:00.000-05:00</published><updated>2010-05-25T22:05:05.043-05:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='Mac'/><title type='text'>lipo in Mac</title><content type='html'>lipo is very helpful. Look at the following examples.&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;$ lipo -info /usr/local/lib/libgd.a&lt;br /&gt;input file /usr/local/lib/libgd.a is not a fat file&lt;br /&gt;Non-fat file: /usr/local/lib/libgd.a is architecture: ppc7400&lt;br /&gt;&lt;br /&gt;$ lipo -info /usr/lib/libcrypto.dylib&lt;br /&gt;Architectures in the fat file: /usr/lib/libcrypto.dylib are: ppc7400 ppc64 i386 x86_64&lt;br /&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/21595493-8346927014816465700?l=linux4research.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://linux4research.blogspot.com/feeds/8346927014816465700/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=21595493&amp;postID=8346927014816465700' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/21595493/posts/default/8346927014816465700'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/21595493/posts/default/8346927014816465700'/><link rel='alternate' type='text/html' href='http://linux4research.blogspot.com/2010/05/lipo-in-mac.html' title='lipo in Mac'/><author><name>Dave</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-21595493.post-5946637446938977512</id><published>2010-05-02T20:43:00.000-05:00</published><updated>2010-05-25T22:05:05.043-05:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='Mac'/><title type='text'>How to uninstall Qt on Mac.</title><content type='html'>If you installed the binary file, do the following:&lt;br /&gt;&lt;br /&gt;&lt;span class="Apple-style-span" style="font-family: verdana, geneva, lucida, 'lucida grande', arial, helvetica, sans-serif; font-size: 13px;"&gt;sudo /Developer/Tools/uninstall-qt.py&lt;/span&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/21595493-5946637446938977512?l=linux4research.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://linux4research.blogspot.com/feeds/5946637446938977512/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=21595493&amp;postID=5946637446938977512' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/21595493/posts/default/5946637446938977512'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/21595493/posts/default/5946637446938977512'/><link rel='alternate' type='text/html' href='http://linux4research.blogspot.com/2010/05/how-to-uninstall-qt-on-mac.html' title='How to uninstall Qt on Mac.'/><author><name>Dave</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-21595493.post-2715906822768744497</id><published>2010-04-22T15:27:00.001-05:00</published><updated>2010-04-22T15:39:58.916-05:00</updated><title type='text'>Use dar to backup large directories to multiple DVDs.</title><content type='html'>I have a large directory of research data. Cannot use tar to do the work because the file size limit of tar is 4G. Finally get dar, which works very well. Use the following to backup&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;i&gt;&lt;b&gt;&amp;gt;&amp;gt; sudo dar -s 10M -c test -R / -g /Volumes/DATABACKUP/Research/ -v&lt;/b&gt;&lt;/i&gt;&lt;br /&gt;&lt;i&gt;&lt;b&gt;&lt;br /&gt;&lt;/b&gt;&lt;/i&gt;&lt;br /&gt;The above means: backup all the stuffs in directory /Volumes/DATABACKUP/Research/. Since there are so many files in this directory, dar will make sure that the files it generate is small enough for later use. Here with -s 10M, dar generates files of 10 M. &amp;nbsp;-v is used to display message. -R is used to set the ROOT directory, which is / here. -g restricts the directory to /Volumes/DATABACKUP/Research/.&lt;br /&gt;&lt;br /&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/21595493-2715906822768744497?l=linux4research.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://linux4research.blogspot.com/feeds/2715906822768744497/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=21595493&amp;postID=2715906822768744497' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/21595493/posts/default/2715906822768744497'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/21595493/posts/default/2715906822768744497'/><link rel='alternate' type='text/html' href='http://linux4research.blogspot.com/2010/04/use-dar-to-backup-large-directories-to.html' title='Use dar to backup large directories to multiple DVDs.'/><author><name>Dave</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-21595493.post-4135117723076566574</id><published>2010-04-15T22:13:00.000-05:00</published><updated>2010-05-25T22:06:02.421-05:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='Programming related'/><title type='text'>Doxygen graph interpretation.</title><content type='html'>&lt;span class="Apple-style-span" style="font-family: 'Lucida Grande', Verdana, Geneva, Arial, sans-serif; font-size: 12px;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;div class="dynheader" style="font-family: 'Lucida Grande', Verdana, Geneva, Arial, sans-serif; font-size: 12px;"&gt;call graph:&amp;nbsp;&lt;/div&gt;&lt;div class="dynheader" style="font-family: 'Lucida Grande', Verdana, Geneva, Arial, sans-serif; font-size: 12px;"&gt;&lt;br /&gt;&lt;/div&gt;&lt;div class="dynheader" style="font-family: 'Lucida Grande', Verdana, Geneva, Arial, sans-serif; font-size: 12px;"&gt;A ------&amp;gt; B: A is called by B.&amp;nbsp;&lt;/div&gt;&lt;div class="dynheader" style="font-family: 'Lucida Grande', Verdana, Geneva, Arial, sans-serif; font-size: 12px;"&gt;&lt;br /&gt;&lt;/div&gt;&lt;div class="dynheader" style="font-family: 'Lucida Grande', Verdana, Geneva, Arial, sans-serif; font-size: 12px;"&gt;Classes:&amp;nbsp;&lt;/div&gt;&lt;div class="dynheader" style="font-family: 'Lucida Grande', Verdana, Geneva, Arial, sans-serif; font-size: 12px;"&gt;&lt;br /&gt;&lt;/div&gt;&lt;div class="dynheader" style="font-family: 'Lucida Grande', Verdana, Geneva, Arial, sans-serif; font-size: 12px;"&gt;A ----&amp;gt; B: Actually B is the parent class! One way to understand/remember this that A is called as B (for example: A is a dog class; B is an animal class. Dog is called as animal.&amp;nbsp;&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/21595493-4135117723076566574?l=linux4research.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://linux4research.blogspot.com/feeds/4135117723076566574/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=21595493&amp;postID=4135117723076566574' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/21595493/posts/default/4135117723076566574'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/21595493/posts/default/4135117723076566574'/><link rel='alternate' type='text/html' href='http://linux4research.blogspot.com/2010/04/doxygen-graph-interpretation.html' title='Doxygen graph interpretation.'/><author><name>Dave</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-21595493.post-2542817599023748983</id><published>2010-04-07T00:01:00.000-05:00</published><updated>2010-05-25T22:06:15.402-05:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='Programming related'/><title type='text'>Qt and gsl library problem.</title><content type='html'>&lt;b&gt;&lt;span class="Apple-style-span" style="color: red;"&gt;ld: warning: in /usr/local/lib/libgsl.dylib, file is not of required architecture&lt;/span&gt;&lt;/b&gt;&lt;br /&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;Solution:&amp;nbsp;&lt;/div&gt;&lt;div&gt;open the Makefile and:&amp;nbsp;&lt;/div&gt;&lt;div&gt;1. CFLAGS: get rid of "arch i386'.&amp;nbsp;&lt;/div&gt;&lt;div&gt;2. CXXFLAGS: get rid of "arch i386"&lt;/div&gt;&lt;div&gt;3. comment LFLAGS.&amp;nbsp;&lt;/div&gt;&lt;div&gt;4. QMAKE_COMP_QMAKE_OBJECTIVE_CFLAGS: get rid of "arch i386".&amp;nbsp;&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;then save the Makefile and do:&amp;nbsp;&lt;/div&gt;&lt;div&gt;&amp;gt; make clean&lt;/div&gt;&lt;div&gt;&amp;gt; make&lt;/div&gt;&lt;div&gt;you will get warning but it should pass!&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/21595493-2542817599023748983?l=linux4research.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://linux4research.blogspot.com/feeds/2542817599023748983/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=21595493&amp;postID=2542817599023748983' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/21595493/posts/default/2542817599023748983'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/21595493/posts/default/2542817599023748983'/><link rel='alternate' type='text/html' href='http://linux4research.blogspot.com/2010/04/qt-and-gsl-library-problem.html' title='Qt and gsl library problem.'/><author><name>Dave</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-21595493.post-1072845012069449568</id><published>2010-04-06T20:57:00.000-05:00</published><updated>2010-05-25T22:05:05.044-05:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='Mac'/><title type='text'>dyld: Library not loaded</title><content type='html'>&lt;span class="Apple-style-span" style="font-family: verdana, arial, sans-serif; font-size: 11px;"&gt;After I installed qwt, everything seems to work. However, whenever I execute the program (examples), I got into trouble. When I used Qt creator to open one particular example and build it, I encountered the following error:&amp;nbsp;&lt;/span&gt;&lt;br /&gt;&lt;span class="Apple-style-span" style="font-family: verdana, arial, sans-serif; font-size: 11px;"&gt;&lt;b&gt;&lt;span class="Apple-style-span" style="color: red;"&gt;dyld: Library not loaded: libqwt.5.dylib&lt;/span&gt;&lt;/b&gt;&lt;/span&gt;&lt;br /&gt;&lt;span class="Apple-style-span" style="font-family: verdana, arial, sans-serif; font-size: small;"&gt;&lt;span class="Apple-style-span" style="font-size: 11px;"&gt;I searched the internet and did not find any easy solution. Proudly I used the following command to fix the problem. It may not be elegant but it works for me.&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;&lt;span class="Apple-style-span" style="font-family: verdana, arial, sans-serif; font-size: small;"&gt;&lt;span class="Apple-style-span" style="font-size: 11px;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;&lt;span class="Apple-style-span" style="font-family: verdana, arial, sans-serif; font-size: small;"&gt;&lt;span class="Apple-style-span" style="font-size: 11px;"&gt;&lt;i&gt;&lt;span class="Apple-style-span" style="color: blue;"&gt;&lt;b&gt;sudo ln -s /usr/local/qwt-5.2.0/lib/libqwt.5.dylib /usr/lib/libqwt.5.dylib&lt;/b&gt;&lt;/span&gt;&lt;/i&gt;&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;&lt;span class="Apple-style-span" style="font-family: verdana, arial, sans-serif; font-size: small;"&gt;&lt;span class="Apple-style-span" style="font-size: 11px;"&gt;&lt;i&gt;&lt;span class="Apple-style-span" style="color: blue;"&gt;&lt;b&gt;&lt;br /&gt;&lt;/b&gt;&lt;/span&gt;&lt;/i&gt;&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;&lt;span class="Apple-style-span" style="font-family: verdana, arial, sans-serif; font-size: small;"&gt;&lt;span class="Apple-style-span" style="font-size: 11px;"&gt;&lt;i&gt;&lt;span class="Apple-style-span" style="color: blue;"&gt;&lt;b&gt;&lt;br /&gt;&lt;/b&gt;&lt;/span&gt;&lt;/i&gt;&lt;/span&gt;&lt;/span&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/21595493-1072845012069449568?l=linux4research.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://linux4research.blogspot.com/feeds/1072845012069449568/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=21595493&amp;postID=1072845012069449568' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/21595493/posts/default/1072845012069449568'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/21595493/posts/default/1072845012069449568'/><link rel='alternate' type='text/html' href='http://linux4research.blogspot.com/2010/04/dyld-library-not-loaded.html' title='dyld: Library not loaded'/><author><name>Dave</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-21595493.post-2125153182643003931</id><published>2010-03-29T20:11:00.000-05:00</published><updated>2010-03-29T20:11:49.917-05:00</updated><title type='text'>logout kde desktop from command line.</title><content type='html'>&lt;table align="center" border="0" cellpadding="6" cellspacing="0" class="tborder" id="post5263983"&gt;&lt;tbody&gt;&lt;tr valign="top"&gt;&lt;td id="td_post_5263983" style="border-right: 1px solid rgb(255, 255, 255);"&gt;&lt;div class="vbclean_msgtext" id="post_message_5263983"&gt;1. 'killall kdeinit' to logout KDE.&lt;/div&gt;&lt;div class="vbclean_msgtext" id="post_message_5263983"&gt;2. 'dcop kdesktop default logout'. This one will popout the logout dialog and ask the user what to do (logout, cancel or reboot).&amp;nbsp; &lt;br /&gt;&lt;br /&gt;3. 'dcop ksmserver ksmserver logout 0 0 0 '.&amp;nbsp;&lt;/div&gt;&lt;div class="vbclean_msgtext" id="post_message_5263983"&gt;If you want to reboot the machine after logout you have 'dcop ksmserver ksmserver logout 0 1 1'&lt;/div&gt;&lt;/td&gt; &lt;/tr&gt;&lt;tr&gt;  &lt;td class="alt3"&gt;&lt;/td&gt;    &lt;td align="right" class="alt1" style="border-color: -moz-use-text-color rgb(255, 255, 255) rgb(255, 255, 255) -moz-use-text-color; border-style: none solid solid none; border-width: 0px 1px 1px 0px;"&gt;&lt;br /&gt;&lt;/td&gt;&lt;/tr&gt;&lt;/tbody&gt;&lt;/table&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/21595493-2125153182643003931?l=linux4research.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://linux4research.blogspot.com/feeds/2125153182643003931/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=21595493&amp;postID=2125153182643003931' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/21595493/posts/default/2125153182643003931'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/21595493/posts/default/2125153182643003931'/><link rel='alternate' type='text/html' href='http://linux4research.blogspot.com/2010/03/logout-kde-desktop-from-command-line.html' title='logout kde desktop from command line.'/><author><name>Dave</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-21595493.post-5398236811486750433</id><published>2010-03-29T19:35:00.000-05:00</published><updated>2010-03-29T19:35:40.452-05:00</updated><title type='text'>kde slow keyboard response</title><content type='html'>Check the following solution.&lt;br /&gt;&lt;br /&gt;Fortunately you can turn it off with just the mouse by going to the K menu; Control Centre -&amp;gt; Regional and Accessibility -&amp;gt; Accessibility -&amp;gt; Activation Gestures, and untick the first box ('Use gestures for activating slow keys and sticky keys'). Also go to the Keyboard Filters tab and untick the 'Use slow keys' box if it is ticked. Press apply and you should be OK.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/21595493-5398236811486750433?l=linux4research.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://linux4research.blogspot.com/feeds/5398236811486750433/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=21595493&amp;postID=5398236811486750433' title='1 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/21595493/posts/default/5398236811486750433'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/21595493/posts/default/5398236811486750433'/><link rel='alternate' type='text/html' href='http://linux4research.blogspot.com/2010/03/kde-slow-keyboard-response.html' title='kde slow keyboard response'/><author><name>Dave</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>1</thr:total></entry><entry><id>tag:blogger.com,1999:blog-21595493.post-1548283819969072969</id><published>2010-03-29T19:21:00.002-05:00</published><updated>2010-03-29T19:21:23.460-05:00</updated><title type='text'>switch to root user from kde GUI "run command".</title><content type='html'>Use:&lt;br /&gt;&lt;br /&gt;&lt;b&gt;kdesu command&lt;/b&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/21595493-1548283819969072969?l=linux4research.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://linux4research.blogspot.com/feeds/1548283819969072969/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=21595493&amp;postID=1548283819969072969' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/21595493/posts/default/1548283819969072969'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/21595493/posts/default/1548283819969072969'/><link rel='alternate' type='text/html' href='http://linux4research.blogspot.com/2010/03/switch-to-root-user-from-kde-gui-run.html' title='switch to root user from kde GUI &quot;run command&quot;.'/><author><name>Dave</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-21595493.post-5275805400668048913</id><published>2010-03-29T19:20:00.002-05:00</published><updated>2010-03-29T19:20:14.428-05:00</updated><title type='text'>lock kde screen from command line.</title><content type='html'>Lock your KDE screen from the command line&lt;br /&gt;&lt;br /&gt;January 29th, 2009 by T4L&lt;br /&gt;&lt;br /&gt;Did you know you can lock your current KDE screen by using the command line? For the 3.x series use&lt;br /&gt;&lt;br /&gt;dcop kdesktop KScreensaverIface lock&lt;br /&gt;&lt;br /&gt;and for KDE 4.x try&lt;br /&gt;&lt;br /&gt;qdbus org.freedesktop.ScreenSaver /ScreenSaver Lock&lt;br /&gt;&lt;br /&gt;With the help of these you should be able to craft a simple shell script that will lock your screen at given actions. For example, you can leave your screen unlocked and make the PC activate the commands above when it detects mouse movement or when a certain application is launched.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/21595493-5275805400668048913?l=linux4research.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://linux4research.blogspot.com/feeds/5275805400668048913/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=21595493&amp;postID=5275805400668048913' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/21595493/posts/default/5275805400668048913'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/21595493/posts/default/5275805400668048913'/><link rel='alternate' type='text/html' href='http://linux4research.blogspot.com/2010/03/lock-kde-screen-from-command-line.html' title='lock kde screen from command line.'/><author><name>Dave</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-21595493.post-2685468553766775308</id><published>2010-03-22T21:19:00.003-05:00</published><updated>2010-05-25T22:06:02.421-05:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='Programming related'/><title type='text'>Top 10 things that annoy programmer</title><content type='html'>Copied from&amp;nbsp;&lt;b&gt;http://www.kevinwilliampang.com/2008/08/28/top-10-things-that-annoy-programmers/&lt;/b&gt;&lt;br /&gt;&lt;div&gt;&lt;b&gt;Very nice post!&lt;/b&gt;&lt;/div&gt;&lt;div&gt;&lt;b&gt;&lt;br /&gt;&lt;/b&gt;&lt;span class="Apple-style-span" style="color: #333333; font-family: calibri, tahoma, arial, sans-serif; font-size: 16px; line-height: 21px;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;h2 class="entry-title" style="-webkit-border-top-left-radius: 10px 10px; background-color: #464646; border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; clear: both; color: white; font-family: Georgia, 'Times New Roman', 'Bitstream Charter', Times, serif; font-size: 24px; font-style: italic; font-weight: normal; line-height: 28px; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 5px; padding-left: 8px; padding-right: 0px; padding-top: 5px; vertical-align: baseline;"&gt;&lt;/h2&gt;&lt;br /&gt;&lt;div&gt;&lt;span class="Apple-style-span" style="color: #333333; font-family: calibri, tahoma, arial, sans-serif; font-size: 16px; line-height: 21px;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;h2 class="entry-title" style="-webkit-border-top-left-radius: 10px 10px; background-color: #464646; border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; clear: both; color: white; font-family: Georgia, 'Times New Roman', 'Bitstream Charter', Times, serif; font-size: 24px; font-style: italic; font-weight: normal; line-height: 28px; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 5px; padding-left: 8px; padding-right: 0px; padding-top: 5px; vertical-align: baseline;"&gt;Top 10 Things That Annoy Programmers&lt;/h2&gt;&lt;div class="entry-meta entry-header" style="background-color: #f1f1f1; border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; color: #999999; font-family: inherit; font-size: 16px; font-style: italic; font-weight: inherit; margin-bottom: 20px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 5px; padding-left: 8px; padding-right: 5px; padding-top: 5px; vertical-align: baseline;"&gt;&lt;span class="author vcard" style="border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; font-family: inherit; font-size: 16px; font-style: inherit; font-weight: inherit; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; vertical-align: baseline;"&gt;Written by&amp;nbsp;&lt;a class="url fn" href="http://www.kevinwilliampang.com/author/kevinpang/" style="border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; color: #0077cc; font-family: inherit; font-size: 16px; font-style: inherit; font-weight: inherit; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; text-decoration: none; vertical-align: baseline;" title="View all posts by Kevin Pang"&gt;Kevin Pang&lt;/a&gt;&lt;/span&gt;&amp;nbsp;&lt;span class="published" style="border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; font-family: inherit; font-size: 16px; font-style: inherit; font-weight: inherit; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; vertical-align: baseline;"&gt;on&amp;nbsp;&lt;abbr class="published-time" style="border-bottom-color: initial; border-bottom-style: none; border-bottom-width: initial; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; cursor: none; font-family: inherit; font-size: 16px; font-style: inherit; font-weight: inherit; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; vertical-align: baseline;" title="August 28, 2008 - 10:21 am"&gt;August 28, 2008&lt;/abbr&gt;&lt;/span&gt;&amp;nbsp;&lt;span class="meta-sep" style="border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; font-family: inherit; font-size: 16px; font-style: inherit; font-weight: inherit; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; vertical-align: baseline;"&gt;—&lt;/span&gt;&amp;nbsp;&lt;span class="comment-count" style="background-image: url(http://www.kevinwilliampang.com/wp-content/uploads/icon_comment.gif); background-position: 0% 50%; background-repeat: no-repeat; border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; font-family: inherit; font-size: 16px; font-style: inherit; font-weight: inherit; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 20px; padding-right: 0px; padding-top: 0px; vertical-align: baseline;"&gt;&lt;a href="http://www.kevinwilliampang.com/2008/08/28/top-10-things-that-annoy-programmers/#comments" style="border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; color: #0077cc; font-family: inherit; font-size: 16px; font-style: inherit; font-weight: inherit; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; text-decoration: none; vertical-align: baseline;"&gt;125 Comments&lt;/a&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class="entry-content article" style="border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; font-family: inherit; font-size: 16px; font-style: inherit; font-weight: inherit; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; vertical-align: baseline;"&gt;&lt;div style="border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; font-family: inherit; font-size: 16px; font-style: inherit; font-weight: inherit; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; vertical-align: baseline;"&gt;Programmers all have their pet peeves. Whether it’s&amp;nbsp;&lt;a href="http://en.wikipedia.org/wiki/Scope_creep" style="border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; color: #0077cc; font-family: inherit; font-size: 16px; font-style: inherit; font-weight: inherit; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; text-decoration: none; vertical-align: baseline;"&gt;scope creep&lt;/a&gt;,&amp;nbsp;&lt;a href="http://en.wikipedia.org/wiki/Hungarian_notation" style="border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; color: #0077cc; font-family: inherit; font-size: 16px; font-style: inherit; font-weight: inherit; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; text-decoration: none; vertical-align: baseline;"&gt;Hungarian notation&lt;/a&gt;, or smelly coworkers, we’ve come to accept that there are certain nuisances that come with our line of work. The following is a list of the top 10 things that annoy programmers, compiled from the results of&lt;a href="http://beta.stackoverflow.com/questions/27347/what-annoys-you-as-a-programmer" style="border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; color: #0077cc; font-family: inherit; font-size: 16px; font-style: inherit; font-weight: inherit; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; text-decoration: none; vertical-align: baseline;"&gt;my recent question on StackOverflow&lt;/a&gt;&amp;nbsp;along with some of my own experiences:&lt;/div&gt;&lt;h2 style="border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; clear: both; font-family: Georgia, 'Times New Roman', 'Bitstream Charter', Times, serif; font-size: 20px; font-style: italic; font-weight: normal; line-height: 22px; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 5px; padding-left: 0px; padding-right: 0px; padding-top: 5px; vertical-align: baseline;"&gt;10. Comments that explain the “how” but not the “why”&lt;/h2&gt;&lt;div style="border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; font-family: inherit; font-size: 16px; font-style: inherit; font-weight: inherit; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; vertical-align: baseline;"&gt;Introductory-level programming courses teach students to comment early and comment often. The idea is that it’s better to have too many comments than to have too few. Unfortunately, many programmers seem to take this as a personal challenge to comment&amp;nbsp;&lt;em style="border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; font-family: inherit; font-size: 16px; font-style: italic; font-weight: inherit; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; vertical-align: baseline;"&gt;every single line of code&lt;/em&gt;. This is why you will often see something like this code snippit taken from Jeff Atwood’s post on&amp;nbsp;&lt;a href="http://www.codinghorror.com/blog/archives/001150.html" style="border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; color: #0077cc; font-family: inherit; font-size: 16px; font-style: inherit; font-weight: inherit; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; text-decoration: none; vertical-align: baseline;"&gt;Coding Without Comments&lt;/a&gt;:&lt;/div&gt;&lt;div class="syntaxhighlighter  " id="highlighter_508675" style="-webkit-background-clip: initial !important; -webkit-background-origin: initial !important; background-attachment: initial !important; background-color: rgb(255, 255, 255) !important; background-image: none !important; background-position: initial initial !important; background-repeat: initial !important; border-bottom-width: 0px !important; border-color: initial !important; border-color: initial; border-left-width: 0px !important; border-right-width: 0px !important; border-style: initial !important; border-style: initial; border-top-width: 0px !important; bottom: auto !important; float: none !important; font-family: Consolas, 'Bitstream Vera Sans Mono', 'Courier New', Courier, monospace !important; font-size: 12px !important; font-style: normal !important; font-weight: normal !important; height: auto !important; left: auto !important; line-height: 1.1em !important; margin-bottom: 1em !important; margin-left: 0px !important; margin-right: 0px !important; margin-top: 1em !important; min-height: inherit !important; outline-color: initial !important; outline-style: initial !important; outline-width: 0px !important; padding-bottom: 1px !important; padding-left: 1px !important; padding-right: 1px !important; padding-top: 1px !important; position: relative !important; right: auto !important; text-align: left !important; top: auto !important; vertical-align: baseline !important; width: 643px;"&gt;&lt;div class="lines" style="-webkit-background-clip: initial !important; -webkit-background-origin: initial !important; background-attachment: initial !important; background-color: initial !important; background-image: none !important; background-position: initial initial !important; background-repeat: initial !important; border-bottom-width: 0px !important; border-color: initial !important; border-color: initial; border-left-width: 0px !important; border-right-width: 0px !important; border-style: initial !important; border-style: initial; border-top-width: 0px !important; bottom: auto !important; float: none !important; font-family: Consolas, 'Bitstream Vera Sans Mono', 'Courier New', Courier, monospace !important; font-size: 12px !important; font-style: normal !important; font-weight: normal !important; height: auto !important; left: auto !important; line-height: 1.1em !important; margin-bottom: 0px !important; margin-left: 0px !important; margin-right: 0px !important; margin-top: 0px !important; min-height: inherit !important; outline-color: initial !important; outline-style: initial !important; outline-width: 0px !important; padding-bottom: 0px !important; padding-left: 0px !important; padding-right: 0px !important; padding-top: 0px !important; position: static !important; right: auto !important; text-align: left !important; top: auto !important; vertical-align: baseline !important; width: auto !important;"&gt;&lt;div class="line alt1" style="-webkit-background-clip: initial !important; -webkit-background-origin: initial !important; background-attachment: initial !important; background-color: rgb(255, 255, 255) !important; background-image: none !important; background-position: initial initial !important; background-repeat: initial !important; border-bottom-width: 0px !important; border-color: initial !important; border-color: initial; border-left-width: 0px !important; border-right-width: 0px !important; border-style: initial !important; border-style: initial; border-top-width: 0px !important; bottom: auto !important; float: none !important; font-family: Consolas, 'Bitstream Vera Sans Mono', 'Courier New', Courier, monospace !important; font-size: 12px !important; font-style: normal !important; font-weight: normal !important; height: auto !important; left: auto !important; line-height: 1.1em !important; margin-bottom: 0px !important; margin-left: 0px !important; margin-right: 0px !important; margin-top: 0px !important; min-height: inherit !important; outline-color: initial !important; outline-style: initial !important; outline-width: 0px !important; padding-bottom: 0px !important; padding-left: 0px !important; padding-right: 0px !important; padding-top: 0px !important; position: static !important; right: auto !important; text-align: left !important; top: auto !important; vertical-align: baseline !important; width: auto !important;"&gt;&lt;table style="-webkit-background-clip: initial !important; -webkit-background-origin: initial !important; -webkit-border-horizontal-spacing: 0px; -webkit-border-vertical-spacing: 0px; background-attachment: initial !important; background-color: initial !important; background-image: none !important; background-position: initial initial !important; background-repeat: initial !important; border-bottom-width: 0px !important; border-collapse: collapse !important; border-color: initial !important; border-color: initial; border-left-width: 0px !important; border-right-width: 0px !important; border-style: initial !important; border-style: initial; border-top-width: 0px !important; bottom: auto !important; float: none !important; font-family: Consolas, 'Bitstream Vera Sans Mono', 'Courier New', Courier, monospace !important; font-size: 12px !important; font-style: normal !important; font-weight: normal !important; height: auto !important; left: auto !important; line-height: 1.1em !important; margin-bottom: 0px !important; margin-left: 0px !important; margin-right: 0px !important; margin-top: 0px !important; min-height: inherit !important; outline-color: initial !important; outline-style: initial !important; outline-width: 0px !important; padding-bottom: 0px !important; padding-left: 0px !important; padding-right: 0px !important; padding-top: 0px !important; position: static !important; right: auto !important; text-align: left !important; top: auto !important; vertical-align: baseline !important; width: auto !important;"&gt;&lt;tbody style="-webkit-background-clip: initial !important; -webkit-background-origin: initial !important; background-attachment: initial !important; background-color: initial !important; background-image: none !important; background-position: initial initial !important; background-repeat: initial !important; border-bottom-width: 0px !important; border-color: initial !important; border-color: initial; border-left-width: 0px !important; border-right-width: 0px !important; border-style: initial !important; border-style: initial; border-top-width: 0px !important; bottom: auto !important; float: none !important; font-family: Consolas, 'Bitstream Vera Sans Mono', 'Courier New', Courier, monospace !important; font-size: 12px !important; font-style: normal !important; font-weight: normal !important; height: auto !important; left: auto !important; line-height: 1.1em !important; margin-bottom: 0px !important; margin-left: 0px !important; margin-right: 0px !important; margin-top: 0px !important; min-height: inherit !important; outline-color: initial !important; outline-style: initial !important; outline-width: 0px !important; padding-bottom: 0px !important; padding-left: 0px !important; padding-right: 0px !important; padding-top: 0px !important; position: static !important; right: auto !important; text-align: left !important; top: auto !important; vertical-align: baseline !important; width: auto !important;"&gt;&lt;tr style="-webkit-background-clip: initial !important; -webkit-background-origin: initial !important; background-attachment: initial !important; background-color: initial !important; background-image: none !important; background-position: initial initial !important; background-repeat: initial !important; border-bottom-width: 0px !important; border-color: initial !important; border-color: initial; border-left-width: 0px !important; border-right-width: 0px !important; border-style: initial !important; border-style: initial; border-top-width: 0px !important; bottom: auto !important; float: none !important; font-family: Consolas, 'Bitstream Vera Sans Mono', 'Courier New', Courier, monospace !important; font-size: 12px !important; font-style: normal !important; font-weight: normal !important; height: auto !important; left: auto !important; line-height: 1.1em !important; margin-bottom: 0px !important; margin-left: 0px !important; margin-right: 0px !important; margin-top: 0px !important; min-height: inherit !important; outline-color: initial !important; outline-style: initial !important; outline-width: 0px !important; padding-bottom: 0px !important; padding-left: 0px !important; padding-right: 0px !important; padding-top: 0px !important; position: static !important; right: auto !important; text-align: left !important; top: auto !important; vertical-align: baseline !important; width: auto !important;"&gt;&lt;td class="number" style="-webkit-background-clip: initial !important; -webkit-background-origin: initial !important; background-attachment: initial !important; background-color: initial !important; background-image: none !important; background-position: initial initial !important; background-repeat: initial !important; border-bottom-width: 0px !important; border-color: initial !important; border-color: initial; border-left-width: 0px !important; border-right-width: 0px !important; border-style: initial !important; border-style: initial; border-top-width: 0px !important; bottom: auto !important; color: rgb(175, 175, 175) !important; float: none !important; font-family: Consolas, 'Bitstream Vera Sans Mono', 'Courier New', Courier, monospace !important; font-size: 12px !important; font-style: normal !important; font-weight: normal !important; height: auto !important; left: auto !important; line-height: 1.1em !important; margin-bottom: 0px !important; margin-left: 0px !important; margin-right: 0px !important; margin-top: 0px !important; min-height: inherit !important; outline-color: initial !important; outline-style: initial !important; outline-width: 0px !important; padding-bottom: 0px !important; padding-left: 0px !important; padding-right: 0px !important; padding-top: 0px !important; position: static !important; right: auto !important; text-align: left !important; top: auto !important; vertical-align: top !important; width: 3em !important;"&gt;&lt;code style="-webkit-background-clip: initial !important; -webkit-background-origin: initial !important; background-attachment: initial !important; background-color: initial !important; background-image: none !important; background-position: initial initial !important; background-repeat: initial !important; border-bottom-width: 0px !important; border-color: initial !important; border-color: initial; border-left-width: 0px !important; border-right-width: 0px !important; border-style: initial !important; border-style: initial; border-top-width: 0px !important; bottom: auto !important; display: block !important; float: none !important; font-family: Consolas, 'Bitstream Vera Sans Mono', 'Courier New', Courier, monospace !important; font-size: 12px !important; font-style: normal !important; font-weight: normal !important; font: normal normal normal 12px/1.4 Consolas, 'Andale Mono', Courier, 'Courier New', monospace; height: auto !important; left: auto !important; line-height: 1.1em !important; margin-bottom: 0px !important; margin-left: 0px !important; margin-right: 0px !important; margin-top: 0px !important; min-height: inherit !important; outline-color: initial !important; outline-style: initial !important; outline-width: 0px !important; padding-bottom: 0px !important; padding-left: 0px !important; padding-right: 0.3em !important; padding-top: 0px !important; position: static !important; right: auto !important; text-align: right !important; top: auto !important; vertical-align: baseline !important; width: 2.7em !important;"&gt;1&lt;/code&gt;&lt;/td&gt;&lt;td class="content" style="-webkit-background-clip: initial !important; -webkit-background-origin: initial !important; background-attachment: initial !important; background-color: initial !important; background-image: none !important; background-position: initial initial !important; background-repeat: initial !important; border-bottom-width: 0px !important; border-color: initial !important; border-color: initial; border-left-color: rgb(108, 226, 108) !important; border-left-style: solid !important; border-left-width: 3px !important; border-right-width: 0px !important; border-style: initial !important; border-style: initial; border-top-width: 0px !important; bottom: auto !important; color: rgb(0, 0, 0) !important; float: none !important; font-family: Consolas, 'Bitstream Vera Sans Mono', 'Courier New', Courier, monospace !important; font-size: 12px !important; font-style: normal !important; font-weight: normal !important; height: auto !important; left: auto !important; line-height: 1.1em !important; margin-bottom: 0px !important; margin-left: 0px !important; margin-right: 0px !important; margin-top: 0px !important; min-height: inherit !important; outline-color: initial !important; outline-style: initial !important; outline-width: 0px !important; padding-bottom: 0px !important; padding-left: 0.5em !important; padding-right: 0px !important; padding-top: 0px !important; position: static !important; right: auto !important; text-align: left !important; top: auto !important; vertical-align: top !important; width: auto !important;"&gt;&lt;code class="plain" style="-webkit-background-clip: initial !important; -webkit-background-origin: initial !important; background-attachment: initial !important; background-color: initial !important; background-image: none !important; background-position: initial initial !important; background-repeat: initial !important; border-bottom-width: 0px !important; border-color: initial !important; border-color: initial; border-left-width: 0px !important; border-right-width: 0px !important; border-style: initial !important; border-style: initial; border-top-width: 0px !important; bottom: auto !important; color: rgb(0, 0, 0) !important; float: none !important; font-family: Consolas, 'Bitstream Vera Sans Mono', 'Courier New', Courier, monospace !important; font-size: 12px !important; font-style: normal !important; font-weight: normal !important; font: normal normal normal 12px/1.4 Consolas, 'Andale Mono', Courier, 'Courier New', monospace; height: auto !important; left: auto !important; line-height: 1.1em !important; margin-bottom: 0px !important; margin-left: 0px !important; margin-right: 0px !important; margin-top: 0px !important; min-height: inherit !important; outline-color: initial !important; outline-style: initial !important; outline-width: 0px !important; padding-bottom: 0px !important; padding-left: 0px !important; padding-right: 0px !important; padding-top: 0px !important; position: static !important; right: auto !important; text-align: left !important; top: auto !important; vertical-align: baseline !important; width: auto !important;"&gt;r = n / 2;&amp;nbsp;&lt;/code&gt;&lt;code class="comments" style="-webkit-background-clip: initial !important; -webkit-background-origin: initial !important; background-attachment: initial !important; background-color: initial !important; background-image: none !important; background-position: initial initial !important; background-repeat: initial !important; border-bottom-width: 0px !important; border-color: initial !important; border-color: initial; border-left-width: 0px !important; border-right-width: 0px !important; border-style: initial !important; border-style: initial; border-top-width: 0px !important; bottom: auto !important; color: rgb(0, 130, 0) !important; float: none !important; font-family: Consolas, 'Bitstream Vera Sans Mono', 'Courier New', Courier, monospace !important; font-size: 12px !important; font-style: normal !important; font-weight: normal !important; font: normal normal normal 12px/1.4 Consolas, 'Andale Mono', Courier, 'Courier New', monospace; height: auto !important; left: auto !important; line-height: 1.1em !important; margin-bottom: 0px !important; margin-left: 0px !important; margin-right: 0px !important; margin-top: 0px !important; min-height: inherit !important; outline-color: initial !important; outline-style: initial !important; outline-width: 0px !important; padding-bottom: 0px !important; padding-left: 0px !important; padding-right: 0px !important; padding-top: 0px !important; position: static !important; right: auto !important; text-align: left !important; top: auto !important; vertical-align: baseline !important; width: auto !important;"&gt;// Set r to n divided by 2&lt;/code&gt;&lt;/td&gt;&lt;/tr&gt;&lt;/tbody&gt;&lt;/table&gt;&lt;/div&gt;&lt;div class="line alt2" style="-webkit-background-clip: initial !important; -webkit-background-origin: initial !important; background-attachment: initial !important; background-color: rgb(248, 248, 248) !important; background-image: none !important; background-position: initial initial !important; background-repeat: initial !important; border-bottom-width: 0px !important; border-color: initial !important; border-color: initial; border-left-width: 0px !important; border-right-width: 0px !important; border-style: initial !important; border-style: initial; border-top-width: 0px !important; bottom: auto !important; float: none !important; font-family: Consolas, 'Bitstream Vera Sans Mono', 'Courier New', Courier, monospace !important; font-size: 12px !important; font-style: normal !important; font-weight: normal !important; height: auto !important; left: auto !important; line-height: 1.1em !important; margin-bottom: 0px !important; margin-left: 0px !important; margin-right: 0px !important; margin-top: 0px !important; min-height: inherit !important; outline-color: initial !important; outline-style: initial !important; outline-width: 0px !important; padding-bottom: 0px !important; padding-left: 0px !important; padding-right: 0px !important; padding-top: 0px !important; position: static !important; right: auto !important; text-align: left !important; top: auto !important; vertical-align: baseline !important; width: auto !important;"&gt;&lt;table style="-webkit-background-clip: initial !important; -webkit-background-origin: initial !important; -webkit-border-horizontal-spacing: 0px; -webkit-border-vertical-spacing: 0px; background-attachment: initial !important; background-color: initial !important; background-image: none !important; background-position: initial initial !important; background-repeat: initial !important; border-bottom-width: 0px !important; border-collapse: collapse !important; border-color: initial !important; border-color: initial; border-left-width: 0px !important; border-right-width: 0px !important; border-style: initial !important; border-style: initial; border-top-width: 0px !important; bottom: auto !important; float: none !important; font-family: Consolas, 'Bitstream Vera Sans Mono', 'Courier New', Courier, monospace !important; font-size: 12px !important; font-style: normal !important; font-weight: normal !important; height: auto !important; left: auto !important; line-height: 1.1em !important; margin-bottom: 0px !important; margin-left: 0px !important; margin-right: 0px !important; margin-top: 0px !important; min-height: inherit !important; outline-color: initial !important; outline-style: initial !important; outline-width: 0px !important; padding-bottom: 0px !important; padding-left: 0px !important; padding-right: 0px !important; padding-top: 0px !important; position: static !important; right: auto !important; text-align: left !important; top: auto !important; vertical-align: baseline !important; width: auto !important;"&gt;&lt;tbody style="-webkit-background-clip: initial !important; -webkit-background-origin: initial !important; background-attachment: initial !important; background-color: initial !important; background-image: none !important; background-position: initial initial !important; background-repeat: initial !important; border-bottom-width: 0px !important; border-color: initial !important; border-color: initial; border-left-width: 0px !important; border-right-width: 0px !important; border-style: initial !important; border-style: initial; border-top-width: 0px !important; bottom: auto !important; float: none !important; font-family: Consolas, 'Bitstream Vera Sans Mono', 'Courier New', Courier, monospace !important; font-size: 12px !important; font-style: normal !important; font-weight: normal !important; height: auto !important; left: auto !important; line-height: 1.1em !important; margin-bottom: 0px !important; margin-left: 0px !important; margin-right: 0px !important; margin-top: 0px !important; min-height: inherit !important; outline-color: initial !important; outline-style: initial !important; outline-width: 0px !important; padding-bottom: 0px !important; padding-left: 0px !important; padding-right: 0px !important; padding-top: 0px !important; position: static !important; right: auto !important; text-align: left !important; top: auto !important; vertical-align: baseline !important; width: auto !important;"&gt;&lt;tr style="-webkit-background-clip: initial !important; -webkit-background-origin: initial !important; background-attachment: initial !important; background-color: initial !important; background-image: none !important; background-position: initial initial !important; background-repeat: initial !important; border-bottom-width: 0px !important; border-color: initial !important; border-color: initial; border-left-width: 0px !important; border-right-width: 0px !important; border-style: initial !important; border-style: initial; border-top-width: 0px !important; bottom: auto !important; float: none !important; font-family: Consolas, 'Bitstream Vera Sans Mono', 'Courier New', Courier, monospace !important; font-size: 12px !important; font-style: normal !important; font-weight: normal !important; height: auto !important; left: auto !important; line-height: 1.1em !important; margin-bottom: 0px !important; margin-left: 0px !important; margin-right: 0px !important; margin-top: 0px !important; min-height: inherit !important; outline-color: initial !important; outline-style: initial !important; outline-width: 0px !important; padding-bottom: 0px !important; padding-left: 0px !important; padding-right: 0px !important; padding-top: 0px !important; position: static !important; right: auto !important; text-align: left !important; top: auto !important; vertical-align: baseline !important; width: auto !important;"&gt;&lt;td class="number" style="-webkit-background-clip: initial !important; -webkit-background-origin: initial !important; background-attachment: initial !important; background-color: initial !important; background-image: none !important; background-position: initial initial !important; background-repeat: initial !important; border-bottom-width: 0px !important; border-color: initial !important; border-color: initial; border-left-width: 0px !important; border-right-width: 0px !important; border-style: initial !important; border-style: initial; border-top-width: 0px !important; bottom: auto !important; color: rgb(175, 175, 175) !important; float: none !important; font-family: Consolas, 'Bitstream Vera Sans Mono', 'Courier New', Courier, monospace !important; font-size: 12px !important; font-style: normal !important; font-weight: normal !important; height: auto !important; left: auto !important; line-height: 1.1em !important; margin-bottom: 0px !important; margin-left: 0px !important; margin-right: 0px !important; margin-top: 0px !important; min-height: inherit !important; outline-color: initial !important; outline-style: initial !important; outline-width: 0px !important; padding-bottom: 0px !important; padding-left: 0px !important; padding-right: 0px !important; padding-top: 0px !important; position: static !important; right: auto !important; text-align: left !important; top: auto !important; vertical-align: top !important; width: 3em !important;"&gt;&lt;code style="-webkit-background-clip: initial !important; -webkit-background-origin: initial !important; background-attachment: initial !important; background-color: initial !important; background-image: none !important; background-position: initial initial !important; background-repeat: initial !important; border-bottom-width: 0px !important; border-color: initial !important; border-color: initial; border-left-width: 0px !important; border-right-width: 0px !important; border-style: initial !important; border-style: initial; border-top-width: 0px !important; bottom: auto !important; display: block !important; float: none !important; font-family: Consolas, 'Bitstream Vera Sans Mono', 'Courier New', Courier, monospace !important; font-size: 12px !important; font-style: normal !important; font-weight: normal !important; font: normal normal normal 12px/1.4 Consolas, 'Andale Mono', Courier, 'Courier New', monospace; height: auto !important; left: auto !important; line-height: 1.1em !important; margin-bottom: 0px !important; margin-left: 0px !important; margin-right: 0px !important; margin-top: 0px !important; min-height: inherit !important; outline-color: initial !important; outline-style: initial !important; outline-width: 0px !important; padding-bottom: 0px !important; padding-left: 0px !important; padding-right: 0.3em !important; padding-top: 0px !important; position: static !important; right: auto !important; text-align: right !important; top: auto !important; vertical-align: baseline !important; width: 2.7em !important;"&gt;2&lt;/code&gt;&lt;/td&gt;&lt;td class="content" style="-webkit-background-clip: initial !important; -webkit-background-origin: initial !important; background-attachment: initial !important; background-color: initial !important; background-image: none !important; background-position: initial initial !important; background-repeat: initial !important; border-bottom-width: 0px !important; border-color: initial !important; border-color: initial; border-left-color: rgb(108, 226, 108) !important; border-left-style: solid !important; border-left-width: 3px !important; border-right-width: 0px !important; border-style: initial !important; border-style: initial; border-top-width: 0px !important; bottom: auto !important; color: rgb(0, 0, 0) !important; float: none !important; font-family: Consolas, 'Bitstream Vera Sans Mono', 'Courier New', Courier, monospace !important; font-size: 12px !important; font-style: normal !important; font-weight: normal !important; height: auto !important; left: auto !important; line-height: 1.1em !important; margin-bottom: 0px !important; margin-left: 0px !important; margin-right: 0px !important; margin-top: 0px !important; min-height: inherit !important; outline-color: initial !important; outline-style: initial !important; outline-width: 0px !important; padding-bottom: 0px !important; padding-left: 0.5em !important; padding-right: 0px !important; padding-top: 0px !important; position: static !important; right: auto !important; text-align: left !important; top: auto !important; vertical-align: top !important; width: auto !important;"&gt;&lt;/td&gt;&lt;/tr&gt;&lt;/tbody&gt;&lt;/table&gt;&lt;/div&gt;&lt;div class="line alt1" style="-webkit-background-clip: initial !important; -webkit-background-origin: initial !important; background-attachment: initial !important; background-color: rgb(255, 255, 255) !important; background-image: none !important; background-position: initial initial !important; background-repeat: initial !important; border-bottom-width: 0px !important; border-color: initial !important; border-color: initial; border-left-width: 0px !important; border-right-width: 0px !important; border-style: initial !important; border-style: initial; border-top-width: 0px !important; bottom: auto !important; float: none !important; font-family: Consolas, 'Bitstream Vera Sans Mono', 'Courier New', Courier, monospace !important; font-size: 12px !important; font-style: normal !important; font-weight: normal !important; height: auto !important; left: auto !important; line-height: 1.1em !important; margin-bottom: 0px !important; margin-left: 0px !important; margin-right: 0px !important; margin-top: 0px !important; min-height: inherit !important; outline-color: initial !important; outline-style: initial !important; outline-width: 0px !important; padding-bottom: 0px !important; padding-left: 0px !important; padding-right: 0px !important; padding-top: 0px !important; position: static !important; right: auto !important; text-align: left !important; top: auto !important; vertical-align: baseline !important; width: auto !important;"&gt;&lt;table style="-webkit-background-clip: initial !important; -webkit-background-origin: initial !important; -webkit-border-horizontal-spacing: 0px; -webkit-border-vertical-spacing: 0px; background-attachment: initial !important; background-color: initial !important; background-image: none !important; background-position: initial initial !important; background-repeat: initial !important; border-bottom-width: 0px !important; border-collapse: collapse !important; border-color: initial !important; border-color: initial; border-left-width: 0px !important; border-right-width: 0px !important; border-style: initial !important; border-style: initial; border-top-width: 0px !important; bottom: auto !important; float: none !important; font-family: Consolas, 'Bitstream Vera Sans Mono', 'Courier New', Courier, monospace !important; font-size: 12px !important; font-style: normal !important; font-weight: normal !important; height: auto !important; left: auto !important; line-height: 1.1em !important; margin-bottom: 0px !important; margin-left: 0px !important; margin-right: 0px !important; margin-top: 0px !important; min-height: inherit !important; outline-color: initial !important; outline-style: initial !important; outline-width: 0px !important; padding-bottom: 0px !important; padding-left: 0px !important; padding-right: 0px !important; padding-top: 0px !important; position: static !important; right: auto !important; text-align: left !important; top: auto !important; vertical-align: baseline !important; width: auto !important;"&gt;&lt;tbody style="-webkit-background-clip: initial !important; -webkit-background-origin: initial !important; background-attachment: initial !important; background-color: initial !important; background-image: none !important; background-position: initial initial !important; background-repeat: initial !important; border-bottom-width: 0px !important; border-color: initial !important; border-color: initial; border-left-width: 0px !important; border-right-width: 0px !important; border-style: initial !important; border-style: initial; border-top-width: 0px !important; bottom: auto !important; float: none !important; font-family: Consolas, 'Bitstream Vera Sans Mono', 'Courier New', Courier, monospace !important; font-size: 12px !important; font-style: normal !important; font-weight: normal !important; height: auto !important; left: auto !important; line-height: 1.1em !important; margin-bottom: 0px !important; margin-left: 0px !important; margin-right: 0px !important; margin-top: 0px !important; min-height: inherit !important; outline-color: initial !important; outline-style: initial !important; outline-width: 0px !important; padding-bottom: 0px !important; padding-left: 0px !important; padding-right: 0px !important; padding-top: 0px !important; position: static !important; right: auto !important; text-align: left !important; top: auto !important; vertical-align: baseline !important; width: auto !important;"&gt;&lt;tr style="-webkit-background-clip: initial !important; -webkit-background-origin: initial !important; background-attachment: initial !important; background-color: initial !important; background-image: none !important; background-position: initial initial !important; background-repeat: initial !important; border-bottom-width: 0px !important; border-color: initial !important; border-color: initial; border-left-width: 0px !important; border-right-width: 0px !important; border-style: initial !important; border-style: initial; border-top-width: 0px !important; bottom: auto !important; float: none !important; font-family: Consolas, 'Bitstream Vera Sans Mono', 'Courier New', Courier, monospace !important; font-size: 12px !important; font-style: normal !important; font-weight: normal !important; height: auto !important; left: auto !important; line-height: 1.1em !important; margin-bottom: 0px !important; margin-left: 0px !important; margin-right: 0px !important; margin-top: 0px !important; min-height: inherit !important; outline-color: initial !important; outline-style: initial !important; outline-width: 0px !important; padding-bottom: 0px !important; padding-left: 0px !important; padding-right: 0px !important; padding-top: 0px !important; position: static !important; right: auto !important; text-align: left !important; top: auto !important; vertical-align: baseline !important; width: auto !important;"&gt;&lt;td class="number" style="-webkit-background-clip: initial !important; -webkit-background-origin: initial !important; background-attachment: initial !important; background-color: initial !important; background-image: none !important; background-position: initial initial !important; background-repeat: initial !important; border-bottom-width: 0px !important; border-color: initial !important; border-color: initial; border-left-width: 0px !important; border-right-width: 0px !important; border-style: initial !important; border-style: initial; border-top-width: 0px !important; bottom: auto !important; color: rgb(175, 175, 175) !important; float: none !important; font-family: Consolas, 'Bitstream Vera Sans Mono', 'Courier New', Courier, monospace !important; font-size: 12px !important; font-style: normal !important; font-weight: normal !important; height: auto !important; left: auto !important; line-height: 1.1em !important; margin-bottom: 0px !important; margin-left: 0px !important; margin-right: 0px !important; margin-top: 0px !important; min-height: inherit !important; outline-color: initial !important; outline-style: initial !important; outline-width: 0px !important; padding-bottom: 0px !important; padding-left: 0px !important; padding-right: 0px !important; padding-top: 0px !important; position: static !important; right: auto !important; text-align: left !important; top: auto !important; vertical-align: top !important; width: 3em !important;"&gt;&lt;code style="-webkit-background-clip: initial !important; -webkit-background-origin: initial !important; background-attachment: initial !important; background-color: initial !important; background-image: none !important; background-position: initial initial !important; background-repeat: initial !important; border-bottom-width: 0px !important; border-color: initial !important; border-color: initial; border-left-width: 0px !important; border-right-width: 0px !important; border-style: initial !important; border-style: initial; border-top-width: 0px !important; bottom: auto !important; display: block !important; float: none !important; font-family: Consolas, 'Bitstream Vera Sans Mono', 'Courier New', Courier, monospace !important; font-size: 12px !important; font-style: normal !important; font-weight: normal !important; font: normal normal normal 12px/1.4 Consolas, 'Andale Mono', Courier, 'Courier New', monospace; height: auto !important; left: auto !important; line-height: 1.1em !important; margin-bottom: 0px !important; margin-left: 0px !important; margin-right: 0px !important; margin-top: 0px !important; min-height: inherit !important; outline-color: initial !important; outline-style: initial !important; outline-width: 0px !important; padding-bottom: 0px !important; padding-left: 0px !important; padding-right: 0.3em !important; padding-top: 0px !important; position: static !important; right: auto !important; text-align: right !important; top: auto !important; vertical-align: baseline !important; width: 2.7em !important;"&gt;3&lt;/code&gt;&lt;/td&gt;&lt;td class="content" style="-webkit-background-clip: initial !important; -webkit-background-origin: initial !important; background-attachment: initial !important; background-color: initial !important; background-image: none !important; background-position: initial initial !important; background-repeat: initial !important; border-bottom-width: 0px !important; border-color: initial !important; border-color: initial; border-left-color: rgb(108, 226, 108) !important; border-left-style: solid !important; border-left-width: 3px !important; border-right-width: 0px !important; border-style: initial !important; border-style: initial; border-top-width: 0px !important; bottom: auto !important; color: rgb(0, 0, 0) !important; float: none !important; font-family: Consolas, 'Bitstream Vera Sans Mono', 'Courier New', Courier, monospace !important; font-size: 12px !important; font-style: normal !important; font-weight: normal !important; height: auto !important; left: auto !important; line-height: 1.1em !important; margin-bottom: 0px !important; margin-left: 0px !important; margin-right: 0px !important; margin-top: 0px !important; min-height: inherit !important; outline-color: initial !important; outline-style: initial !important; outline-width: 0px !important; padding-bottom: 0px !important; padding-left: 0.5em !important; padding-right: 0px !important; padding-top: 0px !important; position: static !important; right: auto !important; text-align: left !important; top: auto !important; vertical-align: top !important; width: auto !important;"&gt;&lt;code class="comments" style="-webkit-background-clip: initial !important; -webkit-background-origin: initial !important; background-attachment: initial !important; background-color: initial !important; background-image: none !important; background-position: initial initial !important; background-repeat: initial !important; border-bottom-width: 0px !important; border-color: initial !important; border-color: initial; border-left-width: 0px !important; border-right-width: 0px !important; border-style: initial !important; border-style: initial; border-top-width: 0px !important; bottom: auto !important; color: rgb(0, 130, 0) !important; float: none !important; font-family: Consolas, 'Bitstream Vera Sans Mono', 'Courier New', Courier, monospace !important; font-size: 12px !important; font-style: normal !important; font-weight: normal !important; font: normal normal normal 12px/1.4 Consolas, 'Andale Mono', Courier, 'Courier New', monospace; height: auto !important; left: auto !important; line-height: 1.1em !important; margin-bottom: 0px !important; margin-left: 0px !important; margin-right: 0px !important; margin-top: 0px !important; min-height: inherit !important; outline-color: initial !important; outline-style: initial !important; outline-width: 0px !important; padding-bottom: 0px !important; padding-left: 0px !important; padding-right: 0px !important; padding-top: 0px !important; position: static !important; right: auto !important; text-align: left !important; top: auto !important; vertical-align: baseline !important; width: auto !important;"&gt;// Loop while r - (n/r) is greater than t&lt;/code&gt;&lt;/td&gt;&lt;/tr&gt;&lt;/tbody&gt;&lt;/table&gt;&lt;/div&gt;&lt;div class="line alt2" style="-webkit-background-clip: initial !important; -webkit-background-origin: initial !important; background-attachment: initial !important; background-color: rgb(248, 248, 248) !important; background-image: none !important; background-position: initial initial !important; background-repeat: initial !important; border-bottom-width: 0px !important; border-color: initial !important; border-color: initial; border-left-width: 0px !important; border-right-width: 0px !important; border-style: initial !important; border-style: initial; border-top-width: 0px !important; bottom: auto !important; float: none !important; font-family: Consolas, 'Bitstream Vera Sans Mono', 'Courier New', Courier, monospace !important; font-size: 12px !important; font-style: normal !important; font-weight: normal !important; height: auto !important; left: auto !important; line-height: 1.1em !important; margin-bottom: 0px !important; margin-left: 0px !important; margin-right: 0px !important; margin-top: 0px !important; min-height: inherit !important; outline-color: initial !important; outline-style: initial !important; outline-width: 0px !important; padding-bottom: 0px !important; padding-left: 0px !important; padding-right: 0px !important; padding-top: 0px !important; position: static !important; right: auto !important; text-align: left !important; top: auto !important; vertical-align: baseline !important; width: auto !important;"&gt;&lt;table style="-webkit-background-clip: initial !important; -webkit-background-origin: initial !important; -webkit-border-horizontal-spacing: 0px; -webkit-border-vertical-spacing: 0px; background-attachment: initial !important; background-color: initial !important; background-image: none !important; background-position: initial initial !important; background-repeat: initial !important; border-bottom-width: 0px !important; border-collapse: collapse !important; border-color: initial !important; border-color: initial; border-left-width: 0px !important; border-right-width: 0px !important; border-style: initial !important; border-style: initial; border-top-width: 0px !important; bottom: auto !important; float: none !important; font-family: Consolas, 'Bitstream Vera Sans Mono', 'Courier New', Courier, monospace !important; font-size: 12px !important; font-style: normal !important; font-weight: normal !important; height: auto !important; left: auto !important; line-height: 1.1em !important; margin-bottom: 0px !important; margin-left: 0px !important; margin-right: 0px !important; margin-top: 0px !important; min-height: inherit !important; outline-color: initial !important; outline-style: initial !important; outline-width: 0px !important; padding-bottom: 0px !important; padding-left: 0px !important; padding-right: 0px !important; padding-top: 0px !important; position: static !important; right: auto !important; text-align: left !important; top: auto !important; vertical-align: baseline !important; width: auto !important;"&gt;&lt;tbody style="-webkit-background-clip: initial !important; -webkit-background-origin: initial !important; background-attachment: initial !important; background-color: initial !important; background-image: none !important; background-position: initial initial !important; background-repeat: initial !important; border-bottom-width: 0px !important; border-color: initial !important; border-color: initial; border-left-width: 0px !important; border-right-width: 0px !important; border-style: initial !important; border-style: initial; border-top-width: 0px !important; bottom: auto !important; float: none !important; font-family: Consolas, 'Bitstream Vera Sans Mono', 'Courier New', Courier, monospace !important; font-size: 12px !important; font-style: normal !important; font-weight: normal !important; height: auto !important; left: auto !important; line-height: 1.1em !important; margin-bottom: 0px !important; margin-left: 0px !important; margin-right: 0px !important; margin-top: 0px !important; min-height: inherit !important; outline-color: initial !important; outline-style: initial !important; outline-width: 0px !important; padding-bottom: 0px !important; padding-left: 0px !important; padding-right: 0px !important; padding-top: 0px !important; position: static !important; right: auto !important; text-align: left !important; top: auto !important; vertical-align: baseline !important; width: auto !important;"&gt;&lt;tr style="-webkit-background-clip: initial !important; -webkit-background-origin: initial !important; background-attachment: initial !important; background-color: initial !important; background-image: none !important; background-position: initial initial !important; background-repeat: initial !important; border-bottom-width: 0px !important; border-color: initial !important; border-color: initial; border-left-width: 0px !important; border-right-width: 0px !important; border-style: initial !important; border-style: initial; border-top-width: 0px !important; bottom: auto !important; float: none !important; font-family: Consolas, 'Bitstream Vera Sans Mono', 'Courier New', Courier, monospace !important; font-size: 12px !important; font-style: normal !important; font-weight: normal !important; height: auto !important; left: auto !important; line-height: 1.1em !important; margin-bottom: 0px !important; margin-left: 0px !important; margin-right: 0px !important; margin-top: 0px !important; min-height: inherit !important; outline-color: initial !important; outline-style: initial !important; outline-width: 0px !important; padding-bottom: 0px !important; padding-left: 0px !important; padding-right: 0px !important; padding-top: 0px !important; position: static !important; right: auto !important; text-align: left !important; top: auto !important; vertical-align: baseline !important; width: auto !important;"&gt;&lt;td class="number" style="-webkit-background-clip: initial !important; -webkit-background-origin: initial !important; background-attachment: initial !important; background-color: initial !important; background-image: none !important; background-position: initial initial !important; background-repeat: initial !important; border-bottom-width: 0px !important; border-color: initial !important; border-color: initial; border-left-width: 0px !important; border-right-width: 0px !important; border-style: initial !important; border-style: initial; border-top-width: 0px !important; bottom: auto !important; color: rgb(175, 175, 175) !important; float: none !important; font-family: Consolas, 'Bitstream Vera Sans Mono', 'Courier New', Courier, monospace !important; font-size: 12px !important; font-style: normal !important; font-weight: normal !important; height: auto !important; left: auto !important; line-height: 1.1em !important; margin-bottom: 0px !important; margin-left: 0px !important; margin-right: 0px !important; margin-top: 0px !important; min-height: inherit !important; outline-color: initial !important; outline-style: initial !important; outline-width: 0px !important; padding-bottom: 0px !important; padding-left: 0px !important; padding-right: 0px !important; padding-top: 0px !important; position: static !important; right: auto !important; text-align: left !important; top: auto !important; vertical-align: top !important; width: 3em !important;"&gt;&lt;code style="-webkit-background-clip: initial !important; -webkit-background-origin: initial !important; background-attachment: initial !important; background-color: initial !important; background-image: none !important; background-position: initial initial !important; background-repeat: initial !important; border-bottom-width: 0px !important; border-color: initial !important; border-color: initial; border-left-width: 0px !important; border-right-width: 0px !important; border-style: initial !important; border-style: initial; border-top-width: 0px !important; bottom: auto !important; display: block !important; float: none !important; font-family: Consolas, 'Bitstream Vera Sans Mono', 'Courier New', Courier, monospace !important; font-size: 12px !important; font-style: normal !important; font-weight: normal !important; font: normal normal normal 12px/1.4 Consolas, 'Andale Mono', Courier, 'Courier New', monospace; height: auto !important; left: auto !important; line-height: 1.1em !important; margin-bottom: 0px !important; margin-left: 0px !important; margin-right: 0px !important; margin-top: 0px !important; min-height: inherit !important; outline-color: initial !important; outline-style: initial !important; outline-width: 0px !important; padding-bottom: 0px !important; padding-left: 0px !important; padding-right: 0.3em !important; padding-top: 0px !important; position: static !important; right: auto !important; text-align: right !important; top: auto !important; vertical-align: baseline !important; width: 2.7em !important;"&gt;4&lt;/code&gt;&lt;/td&gt;&lt;td class="content" style="-webkit-background-clip: initial !important; -webkit-background-origin: initial !important; background-attachment: initial !important; background-color: initial !important; background-image: none !important; background-position: initial initial !important; background-repeat: initial !important; border-bottom-width: 0px !important; border-color: initial !important; border-color: initial; border-left-color: rgb(108, 226, 108) !important; border-left-style: solid !important; border-left-width: 3px !important; border-right-width: 0px !important; border-style: initial !important; border-style: initial; border-top-width: 0px !important; bottom: auto !important; color: rgb(0, 0, 0) !important; float: none !important; font-family: Consolas, 'Bitstream Vera Sans Mono', 'Courier New', Courier, monospace !important; font-size: 12px !important; font-style: normal !important; font-weight: normal !important; height: auto !important; left: auto !important; line-height: 1.1em !important; margin-bottom: 0px !important; margin-left: 0px !important; margin-right: 0px !important; margin-top: 0px !important; min-height: inherit !important; outline-color: initial !important; outline-style: initial !important; outline-width: 0px !important; padding-bottom: 0px !important; padding-left: 0.5em !important; padding-right: 0px !important; padding-top: 0px !important; position: static !important; right: auto !important; text-align: left !important; top: auto !important; vertical-align: top !important; width: auto !important;"&gt;&lt;code class="keyword" style="-webkit-background-clip: initial !important; -webkit-background-origin: initial !important; background-attachment: initial !important; background-color: initial !important; background-image: none !important; background-position: initial initial !important; background-repeat: initial !important; border-bottom-width: 0px !important; border-color: initial !important; border-color: initial; border-left-width: 0px !important; border-right-width: 0px !important; border-style: initial !important; border-style: initial; border-top-width: 0px !important; bottom: auto !important; color: rgb(0, 102, 153) !important; float: none !important; font-family: Consolas, 'Bitstream Vera Sans Mono', 'Courier New', Courier, monospace !important; font-size: 12px !important; font-style: normal !important; font-weight: bold !important; font: normal normal normal 12px/1.4 Consolas, 'Andale Mono', Courier, 'Courier New', monospace; height: auto !important; left: auto !important; line-height: 1.1em !important; margin-bottom: 0px !important; margin-left: 0px !important; margin-right: 0px !important; margin-top: 0px !important; min-height: inherit !important; outline-color: initial !important; outline-style: initial !important; outline-width: 0px !important; padding-bottom: 0px !important; padding-left: 0px !important; padding-right: 0px !important; padding-top: 0px !important; position: static !important; right: auto !important; text-align: left !important; top: auto !important; vertical-align: baseline !important; width: auto !important;"&gt;while&lt;/code&gt;&amp;nbsp;&lt;code class="plain" style="-webkit-background-clip: initial !important; -webkit-background-origin: initial !important; background-attachment: initial !important; background-color: initial !important; background-image: none !important; background-position: initial initial !important; background-repeat: initial !important; border-bottom-width: 0px !important; border-color: initial !important; border-color: initial; border-left-width: 0px !important; border-right-width: 0px !important; border-style: initial !important; border-style: initial; border-top-width: 0px !important; bottom: auto !important; color: rgb(0, 0, 0) !important; float: none !important; font-family: Consolas, 'Bitstream Vera Sans Mono', 'Courier New', Courier, monospace !important; font-size: 12px !important; font-style: normal !important; font-weight: normal !important; font: normal normal normal 12px/1.4 Consolas, 'Andale Mono', Courier, 'Courier New', monospace; height: auto !important; left: auto !important; line-height: 1.1em !important; margin-bottom: 0px !important; margin-left: 0px !important; margin-right: 0px !important; margin-top: 0px !important; min-height: inherit !important; outline-color: initial !important; outline-style: initial !important; outline-width: 0px !important; padding-bottom: 0px !important; padding-left: 0px !important; padding-right: 0px !important; padding-top: 0px !important; position: static !important; right: auto !important; text-align: left !important; top: auto !important; vertical-align: baseline !important; width: auto !important;"&gt;( abs( r - (n/r) ) &amp;gt; t ) {&lt;/code&gt;&lt;/td&gt;&lt;/tr&gt;&lt;/tbody&gt;&lt;/table&gt;&lt;/div&gt;&lt;div class="line alt1" style="-webkit-background-clip: initial !important; -webkit-background-origin: initial !important; background-attachment: initial !important; background-color: rgb(255, 255, 255) !important; background-image: none !important; background-position: initial initial !important; background-repeat: initial !important; border-bottom-width: 0px !important; border-color: initial !important; border-color: initial; border-left-width: 0px !important; border-right-width: 0px !important; border-style: initial !important; border-style: initial; border-top-width: 0px !important; bottom: auto !important; float: none !important; font-family: Consolas, 'Bitstream Vera Sans Mono', 'Courier New', Courier, monospace !important; font-size: 12px !important; font-style: normal !important; font-weight: normal !important; height: auto !important; left: auto !important; line-height: 1.1em !important; margin-bottom: 0px !important; margin-left: 0px !important; margin-right: 0px !important; margin-top: 0px !important; min-height: inherit !important; outline-color: initial !important; outline-style: initial !important; outline-width: 0px !important; padding-bottom: 0px !important; padding-left: 0px !important; padding-right: 0px !important; padding-top: 0px !important; position: static !important; right: auto !important; text-align: left !important; top: auto !important; vertical-align: baseline !important; width: auto !important;"&gt;&lt;table style="-webkit-background-clip: initial !important; -webkit-background-origin: initial !important; -webkit-border-horizontal-spacing: 0px; -webkit-border-vertical-spacing: 0px; background-attachment: initial !important; background-color: initial !important; background-image: none !important; background-position: initial initial !important; background-repeat: initial !important; border-bottom-width: 0px !important; border-collapse: collapse !important; border-color: initial !important; border-color: initial; border-left-width: 0px !important; border-right-width: 0px !important; border-style: initial !important; border-style: initial; border-top-width: 0px !important; bottom: auto !important; float: none !important; font-family: Consolas, 'Bitstream Vera Sans Mono', 'Courier New', Courier, monospace !important; font-size: 12px !important; font-style: normal !important; font-weight: normal !important; height: auto !important; left: auto !important; line-height: 1.1em !important; margin-bottom: 0px !important; margin-left: 0px !important; margin-right: 0px !important; margin-top: 0px !important; min-height: inherit !important; outline-color: initial !important; outline-style: initial !important; outline-width: 0px !important; padding-bottom: 0px !important; padding-left: 0px !important; padding-right: 0px !important; padding-top: 0px !important; position: static !important; right: auto !important; text-align: left !important; top: auto !important; vertical-align: baseline !important; width: auto !important;"&gt;&lt;tbody style="-webkit-background-clip: initial !important; -webkit-background-origin: initial !important; background-attachment: initial !important; background-color: initial !important; background-image: none !important; background-position: initial initial !important; background-repeat: initial !important; border-bottom-width: 0px !important; border-color: initial !important; border-color: initial; border-left-width: 0px !important; border-right-width: 0px !important; border-style: initial !important; border-style: initial; border-top-width: 0px !important; bottom: auto !important; float: none !important; font-family: Consolas, 'Bitstream Vera Sans Mono', 'Courier New', Courier, monospace !important; font-size: 12px !important; font-style: normal !important; font-weight: normal !important; height: auto !important; left: auto !important; line-height: 1.1em !important; margin-bottom: 0px !important; margin-left: 0px !important; margin-right: 0px !important; margin-top: 0px !important; min-height: inherit !important; outline-color: initial !important; outline-style: initial !important; outline-width: 0px !important; padding-bottom: 0px !important; padding-left: 0px !important; padding-right: 0px !important; padding-top: 0px !important; position: static !important; right: auto !important; text-align: left !important; top: auto !important; vertical-align: baseline !important; width: auto !important;"&gt;&lt;tr style="-webkit-background-clip: initial !important; -webkit-background-origin: initial !important; background-attachment: initial !important; background-color: initial !important; background-image: none !important; background-position: initial initial !important; background-repeat: initial !important; border-bottom-width: 0px !important; border-color: initial !important; border-color: initial; border-left-width: 0px !important; border-right-width: 0px !important; border-style: initial !important; border-style: initial; border-top-width: 0px !important; bottom: auto !important; float: none !important; font-family: Consolas, 'Bitstream Vera Sans Mono', 'Courier New', Courier, monospace !important; font-size: 12px !important; font-style: normal !important; font-weight: normal !important; height: auto !important; left: auto !important; line-height: 1.1em !important; margin-bottom: 0px !important; margin-left: 0px !important; margin-right: 0px !important; margin-top: 0px !important; min-height: inherit !important; outline-color: initial !important; outline-style: initial !important; outline-width: 0px !important; padding-bottom: 0px !important; padding-left: 0px !important; padding-right: 0px !important; padding-top: 0px !important; position: static !important; right: auto !important; text-align: left !important; top: auto !important; vertical-align: baseline !important; width: auto !important;"&gt;&lt;td class="number" style="-webkit-background-clip: initial !important; -webkit-background-origin: initial !important; background-attachment: initial !important; background-color: initial !important; background-image: none !important; background-position: initial initial !important; background-repeat: initial !important; border-bottom-width: 0px !important; border-color: initial !important; border-color: initial; border-left-width: 0px !important; border-right-width: 0px !important; border-style: initial !important; border-style: initial; border-top-width: 0px !important; bottom: auto !important; color: rgb(175, 175, 175) !important; float: none !important; font-family: Consolas, 'Bitstream Vera Sans Mono', 'Courier New', Courier, monospace !important; font-size: 12px !important; font-style: normal !important; font-weight: normal !important; height: auto !important; left: auto !important; line-height: 1.1em !important; margin-bottom: 0px !important; margin-left: 0px !important; margin-right: 0px !important; margin-top: 0px !important; min-height: inherit !important; outline-color: initial !important; outline-style: initial !important; outline-width: 0px !important; padding-bottom: 0px !important; padding-left: 0px !important; padding-right: 0px !important; padding-top: 0px !important; position: static !important; right: auto !important; text-align: left !important; top: auto !important; vertical-align: top !important; width: 3em !important;"&gt;&lt;code style="-webkit-background-clip: initial !important; -webkit-background-origin: initial !important; background-attachment: initial !important; background-color: initial !important; background-image: none !important; background-position: initial initial !important; background-repeat: initial !important; border-bottom-width: 0px !important; border-color: initial !important; border-color: initial; border-left-width: 0px !important; border-right-width: 0px !important; border-style: initial !important; border-style: initial; border-top-width: 0px !important; bottom: auto !important; display: block !important; float: none !important; font-family: Consolas, 'Bitstream Vera Sans Mono', 'Courier New', Courier, monospace !important; font-size: 12px !important; font-style: normal !important; font-weight: normal !important; font: normal normal normal 12px/1.4 Consolas, 'Andale Mono', Courier, 'Courier New', monospace; height: auto !important; left: auto !important; line-height: 1.1em !important; margin-bottom: 0px !important; margin-left: 0px !important; margin-right: 0px !important; margin-top: 0px !important; min-height: inherit !important; outline-color: initial !important; outline-style: initial !important; outline-width: 0px !important; padding-bottom: 0px !important; padding-left: 0px !important; padding-right: 0.3em !important; padding-top: 0px !important; position: static !important; right: auto !important; text-align: right !important; top: auto !important; vertical-align: baseline !important; width: 2.7em !important;"&gt;5&lt;/code&gt;&lt;/td&gt;&lt;td class="content" style="-webkit-background-clip: initial !important; -webkit-background-origin: initial !important; background-attachment: initial !important; background-color: initial !important; background-image: none !important; background-position: initial initial !important; background-repeat: initial !important; border-bottom-width: 0px !important; border-color: initial !important; border-color: initial; border-left-color: rgb(108, 226, 108) !important; border-left-style: solid !important; border-left-width: 3px !important; border-right-width: 0px !important; border-style: initial !important; border-style: initial; border-top-width: 0px !important; bottom: auto !important; color: rgb(0, 0, 0) !important; float: none !important; font-family: Consolas, 'Bitstream Vera Sans Mono', 'Courier New', Courier, monospace !important; font-size: 12px !important; font-style: normal !important; font-weight: normal !important; height: auto !important; left: auto !important; line-height: 1.1em !important; margin-bottom: 0px !important; margin-left: 0px !important; margin-right: 0px !important; margin-top: 0px !important; min-height: inherit !important; outline-color: initial !important; outline-style: initial !important; outline-width: 0px !important; padding-bottom: 0px !important; padding-left: 0.5em !important; padding-right: 0px !important; padding-top: 0px !important; position: static !important; right: auto !important; text-align: left !important; top: auto !important; vertical-align: top !important; width: auto !important;"&gt;&lt;code class="spaces" style="-webkit-background-clip: initial !important; -webkit-background-origin: initial !important; background-attachment: initial !important; background-color: initial !important; background-image: none !important; background-position: initial initial !important; background-repeat: initial !important; border-bottom-width: 0px !important; border-color: initial !important; border-color: initial; border-left-width: 0px !important; border-right-width: 0px !important; border-style: initial !important; border-style: initial; border-top-width: 0px !important; bottom: auto !important; float: none !important; font-family: Consolas, 'Bitstream Vera Sans Mono', 'Courier New', Courier, monospace !important; font-size: 12px !important; font-style: normal !important; font-weight: normal !important; font: normal normal normal 12px/1.4 Consolas, 'Andale Mono', Courier, 'Courier New', monospace; height: auto !important; left: auto !important; line-height: 1.1em !important; margin-bottom: 0px !important; margin-left: 0px !important; margin-right: 0px !important; margin-top: 0px !important; min-height: inherit !important; outline-color: initial !important; outline-style: initial !important; outline-width: 0px !important; padding-bottom: 0px !important; padding-left: 0px !important; padding-right: 0px !important; padding-top: 0px !important; position: static !important; right: auto !important; text-align: left !important; top: auto !important; vertical-align: baseline !important; width: auto !important;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;/code&gt;&lt;code class="plain" style="-webkit-background-clip: initial !important; -webkit-background-origin: initial !important; background-attachment: initial !important; background-color: initial !important; background-image: none !important; background-position: initial initial !important; background-repeat: initial !important; border-bottom-width: 0px !important; border-color: initial !important; border-color: initial; border-left-width: 0px !important; border-right-width: 0px !important; border-style: initial !important; border-style: initial; border-top-width: 0px !important; bottom: auto !important; color: rgb(0, 0, 0) !important; float: none !important; font-family: Consolas, 'Bitstream Vera Sans Mono', 'Courier New', Courier, monospace !important; font-size: 12px !important; font-style: normal !important; font-weight: normal !important; font: normal normal normal 12px/1.4 Consolas, 'Andale Mono', Courier, 'Courier New', monospace; height: auto !important; left: auto !important; line-height: 1.1em !important; margin-bottom: 0px !important; margin-left: 0px !important; margin-right: 0px !important; margin-top: 0px !important; min-height: inherit !important; outline-color: initial !important; outline-style: initial !important; outline-width: 0px !important; padding-bottom: 0px !important; padding-left: 0px !important; padding-right: 0px !important; padding-top: 0px !important; position: static !important; right: auto !important; text-align: left !important; top: auto !important; vertical-align: baseline !important; width: auto !important;"&gt;r = 0.5 * ( r + (n/r) );&amp;nbsp;&lt;/code&gt;&lt;code class="comments" style="-webkit-background-clip: initial !important; -webkit-background-origin: initial !important; background-attachment: initial !important; background-color: initial !important; background-image: none !important; background-position: initial initial !important; background-repeat: initial !important; border-bottom-width: 0px !important; border-color: initial !important; border-color: initial; border-left-width: 0px !important; border-right-width: 0px !important; border-style: initial !important; border-style: initial; border-top-width: 0px !important; bottom: auto !important; color: rgb(0, 130, 0) !important; float: none !important; font-family: Consolas, 'Bitstream Vera Sans Mono', 'Courier New', Courier, monospace !important; font-size: 12px !important; font-style: normal !important; font-weight: normal !important; font: normal normal normal 12px/1.4 Consolas, 'Andale Mono', Courier, 'Courier New', monospace; height: auto !important; left: auto !important; line-height: 1.1em !important; margin-bottom: 0px !important; margin-left: 0px !important; margin-right: 0px !important; margin-top: 0px !important; min-height: inherit !important; outline-color: initial !important; outline-style: initial !important; outline-width: 0px !important; padding-bottom: 0px !important; padding-left: 0px !important; padding-right: 0px !important; padding-top: 0px !important; position: static !important; right: auto !important; text-align: left !important; top: auto !important; vertical-align: baseline !important; width: auto !important;"&gt;// Set r to half of r + (n/r)&lt;/code&gt;&lt;/td&gt;&lt;/tr&gt;&lt;/tbody&gt;&lt;/table&gt;&lt;/div&gt;&lt;div class="line alt2" style="-webkit-background-clip: initial !important; -webkit-background-origin: initial !important; background-attachment: initial !important; background-color: rgb(248, 248, 248) !important; background-image: none !important; background-position: initial initial !important; background-repeat: initial !important; border-bottom-width: 0px !important; border-color: initial !important; border-color: initial; border-left-width: 0px !important; border-right-width: 0px !important; border-style: initial !important; border-style: initial; border-top-width: 0px !important; bottom: auto !important; float: none !important; font-family: Consolas, 'Bitstream Vera Sans Mono', 'Courier New', Courier, monospace !important; font-size: 12px !important; font-style: normal !important; font-weight: normal !important; height: auto !important; left: auto !important; line-height: 1.1em !important; margin-bottom: 0px !important; margin-left: 0px !important; margin-right: 0px !important; margin-top: 0px !important; min-height: inherit !important; outline-color: initial !important; outline-style: initial !important; outline-width: 0px !important; padding-bottom: 0px !important; padding-left: 0px !important; padding-right: 0px !important; padding-top: 0px !important; position: static !important; right: auto !important; text-align: left !important; top: auto !important; vertical-align: baseline !important; width: auto !important;"&gt;&lt;table style="-webkit-background-clip: initial !important; -webkit-background-origin: initial !important; -webkit-border-horizontal-spacing: 0px; -webkit-border-vertical-spacing: 0px; background-attachment: initial !important; background-color: initial !important; background-image: none !important; background-position: initial initial !important; background-repeat: initial !important; border-bottom-width: 0px !important; border-collapse: collapse !important; border-color: initial !important; border-color: initial; border-left-width: 0px !important; border-right-width: 0px !important; border-style: initial !important; border-style: initial; border-top-width: 0px !important; bottom: auto !important; float: none !important; font-family: Consolas, 'Bitstream Vera Sans Mono', 'Courier New', Courier, monospace !important; font-size: 12px !important; font-style: normal !important; font-weight: normal !important; height: auto !important; left: auto !important; line-height: 1.1em !important; margin-bottom: 0px !important; margin-left: 0px !important; margin-right: 0px !important; margin-top: 0px !important; min-height: inherit !important; outline-color: initial !important; outline-style: initial !important; outline-width: 0px !important; padding-bottom: 0px !important; padding-left: 0px !important; padding-right: 0px !important; padding-top: 0px !important; position: static !important; right: auto !important; text-align: left !important; top: auto !important; vertical-align: baseline !important; width: auto !important;"&gt;&lt;tbody style="-webkit-background-clip: initial !important; -webkit-background-origin: initial !important; background-attachment: initial !important; background-color: initial !important; background-image: none !important; background-position: initial initial !important; background-repeat: initial !important; border-bottom-width: 0px !important; border-color: initial !important; border-color: initial; border-left-width: 0px !important; border-right-width: 0px !important; border-style: initial !important; border-style: initial; border-top-width: 0px !important; bottom: auto !important; float: none !important; font-family: Consolas, 'Bitstream Vera Sans Mono', 'Courier New', Courier, monospace !important; font-size: 12px !important; font-style: normal !important; font-weight: normal !important; height: auto !important; left: auto !important; line-height: 1.1em !important; margin-bottom: 0px !important; margin-left: 0px !important; margin-right: 0px !important; margin-top: 0px !important; min-height: inherit !important; outline-color: initial !important; outline-style: initial !important; outline-width: 0px !important; padding-bottom: 0px !important; padding-left: 0px !important; padding-right: 0px !important; padding-top: 0px !important; position: static !important; right: auto !important; text-align: left !important; top: auto !important; vertical-align: baseline !important; width: auto !important;"&gt;&lt;tr style="-webkit-background-clip: initial !important; -webkit-background-origin: initial !important; background-attachment: initial !important; background-color: initial !important; background-image: none !important; background-position: initial initial !important; background-repeat: initial !important; border-bottom-width: 0px !important; border-color: initial !important; border-color: initial; border-left-width: 0px !important; border-right-width: 0px !important; border-style: initial !important; border-style: initial; border-top-width: 0px !important; bottom: auto !important; float: none !important; font-family: Consolas, 'Bitstream Vera Sans Mono', 'Courier New', Courier, monospace !important; font-size: 12px !important; font-style: normal !important; font-weight: normal !important; height: auto !important; left: auto !important; line-height: 1.1em !important; margin-bottom: 0px !important; margin-left: 0px !important; margin-right: 0px !important; margin-top: 0px !important; min-height: inherit !important; outline-color: initial !important; outline-style: initial !important; outline-width: 0px !important; padding-bottom: 0px !important; padding-left: 0px !important; padding-right: 0px !important; padding-top: 0px !important; position: static !important; right: auto !important; text-align: left !important; top: auto !important; vertical-align: baseline !important; width: auto !important;"&gt;&lt;td class="number" style="-webkit-background-clip: initial !important; -webkit-background-origin: initial !important; background-attachment: initial !important; background-color: initial !important; background-image: none !important; background-position: initial initial !important; background-repeat: initial !important; border-bottom-width: 0px !important; border-color: initial !important; border-color: initial; border-left-width: 0px !important; border-right-width: 0px !important; border-style: initial !important; border-style: initial; border-top-width: 0px !important; bottom: auto !important; color: rgb(175, 175, 175) !important; float: none !important; font-family: Consolas, 'Bitstream Vera Sans Mono', 'Courier New', Courier, monospace !important; font-size: 12px !important; font-style: normal !important; font-weight: normal !important; height: auto !important; left: auto !important; line-height: 1.1em !important; margin-bottom: 0px !important; margin-left: 0px !important; margin-right: 0px !important; margin-top: 0px !important; min-height: inherit !important; outline-color: initial !important; outline-style: initial !important; outline-width: 0px !important; padding-bottom: 0px !important; padding-left: 0px !important; padding-right: 0px !important; padding-top: 0px !important; position: static !important; right: auto !important; text-align: left !important; top: auto !important; vertical-align: top !important; width: 3em !important;"&gt;&lt;code style="-webkit-background-clip: initial !important; -webkit-background-origin: initial !important; background-attachment: initial !important; background-color: initial !important; background-image: none !important; background-position: initial initial !important; background-repeat: initial !important; border-bottom-width: 0px !important; border-color: initial !important; border-color: initial; border-left-width: 0px !important; border-right-width: 0px !important; border-style: initial !important; border-style: initial; border-top-width: 0px !important; bottom: auto !important; display: block !important; float: none !important; font-family: Consolas, 'Bitstream Vera Sans Mono', 'Courier New', Courier, monospace !important; font-size: 12px !important; font-style: normal !important; font-weight: normal !important; font: normal normal normal 12px/1.4 Consolas, 'Andale Mono', Courier, 'Courier New', monospace; height: auto !important; left: auto !important; line-height: 1.1em !important; margin-bottom: 0px !important; margin-left: 0px !important; margin-right: 0px !important; margin-top: 0px !important; min-height: inherit !important; outline-color: initial !important; outline-style: initial !important; outline-width: 0px !important; padding-bottom: 0px !important; padding-left: 0px !important; padding-right: 0.3em !important; padding-top: 0px !important; position: static !important; right: auto !important; text-align: right !important; top: auto !important; vertical-align: baseline !important; width: 2.7em !important;"&gt;6&lt;/code&gt;&lt;/td&gt;&lt;td class="content" style="-webkit-background-clip: initial !important; -webkit-background-origin: initial !important; background-attachment: initial !important; background-color: initial !important; background-image: none !important; background-position: initial initial !important; background-repeat: initial !important; border-bottom-width: 0px !important; border-color: initial !important; border-color: initial; border-left-color: rgb(108, 226, 108) !important; border-left-style: solid !important; border-left-width: 3px !important; border-right-width: 0px !important; border-style: initial !important; border-style: initial; border-top-width: 0px !important; bottom: auto !important; color: rgb(0, 0, 0) !important; float: none !important; font-family: Consolas, 'Bitstream Vera Sans Mono', 'Courier New', Courier, monospace !important; font-size: 12px !important; font-style: normal !important; font-weight: normal !important; height: auto !important; left: auto !important; line-height: 1.1em !important; margin-bottom: 0px !important; margin-left: 0px !important; margin-right: 0px !important; margin-top: 0px !important; min-height: inherit !important; outline-color: initial !important; outline-style: initial !important; outline-width: 0px !important; padding-bottom: 0px !important; padding-left: 0.5em !important; padding-right: 0px !important; padding-top: 0px !important; position: static !important; right: auto !important; text-align: left !important; top: auto !important; vertical-align: top !important; width: auto !important;"&gt;&lt;code class="plain" style="-webkit-background-clip: initial !important; -webkit-background-origin: initial !important; background-attachment: initial !important; background-color: initial !important; background-image: none !important; background-position: initial initial !important; background-repeat: initial !important; border-bottom-width: 0px !important; border-color: initial !important; border-color: initial; border-left-width: 0px !important; border-right-width: 0px !important; border-style: initial !important; border-style: initial; border-top-width: 0px !important; bottom: auto !important; color: rgb(0, 0, 0) !important; float: none !important; font-family: Consolas, 'Bitstream Vera Sans Mono', 'Courier New', Courier, monospace !important; font-size: 12px !important; font-style: normal !important; font-weight: normal !important; font: normal normal normal 12px/1.4 Consolas, 'Andale Mono', Courier, 'Courier New', monospace; height: auto !important; left: auto !important; line-height: 1.1em !important; margin-bottom: 0px !important; margin-left: 0px !important; margin-right: 0px !important; margin-top: 0px !important; min-height: inherit !important; outline-color: initial !important; outline-style: initial !important; outline-width: 0px !important; padding-bottom: 0px !important; padding-left: 0px !important; padding-right: 0px !important; padding-top: 0px !important; position: static !important; right: auto !important; text-align: left !important; top: auto !important; vertical-align: baseline !important; width: auto !important;"&gt;}&lt;/code&gt;&lt;/td&gt;&lt;/tr&gt;&lt;/tbody&gt;&lt;/table&gt;&lt;/div&gt;&lt;/div&gt;&lt;/div&gt;&lt;div style="border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; font-family: inherit; font-size: 16px; font-style: inherit; font-weight: inherit; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; vertical-align: baseline;"&gt;Do you have any idea what this code does? Me neither. The problem is that while there are plenty of comments describing&amp;nbsp;&lt;em style="border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; font-family: inherit; font-size: 16px; font-style: italic; font-weight: inherit; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; vertical-align: baseline;"&gt;what&amp;nbsp;&lt;/em&gt;the code is doing, there are none describing&amp;nbsp;&lt;em style="border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; font-family: inherit; font-size: 16px; font-style: italic; font-weight: inherit; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; vertical-align: baseline;"&gt;why&amp;nbsp;&lt;/em&gt;it’s doing it.&lt;/div&gt;&lt;div style="border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; font-family: inherit; font-size: 16px; font-style: inherit; font-weight: inherit; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; vertical-align: baseline;"&gt;Now, consider the same code with a different commenting methodology:&lt;/div&gt;&lt;div class="syntaxhighlighter  " id="highlighter_295838" style="-webkit-background-clip: initial !important; -webkit-background-origin: initial !important; background-attachment: initial !important; background-color: rgb(255, 255, 255) !important; background-image: none !important; background-position: initial initial !important; background-repeat: initial !important; border-bottom-width: 0px !important; border-color: initial !important; border-color: initial; border-left-width: 0px !important; border-right-width: 0px !important; border-style: initial !important; border-style: initial; border-top-width: 0px !important; bottom: auto !important; float: none !important; font-family: Consolas, 'Bitstream Vera Sans Mono', 'Courier New', Courier, monospace !important; font-size: 12px !important; font-style: normal !important; font-weight: normal !important; height: auto !important; left: auto !important; line-height: 1.1em !important; margin-bottom: 1em !important; margin-left: 0px !important; margin-right: 0px !important; margin-top: 1em !important; min-height: inherit !important; outline-color: initial !important; outline-style: initial !important; outline-width: 0px !important; padding-bottom: 1px !important; padding-left: 1px !important; padding-right: 1px !important; padding-top: 1px !important; position: relative !important; right: auto !important; text-align: left !important; top: auto !important; vertical-align: baseline !important; width: 643px;"&gt;&lt;div class="lines" style="-webkit-background-clip: initial !important; -webkit-background-origin: initial !important; background-attachment: initial !important; background-color: initial !important; background-image: none !important; background-position: initial initial !important; background-repeat: initial !important; border-bottom-width: 0px !important; border-color: initial !important; border-color: initial; border-left-width: 0px !important; border-right-width: 0px !important; border-style: initial !important; border-style: initial; border-top-width: 0px !important; bottom: auto !important; float: none !important; font-family: Consolas, 'Bitstream Vera Sans Mono', 'Courier New', Courier, monospace !important; font-size: 12px !important; font-style: normal !important; font-weight: normal !important; height: auto !important; left: auto !important; line-height: 1.1em !important; margin-bottom: 0px !important; margin-left: 0px !important; margin-right: 0px !important; margin-top: 0px !important; min-height: inherit !important; outline-color: initial !important; outline-style: initial !important; outline-width: 0px !important; padding-bottom: 0px !important; padding-left: 0px !important; padding-right: 0px !important; padding-top: 0px !important; position: static !important; right: auto !important; text-align: left !important; top: auto !important; vertical-align: baseline !important; width: auto !important;"&gt;&lt;div class="line alt1" style="-webkit-background-clip: initial !important; -webkit-background-origin: initial !important; background-attachment: initial !important; background-color: rgb(255, 255, 255) !important; background-image: none !important; background-position: initial initial !important; background-repeat: initial !important; border-bottom-width: 0px !important; border-color: initial !important; border-color: initial; border-left-width: 0px !important; border-right-width: 0px !important; border-style: initial !important; border-style: initial; border-top-width: 0px !important; bottom: auto !important; float: none !important; font-family: Consolas, 'Bitstream Vera Sans Mono', 'Courier New', Courier, monospace !important; font-size: 12px !important; font-style: normal !important; font-weight: normal !important; height: auto !important; left: auto !important; line-height: 1.1em !important; margin-bottom: 0px !important; margin-left: 0px !important; margin-right: 0px !important; margin-top: 0px !important; min-height: inherit !important; outline-color: initial !important; outline-style: initial !important; outline-width: 0px !important; padding-bottom: 0px !important; padding-left: 0px !important; padding-right: 0px !important; padding-top: 0px !important; position: static !important; right: auto !important; text-align: left !important; top: auto !important; vertical-align: baseline !important; width: auto !important;"&gt;&lt;table style="-webkit-background-clip: initial !important; -webkit-background-origin: initial !important; -webkit-border-horizontal-spacing: 0px; -webkit-border-vertical-spacing: 0px; background-attachment: initial !important; background-color: initial !important; background-image: none !important; background-position: initial initial !important; background-repeat: initial !important; border-bottom-width: 0px !important; border-collapse: collapse !important; border-color: initial !important; border-color: initial; border-left-width: 0px !important; border-right-width: 0px !important; border-style: initial !important; border-style: initial; border-top-width: 0px !important; bottom: auto !important; float: none !important; font-family: Consolas, 'Bitstream Vera Sans Mono', 'Courier New', Courier, monospace !important; font-size: 12px !important; font-style: normal !important; font-weight: normal !important; height: auto !important; left: auto !important; line-height: 1.1em !important; margin-bottom: 0px !important; margin-left: 0px !important; margin-right: 0px !important; margin-top: 0px !important; min-height: inherit !important; outline-color: initial !important; outline-style: initial !important; outline-width: 0px !important; padding-bottom: 0px !important; padding-left: 0px !important; padding-right: 0px !important; padding-top: 0px !important; position: static !important; right: auto !important; text-align: left !important; top: auto !important; vertical-align: baseline !important; width: auto !important;"&gt;&lt;tbody style="-webkit-background-clip: initial !important; -webkit-background-origin: initial !important; background-attachment: initial !important; background-color: initial !important; background-image: none !important; background-position: initial initial !important; background-repeat: initial !important; border-bottom-width: 0px !important; border-color: initial !important; border-color: initial; border-left-width: 0px !important; border-right-width: 0px !important; border-style: initial !important; border-style: initial; border-top-width: 0px !important; bottom: auto !important; float: none !important; font-family: Consolas, 'Bitstream Vera Sans Mono', 'Courier New', Courier, monospace !important; font-size: 12px !important; font-style: normal !important; font-weight: normal !important; height: auto !important; left: auto !important; line-height: 1.1em !important; margin-bottom: 0px !important; margin-left: 0px !important; margin-right: 0px !important; margin-top: 0px !important; min-height: inherit !important; outline-color: initial !important; outline-style: initial !important; outline-width: 0px !important; padding-bottom: 0px !important; padding-left: 0px !important; padding-right: 0px !important; padding-top: 0px !important; position: static !important; right: auto !important; text-align: left !important; top: auto !important; vertical-align: baseline !important; width: auto !important;"&gt;&lt;tr style="-webkit-background-clip: initial !important; -webkit-background-origin: initial !important; background-attachment: initial !important; background-color: initial !important; background-image: none !important; background-position: initial initial !important; background-repeat: initial !important; border-bottom-width: 0px !important; border-color: initial !important; border-color: initial; border-left-width: 0px !important; border-right-width: 0px !important; border-style: initial !important; border-style: initial; border-top-width: 0px !important; bottom: auto !important; float: none !important; font-family: Consolas, 'Bitstream Vera Sans Mono', 'Courier New', Courier, monospace !important; font-size: 12px !important; font-style: normal !important; font-weight: normal !important; height: auto !important; left: auto !important; line-height: 1.1em !important; margin-bottom: 0px !important; margin-left: 0px !important; margin-right: 0px !important; margin-top: 0px !important; min-height: inherit !important; outline-color: initial !important; outline-style: initial !important; outline-width: 0px !important; padding-bottom: 0px !important; padding-left: 0px !important; padding-right: 0px !important; padding-top: 0px !important; position: static !important; right: auto !important; text-align: left !important; top: auto !important; vertical-align: baseline !important; width: auto !important;"&gt;&lt;td class="number" style="-webkit-background-clip: initial !important; -webkit-background-origin: initial !important; background-attachment: initial !important; background-color: initial !important; background-image: none !important; background-position: initial initial !important; background-repeat: initial !important; border-bottom-width: 0px !important; border-color: initial !important; border-color: initial; border-left-width: 0px !important; border-right-width: 0px !important; border-style: initial !important; border-style: initial; border-top-width: 0px !important; bottom: auto !important; color: rgb(175, 175, 175) !important; float: none !important; font-family: Consolas, 'Bitstream Vera Sans Mono', 'Courier New', Courier, monospace !important; font-size: 12px !important; font-style: normal !important; font-weight: normal !important; height: auto !important; left: auto !important; line-height: 1.1em !important; margin-bottom: 0px !important; margin-left: 0px !important; margin-right: 0px !important; margin-top: 0px !important; min-height: inherit !important; outline-color: initial !important; outline-style: initial !important; outline-width: 0px !important; padding-bottom: 0px !important; padding-left: 0px !important; padding-right: 0px !important; padding-top: 0px !important; position: static !important; right: auto !important; text-align: left !important; top: auto !important; vertical-align: top !important; width: 3em !important;"&gt;&lt;code style="-webkit-background-clip: initial !important; -webkit-background-origin: initial !important; background-attachment: initial !important; background-color: initial !important; background-image: none !important; background-position: initial initial !important; background-repeat: initial !important; border-bottom-width: 0px !important; border-color: initial !important; border-color: initial; border-left-width: 0px !important; border-right-width: 0px !important; border-style: initial !important; border-style: initial; border-top-width: 0px !important; bottom: auto !important; display: block !important; float: none !important; font-family: Consolas, 'Bitstream Vera Sans Mono', 'Courier New', Courier, monospace !important; font-size: 12px !important; font-style: normal !important; font-weight: normal !important; font: normal normal normal 12px/1.4 Consolas, 'Andale Mono', Courier, 'Courier New', monospace; height: auto !important; left: auto !important; line-height: 1.1em !important; margin-bottom: 0px !important; margin-left: 0px !important; margin-right: 0px !important; margin-top: 0px !important; min-height: inherit !important; outline-color: initial !important; outline-style: initial !important; outline-width: 0px !important; padding-bottom: 0px !important; padding-left: 0px !important; padding-right: 0.3em !important; padding-top: 0px !important; position: static !important; right: auto !important; text-align: right !important; top: auto !important; vertical-align: baseline !important; width: 2.7em !important;"&gt;1&lt;/code&gt;&lt;/td&gt;&lt;td class="content" style="-webkit-background-clip: initial !important; -webkit-background-origin: initial !important; background-attachment: initial !important; background-color: initial !important; background-image: none !important; background-position: initial initial !important; background-repeat: initial !important; border-bottom-width: 0px !important; border-color: initial !important; border-color: initial; border-left-color: rgb(108, 226, 108) !important; border-left-style: solid !important; border-left-width: 3px !important; border-right-width: 0px !important; border-style: initial !important; border-style: initial; border-top-width: 0px !important; bottom: auto !important; color: rgb(0, 0, 0) !important; float: none !important; font-family: Consolas, 'Bitstream Vera Sans Mono', 'Courier New', Courier, monospace !important; font-size: 12px !important; font-style: normal !important; font-weight: normal !important; height: auto !important; left: auto !important; line-height: 1.1em !important; margin-bottom: 0px !important; margin-left: 0px !important; margin-right: 0px !important; margin-top: 0px !important; min-height: inherit !important; outline-color: initial !important; outline-style: initial !important; outline-width: 0px !important; padding-bottom: 0px !important; padding-left: 0.5em !important; padding-right: 0px !important; padding-top: 0px !important; position: static !important; right: auto !important; text-align: left !important; top: auto !important; vertical-align: top !important; width: auto !important;"&gt;&lt;code class="comments" style="-webkit-background-clip: initial !important; -webkit-background-origin: initial !important; background-attachment: initial !important; background-color: initial !important; background-image: none !important; background-position: initial initial !important; background-repeat: initial !important; border-bottom-width: 0px !important; border-color: initial !important; border-color: initial; border-left-width: 0px !important; border-right-width: 0px !important; border-style: initial !important; border-style: initial; border-top-width: 0px !important; bottom: auto !important; color: rgb(0, 130, 0) !important; float: none !important; font-family: Consolas, 'Bitstream Vera Sans Mono', 'Courier New', Courier, monospace !important; font-size: 12px !important; font-style: normal !important; font-weight: normal !important; font: normal normal normal 12px/1.4 Consolas, 'Andale Mono', Courier, 'Courier New', monospace; height: auto !important; left: auto !important; line-height: 1.1em !important; margin-bottom: 0px !important; margin-left: 0px !important; margin-right: 0px !important; margin-top: 0px !important; min-height: inherit !important; outline-color: initial !important; outline-style: initial !important; outline-width: 0px !important; padding-bottom: 0px !important; padding-left: 0px !important; padding-right: 0px !important; padding-top: 0px !important; position: static !important; right: auto !important; text-align: left !important; top: auto !important; vertical-align: baseline !important; width: auto !important;"&gt;// square root of n with Newton-Raphson approximation&lt;/code&gt;&lt;/td&gt;&lt;/tr&gt;&lt;/tbody&gt;&lt;/table&gt;&lt;/div&gt;&lt;div class="line alt2" style="-webkit-background-clip: initial !important; -webkit-background-origin: initial !important; background-attachment: initial !important; background-color: rgb(248, 248, 248) !important; background-image: none !important; background-position: initial initial !important; background-repeat: initial !important; border-bottom-width: 0px !important; border-color: initial !important; border-color: initial; border-left-width: 0px !important; border-right-width: 0px !important; border-style: initial !important; border-style: initial; border-top-width: 0px !important; bottom: auto !important; float: none !important; font-family: Consolas, 'Bitstream Vera Sans Mono', 'Courier New', Courier, monospace !important; font-size: 12px !important; font-style: normal !important; font-weight: normal !important; height: auto !important; left: auto !important; line-height: 1.1em !important; margin-bottom: 0px !important; margin-left: 0px !important; margin-right: 0px !important; margin-top: 0px !important; min-height: inherit !important; outline-color: initial !important; outline-style: initial !important; outline-width: 0px !important; padding-bottom: 0px !important; padding-left: 0px !important; padding-right: 0px !important; padding-top: 0px !important; position: static !important; right: auto !important; text-align: left !important; top: auto !important; vertical-align: baseline !important; width: auto !important;"&gt;&lt;table style="-webkit-background-clip: initial !important; -webkit-background-origin: initial !important; -webkit-border-horizontal-spacing: 0px; -webkit-border-vertical-spacing: 0px; background-attachment: initial !important; background-color: initial !important; background-image: none !important; background-position: initial initial !important; background-repeat: initial !important; border-bottom-width: 0px !important; border-collapse: collapse !important; border-color: initial !important; border-color: initial; border-left-width: 0px !important; border-right-width: 0px !important; border-style: initial !important; border-style: initial; border-top-width: 0px !important; bottom: auto !important; float: none !important; font-family: Consolas, 'Bitstream Vera Sans Mono', 'Courier New', Courier, monospace !important; font-size: 12px !important; font-style: normal !important; font-weight: normal !important; height: auto !important; left: auto !important; line-height: 1.1em !important; margin-bottom: 0px !important; margin-left: 0px !important; margin-right: 0px !important; margin-top: 0px !important; min-height: inherit !important; outline-color: initial !important; outline-style: initial !important; outline-width: 0px !important; padding-bottom: 0px !important; padding-left: 0px !important; padding-right: 0px !important; padding-top: 0px !important; position: static !important; right: auto !important; text-align: left !important; top: auto !important; vertical-align: baseline !important; width: auto !important;"&gt;&lt;tbody style="-webkit-background-clip: initial !important; -webkit-background-origin: initial !important; background-attachment: initial !important; background-color: initial !important; background-image: none !important; background-position: initial initial !important; background-repeat: initial !important; border-bottom-width: 0px !important; border-color: initial !important; border-color: initial; border-left-width: 0px !important; border-right-width: 0px !important; border-style: initial !important; border-style: initial; border-top-width: 0px !important; bottom: auto !important; float: none !important; font-family: Consolas, 'Bitstream Vera Sans Mono', 'Courier New', Courier, monospace !important; font-size: 12px !important; font-style: normal !important; font-weight: normal !important; height: auto !important; left: auto !important; line-height: 1.1em !important; margin-bottom: 0px !important; margin-left: 0px !important; margin-right: 0px !important; margin-top: 0px !important; min-height: inherit !important; outline-color: initial !important; outline-style: initial !important; outline-width: 0px !important; padding-bottom: 0px !important; padding-left: 0px !important; padding-right: 0px !important; padding-top: 0px !important; position: static !important; right: auto !important; text-align: left !important; top: auto !important; vertical-align: baseline !important; width: auto !important;"&gt;&lt;tr style="-webkit-background-clip: initial !important; -webkit-background-origin: initial !important; background-attachment: initial !important; background-color: initial !important; background-image: none !important; background-position: initial initial !important; background-repeat: initial !important; border-bottom-width: 0px !important; border-color: initial !important; border-color: initial; border-left-width: 0px !important; border-right-width: 0px !important; border-style: initial !important; border-style: initial; border-top-width: 0px !important; bottom: auto !important; float: none !important; font-family: Consolas, 'Bitstream Vera Sans Mono', 'Courier New', Courier, monospace !important; font-size: 12px !important; font-style: normal !important; font-weight: normal !important; height: auto !important; left: auto !important; line-height: 1.1em !important; margin-bottom: 0px !important; margin-left: 0px !important; margin-right: 0px !important; margin-top: 0px !important; min-height: inherit !important; outline-color: initial !important; outline-style: initial !important; outline-width: 0px !important; padding-bottom: 0px !important; padding-left: 0px !important; padding-right: 0px !important; padding-top: 0px !important; position: static !important; right: auto !important; text-align: left !important; top: auto !important; vertical-align: baseline !important; width: auto !important;"&gt;&lt;td class="number" style="-webkit-background-clip: initial !important; -webkit-background-origin: initial !important; background-attachment: initial !important; background-color: initial !important; background-image: none !important; background-position: initial initial !important; background-repeat: initial !important; border-bottom-width: 0px !important; border-color: initial !important; border-color: initial; border-left-width: 0px !important; border-right-width: 0px !important; border-style: initial !important; border-style: initial; border-top-width: 0px !important; bottom: auto !important; color: rgb(175, 175, 175) !important; float: none !important; font-family: Consolas, 'Bitstream Vera Sans Mono', 'Courier New', Courier, monospace !important; font-size: 12px !important; font-style: normal !important; font-weight: normal !important; height: auto !important; left: auto !important; line-height: 1.1em !important; margin-bottom: 0px !important; margin-left: 0px !important; margin-right: 0px !important; margin-top: 0px !important; min-height: inherit !important; outline-color: initial !important; outline-style: initial !important; outline-width: 0px !important; padding-bottom: 0px !important; padding-left: 0px !important; padding-right: 0px !important; padding-top: 0px !important; position: static !important; right: auto !important; text-align: left !important; top: auto !important; vertical-align: top !important; width: 3em !important;"&gt;&lt;code style="-webkit-background-clip: initial !important; -webkit-background-origin: initial !important; background-attachment: initial !important; background-color: initial !important; background-image: none !important; background-position: initial initial !important; background-repeat: initial !important; border-bottom-width: 0px !important; border-color: initial !important; border-color: initial; border-left-width: 0px !important; border-right-width: 0px !important; border-style: initial !important; border-style: initial; border-top-width: 0px !important; bottom: auto !important; display: block !important; float: none !important; font-family: Consolas, 'Bitstream Vera Sans Mono', 'Courier New', Courier, monospace !important; font-size: 12px !important; font-style: normal !important; font-weight: normal !important; font: normal normal normal 12px/1.4 Consolas, 'Andale Mono', Courier, 'Courier New', monospace; height: auto !important; left: auto !important; line-height: 1.1em !important; margin-bottom: 0px !important; margin-left: 0px !important; margin-right: 0px !important; margin-top: 0px !important; min-height: inherit !important; outline-color: initial !important; outline-style: initial !important; outline-width: 0px !important; padding-bottom: 0px !important; padding-left: 0px !important; padding-right: 0.3em !important; padding-top: 0px !important; position: static !important; right: auto !important; text-align: right !important; top: auto !important; vertical-align: baseline !important; width: 2.7em !important;"&gt;2&lt;/code&gt;&lt;/td&gt;&lt;td class="content" style="-webkit-background-clip: initial !important; -webkit-background-origin: initial !important; background-attachment: initial !important; background-color: initial !important; background-image: none !important; background-position: initial initial !important; background-repeat: initial !important; border-bottom-width: 0px !important; border-color: initial !important; border-color: initial; border-left-color: rgb(108, 226, 108) !important; border-left-style: solid !important; border-left-width: 3px !important; border-right-width: 0px !important; border-style: initial !important; border-style: initial; border-top-width: 0px !important; bottom: auto !important; color: rgb(0, 0, 0) !important; float: none !important; font-family: Consolas, 'Bitstream Vera Sans Mono', 'Courier New', Courier, monospace !important; font-size: 12px !important; font-style: normal !important; font-weight: normal !important; height: auto !important; left: auto !important; line-height: 1.1em !important; margin-bottom: 0px !important; margin-left: 0px !important; margin-right: 0px !important; margin-top: 0px !important; min-height: inherit !important; outline-color: initial !important; outline-style: initial !important; outline-width: 0px !important; padding-bottom: 0px !important; padding-left: 0.5em !important; padding-right: 0px !important; padding-top: 0px !important; position: static !important; right: auto !important; text-align: left !important; top: auto !important; vertical-align: top !important; width: auto !important;"&gt;&lt;code class="plain" style="-webkit-background-clip: initial !important; -webkit-background-origin: initial !important; background-attachment: initial !important; background-color: initial !important; background-image: none !important; background-position: initial initial !important; background-repeat: initial !important; border-bottom-width: 0px !important; border-color: initial !important; border-color: initial; border-left-width: 0px !important; border-right-width: 0px !important; border-style: initial !important; border-style: initial; border-top-width: 0px !important; bottom: auto !important; color: rgb(0, 0, 0) !important; float: none !important; font-family: Consolas, 'Bitstream Vera Sans Mono', 'Courier New', Courier, monospace !important; font-size: 12px !important; font-style: normal !important; font-weight: normal !important; font: normal normal normal 12px/1.4 Consolas, 'Andale Mono', Courier, 'Courier New', monospace; height: auto !important; left: auto !important; line-height: 1.1em !important; margin-bottom: 0px !important; margin-left: 0px !important; margin-right: 0px !important; margin-top: 0px !important; min-height: inherit !important; outline-color: initial !important; outline-style: initial !important; outline-width: 0px !important; padding-bottom: 0px !important; padding-left: 0px !important; padding-right: 0px !important; padding-top: 0px !important; position: static !important; right: auto !important; text-align: left !important; top: auto !important; vertical-align: baseline !important; width: auto !important;"&gt;r = n / 2;&lt;/code&gt;&lt;/td&gt;&lt;/tr&gt;&lt;/tbody&gt;&lt;/table&gt;&lt;/div&gt;&lt;div class="line alt1" style="-webkit-background-clip: initial !important; -webkit-background-origin: initial !important; background-attachment: initial !important; background-color: rgb(255, 255, 255) !important; background-image: none !important; background-position: initial initial !important; background-repeat: initial !important; border-bottom-width: 0px !important; border-color: initial !important; border-color: initial; border-left-width: 0px !important; border-right-width: 0px !important; border-style: initial !important; border-style: initial; border-top-width: 0px !important; bottom: auto !important; float: none !important; font-family: Consolas, 'Bitstream Vera Sans Mono', 'Courier New', Courier, monospace !important; font-size: 12px !important; font-style: normal !important; font-weight: normal !important; height: auto !important; left: auto !important; line-height: 1.1em !important; margin-bottom: 0px !important; margin-left: 0px !important; margin-right: 0px !important; margin-top: 0px !important; min-height: inherit !important; outline-color: initial !important; outline-style: initial !important; outline-width: 0px !important; padding-bottom: 0px !important; padding-left: 0px !important; padding-right: 0px !important; padding-top: 0px !important; position: static !important; right: auto !important; text-align: left !important; top: auto !important; vertical-align: baseline !important; width: auto !important;"&gt;&lt;table style="-webkit-background-clip: initial !important; -webkit-background-origin: initial !important; -webkit-border-horizontal-spacing: 0px; -webkit-border-vertical-spacing: 0px; background-attachment: initial !important; background-color: initial !important; background-image: none !important; background-position: initial initial !important; background-repeat: initial !important; border-bottom-width: 0px !important; border-collapse: collapse !important; border-color: initial !important; border-color: initial; border-left-width: 0px !important; border-right-width: 0px !important; border-style: initial !important; border-style: initial; border-top-width: 0px !important; bottom: auto !important; float: none !important; font-family: Consolas, 'Bitstream Vera Sans Mono', 'Courier New', Courier, monospace !important; font-size: 12px !important; font-style: normal !important; font-weight: normal !important; height: auto !important; left: auto !important; line-height: 1.1em !important; margin-bottom: 0px !important; margin-left: 0px !important; margin-right: 0px !important; margin-top: 0px !important; min-height: inherit !important; outline-color: initial !important; outline-style: initial !important; outline-width: 0px !important; padding-bottom: 0px !important; padding-left: 0px !important; padding-right: 0px !important; padding-top: 0px !important; position: static !important; right: auto !important; text-align: left !important; top: auto !important; vertical-align: baseline !important; width: auto !important;"&gt;&lt;tbody style="-webkit-background-clip: initial !important; -webkit-background-origin: initial !important; background-attachment: initial !important; background-color: initial !important; background-image: none !important; background-position: initial initial !important; background-repeat: initial !important; border-bottom-width: 0px !important; border-color: initial !important; border-color: initial; border-left-width: 0px !important; border-right-width: 0px !important; border-style: initial !important; border-style: initial; border-top-width: 0px !important; bottom: auto !important; float: none !important; font-family: Consolas, 'Bitstream Vera Sans Mono', 'Courier New', Courier, monospace !important; font-size: 12px !important; font-style: normal !important; font-weight: normal !important; height: auto !important; left: auto !important; line-height: 1.1em !important; margin-bottom: 0px !important; margin-left: 0px !important; margin-right: 0px !important; margin-top: 0px !important; min-height: inherit !important; outline-color: initial !important; outline-style: initial !important; outline-width: 0px !important; padding-bottom: 0px !important; padding-left: 0px !important; padding-right: 0px !important; padding-top: 0px !important; position: static !important; right: auto !important; text-align: left !important; top: auto !important; vertical-align: baseline !important; width: auto !important;"&gt;&lt;tr style="-webkit-background-clip: initial !important; -webkit-background-origin: initial !important; background-attachment: initial !important; background-color: initial !important; background-image: none !important; background-position: initial initial !important; background-repeat: initial !important; border-bottom-width: 0px !important; border-color: initial !important; border-color: initial; border-left-width: 0px !important; border-right-width: 0px !important; border-style: initial !important; border-style: initial; border-top-width: 0px !important; bottom: auto !important; float: none !important; font-family: Consolas, 'Bitstream Vera Sans Mono', 'Courier New', Courier, monospace !important; font-size: 12px !important; font-style: normal !important; font-weight: normal !important; height: auto !important; left: auto !important; line-height: 1.1em !important; margin-bottom: 0px !important; margin-left: 0px !important; margin-right: 0px !important; margin-top: 0px !important; min-height: inherit !important; outline-color: initial !important; outline-style: initial !important; outline-width: 0px !important; padding-bottom: 0px !important; padding-left: 0px !important; padding-right: 0px !important; padding-top: 0px !important; position: static !important; right: auto !important; text-align: left !important; top: auto !important; vertical-align: baseline !important; width: auto !important;"&gt;&lt;td class="number" style="-webkit-background-clip: initial !important; -webkit-background-origin: initial !important; background-attachment: initial !important; background-color: initial !important; background-image: none !important; background-position: initial initial !important; background-repeat: initial !important; border-bottom-width: 0px !important; border-color: initial !important; border-color: initial; border-left-width: 0px !important; border-right-width: 0px !important; border-style: initial !important; border-style: initial; border-top-width: 0px !important; bottom: auto !important; color: rgb(175, 175, 175) !important; float: none !important; font-family: Consolas, 'Bitstream Vera Sans Mono', 'Courier New', Courier, monospace !important; font-size: 12px !important; font-style: normal !important; font-weight: normal !important; height: auto !important; left: auto !important; line-height: 1.1em !important; margin-bottom: 0px !important; margin-left: 0px !important; margin-right: 0px !important; margin-top: 0px !important; min-height: inherit !important; outline-color: initial !important; outline-style: initial !important; outline-width: 0px !important; padding-bottom: 0px !important; padding-left: 0px !important; padding-right: 0px !important; padding-top: 0px !important; position: static !important; right: auto !important; text-align: left !important; top: auto !important; vertical-align: top !important; width: 3em !important;"&gt;&lt;code style="-webkit-background-clip: initial !important; -webkit-background-origin: initial !important; background-attachment: initial !important; background-color: initial !important; background-image: none !important; background-position: initial initial !important; background-repeat: initial !important; border-bottom-width: 0px !important; border-color: initial !important; border-color: initial; border-left-width: 0px !important; border-right-width: 0px !important; border-style: initial !important; border-style: initial; border-top-width: 0px !important; bottom: auto !important; display: block !important; float: none !important; font-family: Consolas, 'Bitstream Vera Sans Mono', 'Courier New', Courier, monospace !important; font-size: 12px !important; font-style: normal !important; font-weight: normal !important; font: normal normal normal 12px/1.4 Consolas, 'Andale Mono', Courier, 'Courier New', monospace; height: auto !important; left: auto !important; line-height: 1.1em !important; margin-bottom: 0px !important; margin-left: 0px !important; margin-right: 0px !important; margin-top: 0px !important; min-height: inherit !important; outline-color: initial !important; outline-style: initial !important; outline-width: 0px !important; padding-bottom: 0px !important; padding-left: 0px !important; padding-right: 0.3em !important; padding-top: 0px !important; position: static !important; right: auto !important; text-align: right !important; top: auto !important; vertical-align: baseline !important; width: 2.7em !important;"&gt;3&lt;/code&gt;&lt;/td&gt;&lt;td class="content" style="-webkit-background-clip: initial !important; -webkit-background-origin: initial !important; background-attachment: initial !important; background-color: initial !important; background-image: none !important; background-position: initial initial !important; background-repeat: initial !important; border-bottom-width: 0px !important; border-color: initial !important; border-color: initial; border-left-color: rgb(108, 226, 108) !important; border-left-style: solid !important; border-left-width: 3px !important; border-right-width: 0px !important; border-style: initial !important; border-style: initial; border-top-width: 0px !important; bottom: auto !important; color: rgb(0, 0, 0) !important; float: none !important; font-family: Consolas, 'Bitstream Vera Sans Mono', 'Courier New', Courier, monospace !important; font-size: 12px !important; font-style: normal !important; font-weight: normal !important; height: auto !important; left: auto !important; line-height: 1.1em !important; margin-bottom: 0px !important; margin-left: 0px !important; margin-right: 0px !important; margin-top: 0px !important; min-height: inherit !important; outline-color: initial !important; outline-style: initial !important; outline-width: 0px !important; padding-bottom: 0px !important; padding-left: 0.5em !important; padding-right: 0px !important; padding-top: 0px !important; position: static !important; right: auto !important; text-align: left !important; top: auto !important; vertical-align: top !important; width: auto !important;"&gt;&lt;/td&gt;&lt;/tr&gt;&lt;/tbody&gt;&lt;/table&gt;&lt;/div&gt;&lt;div class="line alt2" style="-webkit-background-clip: initial !important; -webkit-background-origin: initial !important; background-attachment: initial !important; background-color: rgb(248, 248, 248) !important; background-image: none !important; background-position: initial initial !important; background-repeat: initial !important; border-bottom-width: 0px !important; border-color: initial !important; border-color: initial; border-left-width: 0px !important; border-right-width: 0px !important; border-style: initial !important; border-style: initial; border-top-width: 0px !important; bottom: auto !important; float: none !important; font-family: Consolas, 'Bitstream Vera Sans Mono', 'Courier New', Courier, monospace !important; font-size: 12px !important; font-style: normal !important; font-weight: normal !important; height: auto !important; left: auto !important; line-height: 1.1em !important; margin-bottom: 0px !important; margin-left: 0px !important; margin-right: 0px !important; margin-top: 0px !important; min-height: inherit !important; outline-color: initial !important; outline-style: initial !important; outline-width: 0px !important; padding-bottom: 0px !important; padding-left: 0px !important; padding-right: 0px !important; padding-top: 0px !important; position: static !important; right: auto !important; text-align: left !important; top: auto !important; vertical-align: baseline !important; width: auto !important;"&gt;&lt;table style="-webkit-background-clip: initial !important; -webkit-background-origin: initial !important; -webkit-border-horizontal-spacing: 0px; -webkit-border-vertical-spacing: 0px; background-attachment: initial !important; background-color: initial !important; background-image: none !important; background-position: initial initial !important; background-repeat: initial !important; border-bottom-width: 0px !important; border-collapse: collapse !important; border-color: initial !important; border-color: initial; border-left-width: 0px !important; border-right-width: 0px !important; border-style: initial !important; border-style: initial; border-top-width: 0px !important; bottom: auto !important; float: none !important; font-family: Consolas, 'Bitstream Vera Sans Mono', 'Courier New', Courier, monospace !important; font-size: 12px !important; font-style: normal !important; font-weight: normal !important; height: auto !important; left: auto !important; line-height: 1.1em !important; margin-bottom: 0px !important; margin-left: 0px !important; margin-right: 0px !important; margin-top: 0px !important; min-height: inherit !important; outline-color: initial !important; outline-style: initial !important; outline-width: 0px !important; padding-bottom: 0px !important; padding-left: 0px !important; padding-right: 0px !important; padding-top: 0px !important; position: static !important; right: auto !important; text-align: left !important; top: auto !important; vertical-align: baseline !important; width: auto !important;"&gt;&lt;tbody style="-webkit-background-clip: initial !important; -webkit-background-origin: initial !important; background-attachment: initial !important; background-color: initial !important; background-image: none !important; background-position: initial initial !important; background-repeat: initial !important; border-bottom-width: 0px !important; border-color: initial !important; border-color: initial; border-left-width: 0px !important; border-right-width: 0px !important; border-style: initial !important; border-style: initial; border-top-width: 0px !important; bottom: auto !important; float: none !important; font-family: Consolas, 'Bitstream Vera Sans Mono', 'Courier New', Courier, monospace !important; font-size: 12px !important; font-style: normal !important; font-weight: normal !important; height: auto !important; left: auto !important; line-height: 1.1em !important; margin-bottom: 0px !important; margin-left: 0px !important; margin-right: 0px !important; margin-top: 0px !important; min-height: inherit !important; outline-color: initial !important; outline-style: initial !important; outline-width: 0px !important; padding-bottom: 0px !important; padding-left: 0px !important; padding-right: 0px !important; padding-top: 0px !important; position: static !important; right: auto !important; text-align: left !important; top: auto !important; vertical-align: baseline !important; width: auto !important;"&gt;&lt;tr style="-webkit-background-clip: initial !important; -webkit-background-origin: initial !important; background-attachment: initial !important; background-color: initial !important; background-image: none !important; background-position: initial initial !important; background-repeat: initial !important; border-bottom-width: 0px !important; border-color: initial !important; border-color: initial; border-left-width: 0px !important; border-right-width: 0px !important; border-style: initial !important; border-style: initial; border-top-width: 0px !important; bottom: auto !important; float: none !important; font-family: Consolas, 'Bitstream Vera Sans Mono', 'Courier New', Courier, monospace !important; font-size: 12px !important; font-style: normal !important; font-weight: normal !important; height: auto !important; left: auto !important; line-height: 1.1em !important; margin-bottom: 0px !important; margin-left: 0px !important; margin-right: 0px !important; margin-top: 0px !important; min-height: inherit !important; outline-color: initial !important; outline-style: initial !important; outline-width: 0px !important; padding-bottom: 0px !important; padding-left: 0px !important; padding-right: 0px !important; padding-top: 0px !important; position: static !important; right: auto !important; text-align: left !important; top: auto !important; vertical-align: baseline !important; width: auto !important;"&gt;&lt;td class="number" style="-webkit-background-clip: initial !important; -webkit-background-origin: initial !important; background-attachment: initial !important; background-color: initial !important; background-image: none !important; background-position: initial initial !important; background-repeat: initial !important; border-bottom-width: 0px !important; border-color: initial !important; border-color: initial; border-left-width: 0px !important; border-right-width: 0px !important; border-style: initial !important; border-style: initial; border-top-width: 0px !important; bottom: auto !important; color: rgb(175, 175, 175) !important; float: none !important; font-family: Consolas, 'Bitstream Vera Sans Mono', 'Courier New', Courier, monospace !important; font-size: 12px !important; font-style: normal !important; font-weight: normal !important; height: auto !important; left: auto !important; line-height: 1.1em !important; margin-bottom: 0px !important; margin-left: 0px !important; margin-right: 0px !important; margin-top: 0px !important; min-height: inherit !important; outline-color: initial !important; outline-style: initial !important; outline-width: 0px !important; padding-bottom: 0px !important; padding-left: 0px !important; padding-right: 0px !important; padding-top: 0px !important; position: static !important; right: auto !important; text-align: left !important; top: auto !important; vertical-align: top !important; width: 3em !important;"&gt;&lt;code style="-webkit-background-clip: initial !important; -webkit-background-origin: initial !important; background-attachment: initial !important; background-color: initial !important; background-image: none !important; background-position: initial initial !important; background-repeat: initial !important; border-bottom-width: 0px !important; border-color: initial !important; border-color: initial; border-left-width: 0px !important; border-right-width: 0px !important; border-style: initial !important; border-style: initial; border-top-width: 0px !important; bottom: auto !important; display: block !important; float: none !important; font-family: Consolas, 'Bitstream Vera Sans Mono', 'Courier New', Courier, monospace !important; font-size: 12px !important; font-style: normal !important; font-weight: normal !important; font: normal normal normal 12px/1.4 Consolas, 'Andale Mono', Courier, 'Courier New', monospace; height: auto !important; left: auto !important; line-height: 1.1em !important; margin-bottom: 0px !important; margin-left: 0px !important; margin-right: 0px !important; margin-top: 0px !important; min-height: inherit !important; outline-color: initial !important; outline-style: initial !important; outline-width: 0px !important; padding-bottom: 0px !important; padding-left: 0px !important; padding-right: 0.3em !important; padding-top: 0px !important; position: static !important; right: auto !important; text-align: right !important; top: auto !important; vertical-align: baseline !important; width: 2.7em !important;"&gt;4&lt;/code&gt;&lt;/td&gt;&lt;td class="content" style="-webkit-background-clip: initial !important; -webkit-background-origin: initial !important; background-attachment: initial !important; background-color: initial !important; background-image: none !important; background-position: initial initial !important; background-repeat: initial !important; border-bottom-width: 0px !important; border-color: initial !important; border-color: initial; border-left-color: rgb(108, 226, 108) !important; border-left-style: solid !important; border-left-width: 3px !important; border-right-width: 0px !important; border-style: initial !important; border-style: initial; border-top-width: 0px !important; bottom: auto !important; color: rgb(0, 0, 0) !important; float: none !important; font-family: Consolas, 'Bitstream Vera Sans Mono', 'Courier New', Courier, monospace !important; font-size: 12px !important; font-style: normal !important; font-weight: normal !important; height: auto !important; left: auto !important; line-height: 1.1em !important; margin-bottom: 0px !important; margin-left: 0px !important; margin-right: 0px !important; margin-top: 0px !important; min-height: inherit !important; outline-color: initial !important; outline-style: initial !important; outline-width: 0px !important; padding-bottom: 0px !important; padding-left: 0.5em !important; padding-right: 0px !important; padding-top: 0px !important; position: static !important; right: auto !important; text-align: left !important; top: auto !important; vertical-align: top !important; width: auto !important;"&gt;&lt;code class="keyword" style="-webkit-background-clip: initial !important; -webkit-background-origin: initial !important; background-attachment: initial !important; background-color: initial !important; background-image: none !important; background-position: initial initial !important; background-repeat: initial !important; border-bottom-width: 0px !important; border-color: initial !important; border-color: initial; border-left-width: 0px !important; border-right-width: 0px !important; border-style: initial !important; border-style: initial; border-top-width: 0px !important; bottom: auto !important; color: rgb(0, 102, 153) !important; float: none !important; font-family: Consolas, 'Bitstream Vera Sans Mono', 'Courier New', Courier, monospace !important; font-size: 12px !important; font-style: normal !important; font-weight: bold !important; font: normal normal normal 12px/1.4 Consolas, 'Andale Mono', Courier, 'Courier New', monospace; height: auto !important; left: auto !important; line-height: 1.1em !important; margin-bottom: 0px !important; margin-left: 0px !important; margin-right: 0px !important; margin-top: 0px !important; min-height: inherit !important; outline-color: initial !important; outline-style: initial !important; outline-width: 0px !important; padding-bottom: 0px !important; padding-left: 0px !important; padding-right: 0px !important; padding-top: 0px !important; position: static !important; right: auto !important; text-align: left !important; top: auto !important; vertical-align: baseline !important; width: auto !important;"&gt;while&lt;/code&gt;&amp;nbsp;&lt;code class="plain" style="-webkit-background-clip: initial !important; -webkit-background-origin: initial !important; background-attachment: initial !important; background-color: initial !important; background-image: none !important; background-position: initial initial !important; background-repeat: initial !important; border-bottom-width: 0px !important; border-color: initial !important; border-color: initial; border-left-width: 0px !important; border-right-width: 0px !important; border-style: initial !important; border-style: initial; border-top-width: 0px !important; bottom: auto !important; color: rgb(0, 0, 0) !important; float: none !important; font-family: Consolas, 'Bitstream Vera Sans Mono', 'Courier New', Courier, monospace !important; font-size: 12px !important; font-style: normal !important; font-weight: normal !important; font: normal normal normal 12px/1.4 Consolas, 'Andale Mono', Courier, 'Courier New', monospace; height: auto !important; left: auto !important; line-height: 1.1em !important; margin-bottom: 0px !important; margin-left: 0px !important; margin-right: 0px !important; margin-top: 0px !important; min-height: inherit !important; outline-color: initial !important; outline-style: initial !important; outline-width: 0px !important; padding-bottom: 0px !important; padding-left: 0px !important; padding-right: 0px !important; padding-top: 0px !important; position: static !important; right: auto !important; text-align: left !important; top: auto !important; vertical-align: baseline !important; width: auto !important;"&gt;( abs( r - (n/r) ) &amp;gt; t ) {&lt;/code&gt;&lt;/td&gt;&lt;/tr&gt;&lt;/tbody&gt;&lt;/table&gt;&lt;/div&gt;&lt;div class="line alt1" style="-webkit-background-clip: initial !important; -webkit-background-origin: initial !important; background-attachment: initial !important; background-color: rgb(255, 255, 255) !important; background-image: none !important; background-position: initial initial !important; background-repeat: initial !important; border-bottom-width: 0px !important; border-color: initial !important; border-color: initial; border-left-width: 0px !important; border-right-width: 0px !important; border-style: initial !important; border-style: initial; border-top-width: 0px !important; bottom: auto !important; float: none !important; font-family: Consolas, 'Bitstream Vera Sans Mono', 'Courier New', Courier, monospace !important; font-size: 12px !important; font-style: normal !important; font-weight: normal !important; height: auto !important; left: auto !important; line-height: 1.1em !important; margin-bottom: 0px !important; margin-left: 0px !important; margin-right: 0px !important; margin-top: 0px !important; min-height: inherit !important; outline-color: initial !important; outline-style: initial !important; outline-width: 0px !important; padding-bottom: 0px !important; padding-left: 0px !important; padding-right: 0px !important; padding-top: 0px !important; position: static !important; right: auto !important; text-align: left !important; top: auto !important; vertical-align: baseline !important; width: auto !important;"&gt;&lt;table style="-webkit-background-clip: initial !important; -webkit-background-origin: initial !important; -webkit-border-horizontal-spacing: 0px; -webkit-border-vertical-spacing: 0px; background-attachment: initial !important; background-color: initial !important; background-image: none !important; background-position: initial initial !important; background-repeat: initial !important; border-bottom-width: 0px !important; border-collapse: collapse !important; border-color: initial !important; border-color: initial; border-left-width: 0px !important; border-right-width: 0px !important; border-style: initial !important; border-style: initial; border-top-width: 0px !important; bottom: auto !important; float: none !important; font-family: Consolas, 'Bitstream Vera Sans Mono', 'Courier New', Courier, monospace !important; font-size: 12px !important; font-style: normal !important; font-weight: normal !important; height: auto !important; left: auto !important; line-height: 1.1em !important; margin-bottom: 0px !important; margin-left: 0px !important; margin-right: 0px !important; margin-top: 0px !important; min-height: inherit !important; outline-color: initial !important; outline-style: initial !important; outline-width: 0px !important; padding-bottom: 0px !important; padding-left: 0px !important; padding-right: 0px !important; padding-top: 0px !important; position: static !important; right: auto !important; text-align: left !important; top: auto !important; vertical-align: baseline !important; width: auto !important;"&gt;&lt;tbody style="-webkit-background-clip: initial !important; -webkit-background-origin: initial !important; background-attachment: initial !important; background-color: initial !important; background-image: none !important; background-position: initial initial !important; background-repeat: initial !important; border-bottom-width: 0px !important; border-color: initial !important; border-color: initial; border-left-width: 0px !important; border-right-width: 0px !important; border-style: initial !important; border-style: initial; border-top-width: 0px !important; bottom: auto !important; float: none !important; font-family: Consolas, 'Bitstream Vera Sans Mono', 'Courier New', Courier, monospace !important; font-size: 12px !important; font-style: normal !important; font-weight: normal !important; height: auto !important; left: auto !important; line-height: 1.1em !important; margin-bottom: 0px !important; margin-left: 0px !important; margin-right: 0px !important; margin-top: 0px !important; min-height: inherit !important; outline-color: initial !important; outline-style: initial !important; outline-width: 0px !important; padding-bottom: 0px !important; padding-left: 0px !important; padding-right: 0px !important; padding-top: 0px !important; position: static !important; right: auto !important; text-align: left !important; top: auto !important; vertical-align: baseline !important; width: auto !important;"&gt;&lt;tr style="-webkit-background-clip: initial !important; -webkit-background-origin: initial !important; background-attachment: initial !important; background-color: initial !important; background-image: none !important; background-position: initial initial !important; background-repeat: initial !important; border-bottom-width: 0px !important; border-color: initial !important; border-color: initial; border-left-width: 0px !important; border-right-width: 0px !important; border-style: initial !important; border-style: initial; border-top-width: 0px !important; bottom: auto !important; float: none !important; font-family: Consolas, 'Bitstream Vera Sans Mono', 'Courier New', Courier, monospace !important; font-size: 12px !important; font-style: normal !important; font-weight: normal !important; height: auto !important; left: auto !important; line-height: 1.1em !important; margin-bottom: 0px !important; margin-left: 0px !important; margin-right: 0px !important; margin-top: 0px !important; min-height: inherit !important; outline-color: initial !important; outline-style: initial !important; outline-width: 0px !important; padding-bottom: 0px !important; padding-left: 0px !important; padding-right: 0px !important; padding-top: 0px !important; position: static !important; right: auto !important; text-align: left !important; top: auto !important; vertical-align: baseline !important; width: auto !important;"&gt;&lt;td class="number" style="-webkit-background-clip: initial !important; -webkit-background-origin: initial !important; background-attachment: initial !important; background-color: initial !important; background-image: none !important; background-position: initial initial !important; background-repeat: initial !important; border-bottom-width: 0px !important; border-color: initial !important; border-color: initial; border-left-width: 0px !important; border-right-width: 0px !important; border-style: initial !important; border-style: initial; border-top-width: 0px !important; bottom: auto !important; color: rgb(175, 175, 175) !important; float: none !important; font-family: Consolas, 'Bitstream Vera Sans Mono', 'Courier New', Courier, monospace !important; font-size: 12px !important; font-style: normal !important; font-weight: normal !important; height: auto !important; left: auto !important; line-height: 1.1em !important; margin-bottom: 0px !important; margin-left: 0px !important; margin-right: 0px !important; margin-top: 0px !important; min-height: inherit !important; outline-color: initial !important; outline-style: initial !important; outline-width: 0px !important; padding-bottom: 0px !important; padding-left: 0px !important; padding-right: 0px !important; padding-top: 0px !important; position: static !important; right: auto !important; text-align: left !important; top: auto !important; vertical-align: top !important; width: 3em !important;"&gt;&lt;code style="-webkit-background-clip: initial !important; -webkit-background-origin: initial !important; background-attachment: initial !important; background-color: initial !important; background-image: none !important; background-position: initial initial !important; background-repeat: initial !important; border-bottom-width: 0px !important; border-color: initial !important; border-color: initial; border-left-width: 0px !important; border-right-width: 0px !important; border-style: initial !important; border-style: initial; border-top-width: 0px !important; bottom: auto !important; display: block !important; float: none !important; font-family: Consolas, 'Bitstream Vera Sans Mono', 'Courier New', Courier, monospace !important; font-size: 12px !important; font-style: normal !important; font-weight: normal !important; font: normal normal normal 12px/1.4 Consolas, 'Andale Mono', Courier, 'Courier New', monospace; height: auto !important; left: auto !important; line-height: 1.1em !important; margin-bottom: 0px !important; margin-left: 0px !important; margin-right: 0px !important; margin-top: 0px !important; min-height: inherit !important; outline-color: initial !important; outline-style: initial !important; outline-width: 0px !important; padding-bottom: 0px !important; padding-left: 0px !important; padding-right: 0.3em !important; padding-top: 0px !important; position: static !important; right: auto !important; text-align: right !important; top: auto !important; vertical-align: baseline !important; width: 2.7em !important;"&gt;5&lt;/code&gt;&lt;/td&gt;&lt;td class="content" style="-webkit-background-clip: initial !important; -webkit-background-origin: initial !important; background-attachment: initial !important; background-color: initial !important; background-image: none !important; background-position: initial initial !important; background-repeat: initial !important; border-bottom-width: 0px !important; border-color: initial !important; border-color: initial; border-left-color: rgb(108, 226, 108) !important; border-left-style: solid !important; border-left-width: 3px !important; border-right-width: 0px !important; border-style: initial !important; border-style: initial; border-top-width: 0px !important; bottom: auto !important; color: rgb(0, 0, 0) !important; float: none !important; font-family: Consolas, 'Bitstream Vera Sans Mono', 'Courier New', Courier, monospace !important; font-size: 12px !important; font-style: normal !important; font-weight: normal !important; height: auto !important; left: auto !important; line-height: 1.1em !important; margin-bottom: 0px !important; margin-left: 0px !important; margin-right: 0px !important; margin-top: 0px !important; min-height: inherit !important; outline-color: initial !important; outline-style: initial !important; outline-width: 0px !important; padding-bottom: 0px !important; padding-left: 0.5em !important; padding-right: 0px !important; padding-top: 0px !important; position: static !important; right: auto !important; text-align: left !important; top: auto !important; vertical-align: top !important; width: auto !important;"&gt;&lt;code class="spaces" style="-webkit-background-clip: initial !important; -webkit-background-origin: initial !important; background-attachment: initial !important; background-color: initial !important; background-image: none !important; background-position: initial initial !important; background-repeat: initial !important; border-bottom-width: 0px !important; border-color: initial !important; border-color: initial; border-left-width: 0px !important; border-right-width: 0px !important; border-style: initial !important; border-style: initial; border-top-width: 0px !important; bottom: auto !important; float: none !important; font-family: Consolas, 'Bitstream Vera Sans Mono', 'Courier New', Courier, monospace !important; font-size: 12px !important; font-style: normal !important; font-weight: normal !important; font: normal normal normal 12px/1.4 Consolas, 'Andale Mono', Courier, 'Courier New', monospace; height: auto !important; left: auto !important; line-height: 1.1em !important; margin-bottom: 0px !important; margin-left: 0px !important; margin-right: 0px !important; margin-top: 0px !important; min-height: inherit !important; outline-color: initial !important; outline-style: initial !important; outline-width: 0px !important; padding-bottom: 0px !important; padding-left: 0px !important; padding-right: 0px !important; padding-top: 0px !important; position: static !important; right: auto !important; text-align: left !important; top: auto !important; vertical-align: baseline !important; width: auto !important;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;/code&gt;&lt;code class="plain" style="-webkit-background-clip: initial !important; -webkit-background-origin: initial !important; background-attachment: initial !important; background-color: initial !important; background-image: none !important; background-position: initial initial !important; background-repeat: initial !important; border-bottom-width: 0px !important; border-color: initial !important; border-color: initial; border-left-width: 0px !important; border-right-width: 0px !important; border-style: initial !important; border-style: initial; border-top-width: 0px !important; bottom: auto !important; color: rgb(0, 0, 0) !important; float: none !important; font-family: Consolas, 'Bitstream Vera Sans Mono', 'Courier New', Courier, monospace !important; font-size: 12px !important; font-style: normal !important; font-weight: normal !important; font: normal normal normal 12px/1.4 Consolas, 'Andale Mono', Courier, 'Courier New', monospace; height: auto !important; left: auto !important; line-height: 1.1em !important; margin-bottom: 0px !important; margin-left: 0px !important; margin-right: 0px !important; margin-top: 0px !important; min-height: inherit !important; outline-color: initial !important; outline-style: initial !important; outline-width: 0px !important; padding-bottom: 0px !important; padding-left: 0px !important; padding-right: 0px !important; padding-top: 0px !important; position: static !important; right: auto !important; text-align: left !important; top: auto !important; vertical-align: baseline !important; width: auto !important;"&gt;r = 0.5 * ( r + (n/r) );&lt;/code&gt;&lt;/td&gt;&lt;/tr&gt;&lt;/tbody&gt;&lt;/table&gt;&lt;/div&gt;&lt;div class="line alt2" style="-webkit-background-clip: initial !important; -webkit-background-origin: initial !important; background-attachment: initial !important; background-color: rgb(248, 248, 248) !important; background-image: none !important; background-position: initial initial !important; background-repeat: initial !important; border-bottom-width: 0px !important; border-color: initial !important; border-color: initial; border-left-width: 0px !important; border-right-width: 0px !important; border-style: initial !important; border-style: initial; border-top-width: 0px !important; bottom: auto !important; float: none !important; font-family: Consolas, 'Bitstream Vera Sans Mono', 'Courier New', Courier, monospace !important; font-size: 12px !important; font-style: normal !important; font-weight: normal !important; height: auto !important; left: auto !important; line-height: 1.1em !important; margin-bottom: 0px !important; margin-left: 0px !important; margin-right: 0px !important; margin-top: 0px !important; min-height: inherit !important; outline-color: initial !important; outline-style: initial !important; outline-width: 0px !important; padding-bottom: 0px !important; padding-left: 0px !important; padding-right: 0px !important; padding-top: 0px !important; position: static !important; right: auto !important; text-align: left !important; top: auto !important; vertical-align: baseline !important; width: auto !important;"&gt;&lt;table style="-webkit-background-clip: initial !important; -webkit-background-origin: initial !important; -webkit-border-horizontal-spacing: 0px; -webkit-border-vertical-spacing: 0px; background-attachment: initial !important; background-color: initial !important; background-image: none !important; background-position: initial initial !important; background-repeat: initial !important; border-bottom-width: 0px !important; border-collapse: collapse !important; border-color: initial !important; border-color: initial; border-left-width: 0px !important; border-right-width: 0px !important; border-style: initial !important; border-style: initial; border-top-width: 0px !important; bottom: auto !important; float: none !important; font-family: Consolas, 'Bitstream Vera Sans Mono', 'Courier New', Courier, monospace !important; font-size: 12px !important; font-style: normal !important; font-weight: normal !important; height: auto !important; left: auto !important; line-height: 1.1em !important; margin-bottom: 0px !important; margin-left: 0px !important; margin-right: 0px !important; margin-top: 0px !important; min-height: inherit !important; outline-color: initial !important; outline-style: initial !important; outline-width: 0px !important; padding-bottom: 0px !important; padding-left: 0px !important; padding-right: 0px !important; padding-top: 0px !important; position: static !important; right: auto !important; text-align: left !important; top: auto !important; vertical-align: baseline !important; width: auto !important;"&gt;&lt;tbody style="-webkit-background-clip: initial !important; -webkit-background-origin: initial !important; background-attachment: initial !important; background-color: initial !important; background-image: none !important; background-position: initial initial !important; background-repeat: initial !important; border-bottom-width: 0px !important; border-color: initial !important; border-color: initial; border-left-width: 0px !important; border-right-width: 0px !important; border-style: initial !important; border-style: initial; border-top-width: 0px !important; bottom: auto !important; float: none !important; font-family: Consolas, 'Bitstream Vera Sans Mono', 'Courier New', Courier, monospace !important; font-size: 12px !important; font-style: normal !important; font-weight: normal !important; height: auto !important; left: auto !important; line-height: 1.1em !important; margin-bottom: 0px !important; margin-left: 0px !important; margin-right: 0px !important; margin-top: 0px !important; min-height: inherit !important; outline-color: initial !important; outline-style: initial !important; outline-width: 0px !important; padding-bottom: 0px !important; padding-left: 0px !important; padding-right: 0px !important; padding-top: 0px !important; position: static !important; right: auto !important; text-align: left !important; top: auto !important; vertical-align: baseline !important; width: auto !important;"&gt;&lt;tr style="-webkit-background-clip: initial !important; -webkit-background-origin: initial !important; background-attachment: initial !important; background-color: initial !important; background-image: none !important; background-position: initial initial !important; background-repeat: initial !important; border-bottom-width: 0px !important; border-color: initial !important; border-color: initial; border-left-width: 0px !important; border-right-width: 0px !important; border-style: initial !important; border-style: initial; border-top-width: 0px !important; bottom: auto !important; float: none !important; font-family: Consolas, 'Bitstream Vera Sans Mono', 'Courier New', Courier, monospace !important; font-size: 12px !important; font-style: normal !important; font-weight: normal !important; height: auto !important; left: auto !important; line-height: 1.1em !important; margin-bottom: 0px !important; margin-left: 0px !important; margin-right: 0px !important; margin-top: 0px !important; min-height: inherit !important; outline-color: initial !important; outline-style: initial !important; outline-width: 0px !important; padding-bottom: 0px !important; padding-left: 0px !important; padding-right: 0px !important; padding-top: 0px !important; position: static !important; right: auto !important; text-align: left !important; top: auto !important; vertical-align: baseline !important; width: auto !important;"&gt;&lt;td class="number" style="-webkit-background-clip: initial !important; -webkit-background-origin: initial !important; background-attachment: initial !important; background-color: initial !important; background-image: none !important; background-position: initial initial !important; background-repeat: initial !important; border-bottom-width: 0px !important; border-color: initial !important; border-color: initial; border-left-width: 0px !important; border-right-width: 0px !important; border-style: initial !important; border-style: initial; border-top-width: 0px !important; bottom: auto !important; color: rgb(175, 175, 175) !important; float: none !important; font-family: Consolas, 'Bitstream Vera Sans Mono', 'Courier New', Courier, monospace !important; font-size: 12px !important; font-style: normal !important; font-weight: normal !important; height: auto !important; left: auto !important; line-height: 1.1em !important; margin-bottom: 0px !important; margin-left: 0px !important; margin-right: 0px !important; margin-top: 0px !important; min-height: inherit !important; outline-color: initial !important; outline-style: initial !important; outline-width: 0px !important; padding-bottom: 0px !important; padding-left: 0px !important; padding-right: 0px !important; padding-top: 0px !important; position: static !important; right: auto !important; text-align: left !important; top: auto !important; vertical-align: top !important; width: 3em !important;"&gt;&lt;code style="-webkit-background-clip: initial !important; -webkit-background-origin: initial !important; background-attachment: initial !important; background-color: initial !important; background-image: none !important; background-position: initial initial !important; background-repeat: initial !important; border-bottom-width: 0px !important; border-color: initial !important; border-color: initial; border-left-width: 0px !important; border-right-width: 0px !important; border-style: initial !important; border-style: initial; border-top-width: 0px !important; bottom: auto !important; display: block !important; float: none !important; font-family: Consolas, 'Bitstream Vera Sans Mono', 'Courier New', Courier, monospace !important; font-size: 12px !important; font-style: normal !important; font-weight: normal !important; font: normal normal normal 12px/1.4 Consolas, 'Andale Mono', Courier, 'Courier New', monospace; height: auto !important; left: auto !important; line-height: 1.1em !important; margin-bottom: 0px !important; margin-left: 0px !important; margin-right: 0px !important; margin-top: 0px !important; min-height: inherit !important; outline-color: initial !important; outline-style: initial !important; outline-width: 0px !important; padding-bottom: 0px !important; padding-left: 0px !important; padding-right: 0.3em !important; padding-top: 0px !important; position: static !important; right: auto !important; text-align: right !important; top: auto !important; vertical-align: baseline !important; width: 2.7em !important;"&gt;6&lt;/code&gt;&lt;/td&gt;&lt;td class="content" style="-webkit-background-clip: initial !important; -webkit-background-origin: initial !important; background-attachment: initial !important; background-color: initial !important; background-image: none !important; background-position: initial initial !important; background-repeat: initial !important; border-bottom-width: 0px !important; border-color: initial !important; border-color: initial; border-left-color: rgb(108, 226, 108) !important; border-left-style: solid !important; border-left-width: 3px !important; border-right-width: 0px !important; border-style: initial !important; border-style: initial; border-top-width: 0px !important; bottom: auto !important; color: rgb(0, 0, 0) !important; float: none !important; font-family: Consolas, 'Bitstream Vera Sans Mono', 'Courier New', Courier, monospace !important; font-size: 12px !important; font-style: normal !important; font-weight: normal !important; height: auto !important; left: auto !important; line-height: 1.1em !important; margin-bottom: 0px !important; margin-left: 0px !important; margin-right: 0px !important; margin-top: 0px !important; min-height: inherit !important; outline-color: initial !important; outline-style: initial !important; outline-width: 0px !important; padding-bottom: 0px !important; padding-left: 0.5em !important; padding-right: 0px !important; padding-top: 0px !important; position: static !important; right: auto !important; text-align: left !important; top: auto !important; vertical-align: top !important; width: auto !important;"&gt;&lt;code class="plain" style="-webkit-background-clip: initial !important; -webkit-background-origin: initial !important; background-attachment: initial !important; background-color: initial !important; background-image: none !important; background-position: initial initial !important; background-repeat: initial !important; border-bottom-width: 0px !important; border-color: initial !important; border-color: initial; border-left-width: 0px !important; border-right-width: 0px !important; border-style: initial !important; border-style: initial; border-top-width: 0px !important; bottom: auto !important; color: rgb(0, 0, 0) !important; float: none !important; font-family: Consolas, 'Bitstream Vera Sans Mono', 'Courier New', Courier, monospace !important; font-size: 12px !important; font-style: normal !important; font-weight: normal !important; font: normal normal normal 12px/1.4 Consolas, 'Andale Mono', Courier, 'Courier New', monospace; height: auto !important; left: auto !important; line-height: 1.1em !important; margin-bottom: 0px !important; margin-left: 0px !important; margin-right: 0px !important; margin-top: 0px !important; min-height: inherit !important; outline-color: initial !important; outline-style: initial !important; outline-width: 0px !important; padding-bottom: 0px !important; padding-left: 0px !important; padding-right: 0px !important; padding-top: 0px !important; position: static !important; right: auto !important; text-align: left !important; top: auto !important; vertical-align: baseline !important; width: auto !important;"&gt;}&lt;/code&gt;&lt;/td&gt;&lt;/tr&gt;&lt;/tbody&gt;&lt;/table&gt;&lt;/div&gt;&lt;/div&gt;&lt;/div&gt;&lt;div style="border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; font-family: inherit; font-size: 16px; font-style: inherit; font-weight: inherit; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; vertical-align: baseline;"&gt;Much better! We still might not understand exactly what’s going on here, but at least we have a starting point.&lt;/div&gt;&lt;div style="border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; font-family: inherit; font-size: 16px; font-style: inherit; font-weight: inherit; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; vertical-align: baseline;"&gt;Comments are supposed to help the reader understand the code, not the syntax. It’s a fair assumption that the reader has a basic understanding of how a for loop works; there’s no need to add comments such as “// iterate over a list of customers”. What the reader is not going to be familiar with is why your code works and why you chose to write it the way you did.&lt;/div&gt;&lt;h2 style="border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; clear: both; font-family: Georgia, 'Times New Roman', 'Bitstream Charter', Times, serif; font-size: 20px; font-style: italic; font-weight: normal; line-height: 22px; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 5px; padding-left: 0px; padding-right: 0px; padding-top: 5px; vertical-align: baseline;"&gt;9. Interruptions&lt;/h2&gt;&lt;div style="border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; font-family: inherit; font-size: 16px; font-style: inherit; font-weight: inherit; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; vertical-align: baseline;"&gt;Very few programmers can go from 0 to code at the drop of a hat. In general,&amp;nbsp;&lt;strong style="font-weight: bold;"&gt;we tend to be more akin to locomotives than ferraris&lt;/strong&gt;; it may take us awhile to get started, but once we hit our stride we can get an impressive amount of work done. Unfortunately, it’s very hard to get into a programming zone when your train of thought is constantly being derailed by clients, managers, and fellow programmers.&lt;/div&gt;&lt;div style="border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; font-family: inherit; font-size: 16px; font-style: inherit; font-weight: inherit; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; vertical-align: baseline;"&gt;There is simply too much information we need to keep in mind while we’re working on a task to be able to drop the task, handle another issue, then pick up the task without missing a beat. Interruptions kill our train of thought and getting it back is often a time-consuming, frustrating, and worst of all, error-prone process.&lt;/div&gt;&lt;h2 style="border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; clear: both; font-family: Georgia, 'Times New Roman', 'Bitstream Charter', Times, serif; font-size: 20px; font-style: italic; font-weight: normal; line-height: 22px; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 5px; padding-left: 0px; padding-right: 0px; padding-top: 5px; vertical-align: baseline;"&gt;8. Scope creep&lt;/h2&gt;&lt;div style="border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; font-family: inherit; font-size: 16px; font-style: inherit; font-weight: inherit; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; vertical-align: baseline;"&gt;From&amp;nbsp;&lt;a href="http://en.wikipedia.org/wiki/Scope_creep" style="border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; color: #0077cc; font-family: inherit; font-size: 16px; font-style: inherit; font-weight: inherit; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; text-decoration: none; vertical-align: baseline;"&gt;Wikipedia&lt;/a&gt;:&lt;/div&gt;&lt;blockquote style="border-bottom-width: 0px; border-color: initial; border-left-color: rgb(221, 221, 221); border-left-style: solid; border-left-width: 1px; border-right-width: 0px; border-style: initial; border-top-width: 0px; color: #666666; font-family: inherit; font-size: 16px; font-style: italic; font-weight: inherit; margin-bottom: 20px; margin-left: 15px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 10px; padding-right: 0px; padding-top: 0px; vertical-align: baseline;"&gt;&lt;div style="border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; font-family: inherit; font-size: 16px; font-style: inherit; font-weight: inherit; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; vertical-align: baseline;"&gt;Scope creep (also called focus creep, requirement creep, feature creep, and sometimes kitchen sink syndrome) in project management refers to uncontrolled changes in a project’s scope. This phenomenon can occur when the scope of a project is not properly defined, documented, or controlled. It is generally considered a negative occurrence that is to be avoided.&lt;/div&gt;&lt;/blockquote&gt;&lt;div style="border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; font-family: inherit; font-size: 16px; font-style: inherit; font-weight: inherit; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; vertical-align: baseline;"&gt;Scope creep turns relatively simple requests into horribly complex and time consuming monsters. It only takes a few innocent keystrokes by the requirements guy for scope creep to happen:&lt;/div&gt;&lt;ul style="border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; font-family: inherit; font-size: 16px; font-style: inherit; font-weight: inherit; list-style-type: disc; margin-bottom: 20px; margin-left: 25px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; vertical-align: baseline;"&gt;&lt;li style="border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; font-family: inherit; font-size: 16px; font-style: inherit; font-weight: inherit; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; vertical-align: baseline;"&gt;Version 1: Show a map of the location&lt;/li&gt;&lt;li style="border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; font-family: inherit; font-size: 16px; font-style: inherit; font-weight: inherit; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; vertical-align: baseline;"&gt;Version 2: Show a&amp;nbsp;&lt;strong style="font-weight: bold;"&gt;3D&lt;/strong&gt;&amp;nbsp;map of the location&lt;/li&gt;&lt;li style="border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; font-family: inherit; font-size: 16px; font-style: inherit; font-weight: inherit; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; vertical-align: baseline;"&gt;Version 3: Show a&amp;nbsp;&lt;strong style="font-weight: bold;"&gt;3D&lt;/strong&gt;&amp;nbsp;map of the location&amp;nbsp;&lt;strong style="font-weight: bold;"&gt;that the user can fly through&lt;/strong&gt;&lt;/li&gt;&lt;/ul&gt;&lt;div style="border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; font-family: inherit; font-size: 16px; font-style: inherit; font-weight: inherit; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; vertical-align: baseline;"&gt;Argh! What used to be a 30 minute task just turned into a massively complex system that could take hundreds of man hours. Even worse, most of the time scope creep happens&amp;nbsp;&lt;em style="border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; font-family: inherit; font-size: 16px; font-style: italic; font-weight: inherit; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; vertical-align: baseline;"&gt;during&lt;/em&gt;&amp;nbsp;development, which requires rewriting, refactoring, and sometimes throwing out code that was developed just days prior.&lt;/div&gt;&lt;h2 style="border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; clear: both; font-family: Georgia, 'Times New Roman', 'Bitstream Charter', Times, serif; font-size: 20px; font-style: italic; font-weight: normal; line-height: 22px; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 5px; padding-left: 0px; padding-right: 0px; padding-top: 5px; vertical-align: baseline;"&gt;7. Management that doesn’t understand programming&lt;/h2&gt;&lt;div style="border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; float: right; font-family: inherit; font-size: 16px; font-style: inherit; font-weight: inherit; margin-bottom: 0px; margin-left: 20px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; vertical-align: baseline;"&gt;&lt;div style="border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; font-family: inherit; font-size: 16px; font-style: inherit; font-weight: inherit; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; vertical-align: baseline;"&gt;&lt;img alt="Compiling" src="http://www.kevinwilliampang.com/wp-content/uploads/Compiling3.png" style="border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; font-family: inherit; font-size: 16px; font-style: inherit; font-weight: inherit; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; vertical-align: baseline;" /&gt;&lt;br /&gt;&lt;em style="border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; font-family: inherit; font-size: 16px; font-style: italic; font-weight: inherit; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; vertical-align: baseline;"&gt;Ok, so maybe there are&amp;nbsp;&lt;a href="http://xkcd.com/303/" style="border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; color: #0077cc; font-family: inherit; font-size: 16px; font-style: inherit; font-weight: inherit; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; text-decoration: none; vertical-align: baseline;"&gt;some perks&lt;/a&gt;.&lt;/em&gt;&lt;/div&gt;&lt;/div&gt;&lt;div style="border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; font-family: inherit; font-size: 16px; font-style: inherit; font-weight: inherit; height: 220px; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; vertical-align: baseline;"&gt;Management is not an easy job. People&amp;nbsp;&lt;strong style="font-weight: bold;"&gt;suck&lt;/strong&gt;; we’re fickle and fragile and we’re all out for #1. Keeping a large group of us content and cohesive is a mountain of a task. However, that doesn’t mean that managers should be able to get away without having some basic understanding of what their subordinates are doing. When management cannot grasp the basic concepts of our jobs, we end up with scope creep, unrealistic deadlines, and general frustration on both sides of the table. This is a pretty common complaint amongst programmers and the source of a lot of angst (as well as one hilarious&amp;nbsp;&lt;a href="http://www.dilbert.com/" style="border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; color: #0077cc; font-family: inherit; font-size: 16px; font-style: inherit; font-weight: inherit; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; text-decoration: none; vertical-align: baseline;"&gt;cartoon&lt;/a&gt;).&lt;/div&gt;&lt;h2 style="border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; clear: both; font-family: Georgia, 'Times New Roman', 'Bitstream Charter', Times, serif; font-size: 20px; font-style: italic; font-weight: normal; line-height: 22px; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 5px; padding-left: 0px; padding-right: 0px; padding-top: 5px; vertical-align: baseline;"&gt;&lt;br /&gt;&lt;/h2&gt;&lt;h2 style="border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; clear: both; font-family: Georgia, 'Times New Roman', 'Bitstream Charter', Times, serif; font-size: 20px; font-style: italic; font-weight: normal; line-height: 22px; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 5px; padding-left: 0px; padding-right: 0px; padding-top: 5px; vertical-align: baseline;"&gt;&lt;br /&gt;&lt;/h2&gt;&lt;h2 style="border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; clear: both; font-family: Georgia, 'Times New Roman', 'Bitstream Charter', Times, serif; font-size: 20px; font-style: italic; font-weight: normal; line-height: 22px; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 5px; padding-left: 0px; padding-right: 0px; padding-top: 5px; vertical-align: baseline;"&gt;&lt;br /&gt;&lt;/h2&gt;&lt;h2 style="border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; clear: both; font-family: Georgia, 'Times New Roman', 'Bitstream Charter', Times, serif; font-size: 20px; font-style: italic; font-weight: normal; line-height: 22px; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 5px; padding-left: 0px; padding-right: 0px; padding-top: 5px; vertical-align: baseline;"&gt;&lt;br /&gt;&lt;/h2&gt;&lt;h2 style="border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; clear: both; font-family: Georgia, 'Times New Roman', 'Bitstream Charter', Times, serif; font-size: 20px; font-style: italic; font-weight: normal; line-height: 22px; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 5px; padding-left: 0px; padding-right: 0px; padding-top: 5px; vertical-align: baseline;"&gt;&lt;br /&gt;&lt;/h2&gt;&lt;h2 style="border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; clear: both; font-family: Georgia, 'Times New Roman', 'Bitstream Charter', Times, serif; font-size: 20px; font-style: italic; font-weight: normal; line-height: 22px; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 5px; padding-left: 0px; padding-right: 0px; padding-top: 5px; vertical-align: baseline;"&gt;&lt;br /&gt;&lt;/h2&gt;&lt;h2 style="border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; clear: both; font-family: Georgia, 'Times New Roman', 'Bitstream Charter', Times, serif; font-size: 20px; font-style: italic; font-weight: normal; line-height: 22px; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 5px; padding-left: 0px; padding-right: 0px; padding-top: 5px; vertical-align: baseline;"&gt;6. Documenting our applications&lt;/h2&gt;&lt;div style="border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; font-family: inherit; font-size: 16px; font-style: inherit; font-weight: inherit; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; vertical-align: baseline;"&gt;Let me preface this by saying that yes, I know that there are a lot of documentation-generating applications out there, but in my experience those are usually only good for generating API documentation for other programmers to read. If you are working with an application that normal everyday people are using, you’re going to have to write some documentation that the average layman can understand (e.g. how your application works, troubleshooting guides, etc.).&lt;/div&gt;&lt;div style="border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; font-family: inherit; font-size: 16px; font-style: inherit; font-weight: inherit; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; vertical-align: baseline;"&gt;It’s not hard to see that this is something programmers dread doing. Take a quick look at all the open-source projects out there. What’s the one thing that all of them are constantly asking for help with? Documentation.&lt;/div&gt;&lt;div style="border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; font-family: inherit; font-size: 16px; font-style: inherit; font-weight: inherit; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; vertical-align: baseline;"&gt;I think I can safely speak on behalf of all programmers everywhere when I say, “&lt;a href="http://en.wikipedia.org/wiki/Trash_of_the_Titans" style="border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; color: #0077cc; font-family: inherit; font-size: 16px; font-style: inherit; font-weight: inherit; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; text-decoration: none; vertical-align: baseline;"&gt;can’t someone else do it?&lt;/a&gt;“.&lt;/div&gt;&lt;h2 style="border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; clear: both; font-family: Georgia, 'Times New Roman', 'Bitstream Charter', Times, serif; font-size: 20px; font-style: italic; font-weight: normal; line-height: 22px; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 5px; padding-left: 0px; padding-right: 0px; padding-top: 5px; vertical-align: baseline;"&gt;5. Applications without documentation&lt;/h2&gt;&lt;div style="border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; font-family: inherit; font-size: 16px; font-style: inherit; font-weight: inherit; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; vertical-align: baseline;"&gt;I never said that we weren’t hypocrites.&amp;nbsp;&lt;img alt=":-)" class="wp-smiley" src="http://www.kevinwilliampang.com/wp-includes/images/smilies/icon_smile.gif" style="border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; font-family: inherit; font-size: 16px; font-style: inherit; font-weight: inherit; margin-bottom: 0px !important; margin-left: 0px !important; margin-right: 0px !important; margin-top: 0px !important; max-height: 13px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; vertical-align: baseline;" /&gt;&amp;nbsp;Programmers are constantly asked to incorporate 3rd party libraries and applications into their work. In order to do that,&amp;nbsp;&lt;strong style="font-weight: bold;"&gt;we need documentation&lt;/strong&gt;. Unfortunately, as mentioned in item 6, programmers hate writing documentation. No, the irony is not lost on us.&lt;/div&gt;&lt;div style="border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; font-family: inherit; font-size: 16px; font-style: inherit; font-weight: inherit; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; vertical-align: baseline;"&gt;&lt;strong style="font-weight: bold;"&gt;There is nothing more frustrating than trying to utilize a 3rd party library while having absolutely no fricken idea what half the functions in the API do&lt;/strong&gt;. What’s the difference between poorlyNamedFunctionA() and poorlyButSimilarlyNamedFunctionB()? Do I need to perform a null check before accessing PropertyX? I guess I’ll just have to find out through trial and error! Ugh.&lt;/div&gt;&lt;h2 style="border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; clear: both; font-family: Georgia, 'Times New Roman', 'Bitstream Charter', Times, serif; font-size: 20px; font-style: italic; font-weight: normal; line-height: 22px; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 5px; padding-left: 0px; padding-right: 0px; padding-top: 5px; vertical-align: baseline;"&gt;4. Hardware&lt;/h2&gt;&lt;div style="border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; font-family: inherit; font-size: 16px; font-style: inherit; font-weight: inherit; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; vertical-align: baseline;"&gt;Any programmer who has ever been called upon to debug a strange crash on the database server or why the RAID drives aren’t working properly knows that hardware problems are a pain. There seems to be a common misconception that since programmers work with computers, we must know how to fix them. Granted, this may be true for some programmers, but I reckon the vast majority of us don’t know or really care about what’s going on after the code gets translated into assembly. We just want the stuff to work like it’s supposed to so we can focus on higher level tasks.&lt;/div&gt;&lt;h2 style="border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; clear: both; font-family: Georgia, 'Times New Roman', 'Bitstream Charter', Times, serif; font-size: 20px; font-style: italic; font-weight: normal; line-height: 22px; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 5px; padding-left: 0px; padding-right: 0px; padding-top: 5px; vertical-align: baseline;"&gt;3. Vagueness&lt;/h2&gt;&lt;div style="border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; font-family: inherit; font-size: 16px; font-style: inherit; font-weight: inherit; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; vertical-align: baseline;"&gt;“The website is broken”. “Feature X isn’t working properly”.&amp;nbsp;&lt;strong style="font-weight: bold;"&gt;Vague requests are a pain to deal with&lt;/strong&gt;. It’s always surprising to me how exasperated non-programmers tend to get when they are asked to reproduce a problem for a programmer. They don’t seem to understand that “it’s broken, fix it!” is&amp;nbsp;&lt;strong style="font-weight: bold;"&gt;not&lt;/strong&gt;&amp;nbsp;enough information for us to work off of.&lt;/div&gt;&lt;div style="border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; font-family: inherit; font-size: 16px; font-style: inherit; font-weight: inherit; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; vertical-align: baseline;"&gt;Software is (for the most part) deterministic. We like it that way. Humor us by letting us figure out which step of the process is broken instead of asking us to simply “fix it”.&lt;/div&gt;&lt;h2 style="border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; clear: both; font-family: Georgia, 'Times New Roman', 'Bitstream Charter', Times, serif; font-size: 20px; font-style: italic; font-weight: normal; line-height: 22px; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 5px; padding-left: 0px; padding-right: 0px; padding-top: 5px; vertical-align: baseline;"&gt;2. Other programmers&lt;/h2&gt;&lt;div style="border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; font-family: inherit; font-size: 16px; font-style: inherit; font-weight: inherit; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; vertical-align: baseline;"&gt;Programmers don’t always get along with other programmers. Shocking, but true. This could easily be its own top 10 list, so I’m just going to list some of the common traits programmers have that annoy their fellow programmers and save going into detail for a separate post:&lt;/div&gt;&lt;ul style="border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; font-family: inherit; font-size: 16px; font-style: inherit; font-weight: inherit; list-style-type: disc; margin-bottom: 20px; margin-left: 25px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; vertical-align: baseline;"&gt;&lt;li style="border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; font-family: inherit; font-size: 16px; font-style: inherit; font-weight: inherit; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; vertical-align: baseline;"&gt;Being grumpy to the point of being hostile.&lt;/li&gt;&lt;li style="border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; font-family: inherit; font-size: 16px; font-style: inherit; font-weight: inherit; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; vertical-align: baseline;"&gt;Failing to understand that there is a time to debate system architecture and a time to get things done.&lt;/li&gt;&lt;li style="border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; font-family: inherit; font-size: 16px; font-style: inherit; font-weight: inherit; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; vertical-align: baseline;"&gt;Inability to communicate effectively and confusing terminology.&lt;/li&gt;&lt;li style="border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; font-family: inherit; font-size: 16px; font-style: inherit; font-weight: inherit; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; vertical-align: baseline;"&gt;Failure to pull ones own weight.&lt;/li&gt;&lt;li style="border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; font-family: inherit; font-size: 16px; font-style: inherit; font-weight: inherit; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; vertical-align: baseline;"&gt;Being apathetic towards the code base and project&lt;/li&gt;&lt;/ul&gt;&lt;div style="border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; font-family: inherit; font-size: 16px; font-style: inherit; font-weight: inherit; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; vertical-align: baseline;"&gt;And last, but not least, the number 1 thing that annoys programmers…&lt;/div&gt;&lt;h2 style="border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; clear: both; font-family: Georgia, 'Times New Roman', 'Bitstream Charter', Times, serif; font-size: 20px; font-style: italic; font-weight: normal; line-height: 22px; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 5px; padding-left: 0px; padding-right: 0px; padding-top: 5px; vertical-align: baseline;"&gt;1. Their own code, 6 months later&lt;/h2&gt;&lt;div style="border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; float: right; font-family: inherit; font-size: 16px; font-style: inherit; font-weight: inherit; margin-bottom: 0px; margin-left: 20px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; vertical-align: baseline;"&gt;&lt;div style="border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; font-family: inherit; font-size: 16px; font-style: inherit; font-weight: inherit; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; vertical-align: baseline;"&gt;&lt;img alt="" src="http://www.kevinwilliampang.com/wp-content/uploads/Sand-Mandala2.JPG" style="border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; font-family: inherit; font-size: 16px; font-style: inherit; font-weight: inherit; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; vertical-align: baseline;" /&gt;&lt;br /&gt;&lt;em style="border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; font-family: inherit; font-size: 16px; font-style: italic; font-weight: inherit; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; vertical-align: baseline;"&gt;Don’t sneeze, I think I see a bug.&lt;/em&gt;&lt;/div&gt;&lt;/div&gt;&lt;div style="border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; font-family: inherit; font-size: 16px; font-style: inherit; font-weight: inherit; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; vertical-align: baseline;"&gt;Ever look back at some of your old code and grimace in pain? How stupid you were! How could you, who know so much&amp;nbsp;&lt;em style="border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; font-family: inherit; font-size: 16px; font-style: italic; font-weight: inherit; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; vertical-align: baseline;"&gt;now&lt;/em&gt;, have written&amp;nbsp;&lt;em style="border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; font-family: inherit; font-size: 16px; font-style: italic; font-weight: inherit; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; vertical-align: baseline;"&gt;that&lt;/em&gt;? Burn it! Burn it with fire!&lt;/div&gt;&lt;div style="border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; font-family: inherit; font-size: 16px; font-style: inherit; font-weight: inherit; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; vertical-align: baseline;"&gt;Well, good news. You’re not alone.&lt;/div&gt;&lt;div style="border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; font-family: inherit; font-size: 16px; font-style: inherit; font-weight: inherit; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; vertical-align: baseline;"&gt;The truth is, the programming world is one that is constantly changing. What we regard as a best practice today can be obsolete tomorrow. It’s simply not possible to write perfect code because the standards upon which our code is judged is evolving every day. It’s tough to cope with the fact that your work, as beautiful as it may be&amp;nbsp;&lt;em style="border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; font-family: inherit; font-size: 16px; font-style: italic; font-weight: inherit; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; vertical-align: baseline;"&gt;now&lt;/em&gt;, is probably going to be ridiculed later. It’s frustrating because no matter how much research we do into the latest and greatest tools, designs, frameworks, and best practices, there’s always the sense that what we’re truly after is slightly out of reach. For me, this is the most annoying thing about being a programmer. The fragility of what we do is necessary to facilitate improvement, but I can’t help feeling like I’m one of those&amp;nbsp;&lt;a href="http://en.wikipedia.org/wiki/Sand_mandala" style="border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; color: #0077cc; font-family: inherit; font-size: 16px; font-style: inherit; font-weight: inherit; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; text-decoration: none; vertical-align: baseline;"&gt;sand-painting monks&lt;/a&gt;.&lt;/div&gt;&lt;div style="border-bottom-width: 0px; border-color: initial; border-left-width: 0px; border-right-width: 0px; border-style: initial; border-top-width: 0px; font-family: inherit; font-size: 16px; font-style: inherit; font-weight: inherit; margin-bottom: 1em; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px; vertical-align: baseline;"&gt;Well, there you have it. The top 10 things that annoy programmers. Again, if you feel that I missed anything please be sure to let me know in the comments!&lt;/div&gt;&lt;/div&gt;&lt;br /&gt;&lt;/div&gt;&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/21595493-2685468553766775308?l=linux4research.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://linux4research.blogspot.com/feeds/2685468553766775308/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=21595493&amp;postID=2685468553766775308' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/21595493/posts/default/2685468553766775308'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/21595493/posts/default/2685468553766775308'/><link rel='alternate' type='text/html' href='http://linux4research.blogspot.com/2010/03/top-10-things-that-annoy-programmer.html' title='Top 10 things that annoy programmer'/><author><name>Dave</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-21595493.post-8945981797054136116</id><published>2010-03-19T19:51:00.000-05:00</published><updated>2010-03-19T19:51:02.420-05:00</updated><title type='text'>locales in debian system.</title><content type='html'>&lt;h2&gt;Configuring Locales&lt;/h2&gt;&lt;h3&gt;The Easy Way&lt;/h3&gt;&lt;ol&gt;&lt;li&gt;Install debconf (i.e. run &lt;tt&gt;apt-get update&lt;/tt&gt; then &lt;tt&gt;apt-get install debconf&lt;/tt&gt;, as root)&lt;/li&gt;&lt;li&gt;Run &lt;tt&gt;dpkg-reconfigure locales&lt;/tt&gt; as root&lt;/li&gt;&lt;/ol&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/21595493-8945981797054136116?l=linux4research.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://linux4research.blogspot.com/feeds/8945981797054136116/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=21595493&amp;postID=8945981797054136116' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/21595493/posts/default/8945981797054136116'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/21595493/posts/default/8945981797054136116'/><link rel='alternate' type='text/html' href='http://linux4research.blogspot.com/2010/03/locales-in-debian-system.html' title='locales in debian system.'/><author><name>Dave</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-21595493.post-9213094306456609011</id><published>2010-01-09T20:08:00.001-06:00</published><updated>2010-11-17T20:09:40.428-06:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='Mac'/><title type='text'>problem with iwork: keynote quit unexpectedly while using the SFWordProcessing plugin</title><content type='html'>Solution is &lt;a href="http://support.apple.com/kb/TS3161"&gt;here&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style="color: #333333; font-family: 'Lucida Grande', Geneva, Arial, Verdana, sans-serif; font-size: 12px; line-height: 18px;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;div id="articlecontent" style="margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;"&gt;&lt;div class="attr SYMPTOMS" style="margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 15px; padding-left: 0px; padding-right: 0px; padding-top: 0px;"&gt;&lt;h2 style="font-size: 14px; font-style: normal; font-weight: bold; line-height: 18px; margin-bottom: 4px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;"&gt;Symptoms&lt;/h2&gt;&lt;div style="margin-bottom: 18px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;"&gt;After updating to Mac OS X v10.6.2, iWeb and iWork applications may quit unexpectedly. On my computer it shows the following:&lt;br /&gt;"keynote quit unexpectedly while using the SFWordProcessing plugin"&lt;br /&gt;&lt;/div&gt;&lt;/div&gt;&lt;div class="affected" style="border-bottom-color: rgb(232, 232, 232); border-bottom-style: solid; border-bottom-width: 1px; border-top-color: rgb(232, 232, 232); border-top-style: solid; border-top-width: 1px; color: #888888; margin-bottom: 15px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 10px; padding-left: 0px; padding-right: 0px; padding-top: 10px;"&gt;&lt;h2 style="color: #888888; font-size: 12px; font-style: normal; font-weight: bold; line-height: 18px; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;"&gt;Products Affected&lt;/h2&gt;&lt;div style="margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;"&gt;Numbers '09, Keynote '09, iWork '09, iWeb '09&lt;br /&gt;&lt;/div&gt;&lt;/div&gt;&lt;div class="attr RESOLUTION" style="margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 15px; padding-left: 0px; padding-right: 0px; padding-top: 0px;"&gt;&lt;h2 style="font-size: 14px; font-style: normal; font-weight: bold; line-height: 18px; margin-bottom: 4px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;"&gt;Resolution&lt;/h2&gt;&lt;div style="margin-bottom: 18px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;"&gt;This issue may be resolved by removing the font database. To do this:&lt;br /&gt;&lt;/div&gt;&lt;div style="margin-bottom: 18px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;"&gt;&lt;strong style="font-size: 1em; font-style: normal; font-weight: bold;"&gt;Important&lt;/strong&gt;: If you use Font Book to manage your fonts, you will need to open Font Book after step 3. Font Book library information will be restored. However, the state of whether fonts are active or disabled will be lost. You will need to correct this manually.&lt;br /&gt;&lt;/div&gt;&lt;ol style="list-style-image: initial; list-style-position: initial; list-style-type: decimal; margin-bottom: 18px; margin-left: 2.2em; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;"&gt;&lt;li style="margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 10px; padding-left: 0px; padding-right: 0px; padding-top: 0px;"&gt;Shut down your computer.&lt;/li&gt;&lt;li style="margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 10px; padding-left: 0px; padding-right: 0px; padding-top: 0px;"&gt;Start up your computer while holding down the Shift key. This starts your computer in&amp;nbsp;&lt;a href="http://support.apple.com/kb/HT1455" onclick="s_objectID=&amp;quot;http://support.apple.com/kb/HT1455_1&amp;quot;;return this.s_oc?this.s_oc(e):true" style="color: #2971a7; text-decoration: none;"&gt;Safe Mode&lt;/a&gt;&amp;nbsp;and removes the font database.&lt;/li&gt;&lt;li style="margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 10px; padding-left: 0px; padding-right: 0px; padding-top: 0px;"&gt;Restart your computer.&lt;/li&gt;&lt;li style="margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 10px; padding-left: 0px; padding-right: 0px; padding-top: 0px;"&gt;Open the application that quit unexpectedly (iWeb, Keynote, Pages, or Numbers).&lt;/li&gt;&lt;div&gt;&lt;/div&gt;&lt;/ol&gt;&lt;/div&gt;&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/21595493-9213094306456609011?l=linux4research.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://linux4research.blogspot.com/feeds/9213094306456609011/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=21595493&amp;postID=9213094306456609011' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/21595493/posts/default/9213094306456609011'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/21595493/posts/default/9213094306456609011'/><link rel='alternate' type='text/html' href='http://linux4research.blogspot.com/2010/01/problem-with-iwork-applications-may.html' title='problem with iwork: keynote quit unexpectedly while using the SFWordProcessing plugin'/><author><name>Dave</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-21595493.post-653830520898698556</id><published>2009-12-23T11:24:00.003-06:00</published><updated>2009-12-23T11:30:48.585-06:00</updated><title type='text'>Building And Using Static And Shared "C" Libraries</title><content type='html'>&lt;div align="center" style="text-align: auto;"&gt;&lt;div style="text-align: left;"&gt;(Original location:&amp;nbsp;http://users.actcom.co.il/~choo/lupg/tutorials/libraries/unix-c-libraries.html)&lt;br /&gt;&lt;/div&gt;&lt;div style="text-align: left;"&gt;Table Of Contents:&lt;br /&gt;&lt;/div&gt;&lt;/div&gt;&lt;ol&gt;&lt;li&gt;Building And Using Static And Shared "C" Libraries&lt;/li&gt;&lt;li&gt;What Is A "C" Library? What Is It Good For?&lt;/li&gt;&lt;li&gt;Creating A Static "C" Library Using "ar" and "ranlib"&lt;/li&gt;&lt;li&gt;Using A "C" Library In A Program&lt;/li&gt;&lt;li&gt;Creating A Shared "C" Library Using "ld"&lt;/li&gt;&lt;li&gt;Using A Shared "C" Library - Quirks And Solutions&lt;/li&gt;&lt;li&gt;Using A Shared "C" Library Dynamically - Programming Interface&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;ol&gt;&lt;li&gt;Loading A Shared Library Using&amp;nbsp;&lt;code&gt;&lt;u&gt;dlopen()&lt;/u&gt;&lt;/code&gt;&lt;/li&gt;&lt;li&gt;Calling Functions Dynamically Using&amp;nbsp;&lt;code&gt;&lt;u&gt;dlsym()&lt;/u&gt;&lt;/code&gt;&lt;/li&gt;&lt;li&gt;Unloading A Shared Library Using&amp;nbsp;&lt;code&gt;&lt;u&gt;dlclose()&lt;/u&gt;&lt;/code&gt;&lt;/li&gt;&lt;li&gt;Automatic Startup And Cleanup Functions&lt;/li&gt;&lt;/ol&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;/li&gt;&lt;li&gt;Getting a Deeper Understanding - The Complete Linking Story&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;ol&gt;&lt;li&gt;The Importance Of Linking Order&lt;/li&gt;&lt;li&gt;Static Linking Vs. Dynamic Linking&lt;/li&gt;&lt;/ol&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;/li&gt;&lt;/ol&gt;&lt;hr size="4" /&gt;&lt;a href="http://www.blogger.com/post-edit.g?blogID=21595493&amp;amp;postID=653830520898698556" name="libraries"&gt;&lt;span style="color: brown;"&gt;&lt;/span&gt;&lt;/a&gt;&lt;br /&gt;&lt;a href="http://www.blogger.com/post-edit.g?blogID=21595493&amp;amp;postID=653830520898698556" name="libraries"&gt;&lt;span style="color: brown;"&gt;&lt;/span&gt;&lt;/a&gt;&lt;br /&gt;&lt;a href="http://www.blogger.com/post-edit.g?blogID=21595493&amp;amp;postID=653830520898698556" name="libraries"&gt;&lt;span style="color: brown;"&gt;&lt;/span&gt;&lt;/a&gt;&lt;br /&gt;&lt;span style="color: brown;"&gt;&lt;h2&gt;Building And Using Static And Shared "C" Libraries&lt;/h2&gt;&lt;/span&gt;One of the problems with developed programs, is that they tend to grow larger and larger, bringing up overall compilation and linking time to a large figure, and polluting out makefile, and the directory where we placed the source files. The first time a program we write reaches this state, is normally when we look for a different way to manage our projects.&lt;br /&gt;It is this point where we start thinking about combining out source code into small units of related files, that can be managed with a separate makefile, possibly by a different programmer (for a multi-programmer project).&lt;br /&gt;&lt;hr size="4" /&gt;&lt;a href="http://www.blogger.com/post-edit.g?blogID=21595493&amp;amp;postID=653830520898698556" name="what_is_a_library"&gt;&lt;span style="color: brown;"&gt;&lt;/span&gt;&lt;/a&gt;&lt;br /&gt;&lt;a href="http://www.blogger.com/post-edit.g?blogID=21595493&amp;amp;postID=653830520898698556" name="what_is_a_library"&gt;&lt;span style="color: brown;"&gt;&lt;/span&gt;&lt;/a&gt;&lt;br /&gt;&lt;a href="http://www.blogger.com/post-edit.g?blogID=21595493&amp;amp;postID=653830520898698556" name="what_is_a_library"&gt;&lt;span style="color: brown;"&gt;&lt;/span&gt;&lt;/a&gt;&lt;br /&gt;&lt;a href="http://www.blogger.com/post-edit.g?blogID=21595493&amp;amp;postID=653830520898698556" name="what_is_a_library"&gt;&lt;span style="color: brown;"&gt;&lt;h2&gt;What Is A "C" Library? What Is It Good For?&lt;/h2&gt;&lt;/span&gt;&lt;/a&gt;One of the tools that compilers supply us with are libraries. A library is a file containing several object files, that can be used as a single entity in a linking phase of a program. Normally the library is indexed, so it is easy to find symbols (functions, variables and so on) in them. For this reason, linking a program whose object files are ordered in libraries is faster than linking a program whose object files are separate on the disk. Also, when using a library, we have fewer files to look for and open, which even further speeds up linking.&lt;br /&gt;Unix systems (as well as most other modern systems) allow us to create and use two kinds of libraries - static libraries and shared (or dynamic) libraries.&lt;br /&gt;Static libraries are just collections of object files that are linked into the program during the linking phase of compilation, and are not relevant during runtime. This last comment seems obvious, as we already know that object files are also used only during the linking phase, and are not required during runtime - only the program's executable file is needed in order to run the program.&lt;br /&gt;Shared libraries (also called dynamic libraries) are linked into the program in two stages. First, during compile time, the linker verifies that all the symbols (again, functions, variables and the like) required by the program, are either linked into the program, or in one of its shared libraries. However, the object files from the dynamic library are not inserted into the executable file. Instead, when the program is started, a program in the system (called a dynamic loader) checks out which shared libraries were linked with the program, loads them to memory, and attaches them to the copy of the program in memory.&lt;br /&gt;The complex phase of dynamic loading makes launching the program slightly slower, but this is a very insignificant drawback, that is out-weighted by a great advantage - if a second program linked with the same shared library is executed, it can use the same copy of the shared library, thus saving a lot of memory. For example, the standard "C" library is normally a shared library, and is used by all C programs. Yet, only one copy of the library is stored in memory at any given time. This means we can use far less memory to run our programs, and the executable files are much smaller, thus saving a lot of disk space as well.&lt;br /&gt;However, there is one drawback to this arrangement. If we re-compile the dynamic library and try to run a second copy of our program with the new library, we'll soon get stuck - the dynamic loader will find that a copy of the library is already stored in memory, and thus will attach it to our program, and not load the new (modified) version from disk. There are ways around this too, as we'll see in the last section of our discussion.&lt;br /&gt;&lt;hr size="4" /&gt;&lt;a href="http://www.blogger.com/post-edit.g?blogID=21595493&amp;amp;postID=653830520898698556" name="creating_static_archive"&gt;&lt;span style="color: brown;"&gt;&lt;/span&gt;&lt;/a&gt;&lt;br /&gt;&lt;a href="http://www.blogger.com/post-edit.g?blogID=21595493&amp;amp;postID=653830520898698556" name="creating_static_archive"&gt;&lt;span style="color: brown;"&gt;&lt;/span&gt;&lt;/a&gt;&lt;br /&gt;&lt;a href="http://www.blogger.com/post-edit.g?blogID=21595493&amp;amp;postID=653830520898698556" name="creating_static_archive"&gt;&lt;span style="color: brown;"&gt;&lt;/span&gt;&lt;/a&gt;&lt;br /&gt;&lt;span style="color: brown;"&gt;&lt;h2&gt;Creating A Static "C" Library Using "ar" and "ranlib"&lt;/h2&gt;&lt;/span&gt;The basic tool used to create static libraries is a program called&amp;nbsp;&lt;code&gt;'ar'&lt;/code&gt;, for 'archiver'. This program can be used to create static libraries (which are actually archive files), modify object files in the static library, list the names of object files in the library, and so on. In order to create a static library, we can use a command like this:&lt;br /&gt;&lt;br /&gt;&lt;code&gt;ar rc libutil.a util_file.o util_net.o util_math.o&amp;nbsp;&lt;/code&gt;&lt;br /&gt;&lt;br /&gt;This command creates a static library named 'libutil.a' and puts copies of the object files "util_file.o", "util_net.o" and "util_math.o" in it. If the library file already exists, it has the object files added to it, or replaced, if they are newer than those inside the library. The&amp;nbsp;&lt;code&gt;'c'&lt;/code&gt;&amp;nbsp;flag tells ar to create the library if it doesn't already exist. The&amp;nbsp;&lt;code&gt;'r'&lt;/code&gt;&amp;nbsp;flag tells it to replace older object files in the library, with the new object files.&lt;br /&gt;After an archive is created, or modified, there is a need to index it. This index is later used by the compiler to speed up symbol-lookup inside the library, and to make sure that the order of the symbols in the library won't matter during compilation (this will be better understood when we take a deeper look at the link process at the end of this tutorial). The command used to create or update the index is called&amp;nbsp;&lt;code&gt;'ranlib'&lt;/code&gt;, and is invoked as follows:&lt;br /&gt;&lt;br /&gt;&lt;code&gt;ranlib libutil.a&amp;nbsp;&lt;/code&gt;&lt;br /&gt;&lt;br /&gt;On some systems, the archiver (which is not always&amp;nbsp;&lt;code&gt;ar&lt;/code&gt;) already takes care of the index, so ranlib is not needed (for example, when Sun's C compiler creates an archive, it is already indexed). However, because&amp;nbsp;&lt;code&gt;'ar'&lt;/code&gt;&amp;nbsp;and&amp;nbsp;&lt;code&gt;'ranlib'&lt;/code&gt;&amp;nbsp;are used by many makefiles for many packages, such platforms tend to supply a ranlib command that does nothing. This helps using the same makefile on both types of platforms.&lt;br /&gt;&lt;em&gt;Note&lt;/em&gt;: when an archive file's index generation date (stored inside the archive file) is older than the file's last modification date (stored in the file system), a compiler trying to use this library will complain its index is out of date, and abort. There are two ways to overcome the problem:&lt;br /&gt;&lt;ol&gt;&lt;li&gt;Use&amp;nbsp;&lt;code&gt;'ranlib'&lt;/code&gt;&amp;nbsp;to re-generate the index.&lt;/li&gt;&lt;li&gt;When copying the archive file to another location, use&amp;nbsp;&lt;code&gt;'cp -p'&lt;/code&gt;, instead of only&amp;nbsp;&lt;code&gt;'cp'&lt;/code&gt;. The&amp;nbsp;&lt;code&gt;'-p'&lt;/code&gt;&amp;nbsp;flag tells&amp;nbsp;&lt;code&gt;'cp'&lt;/code&gt;&amp;nbsp;to keep all attributes of the file, including its access permissions, owner (if "cp" is invoked by a superuser) and its last modification date. This will cause the compiler to think the index inside the file is still updated. This method is useful for makefiles that need to copy the library to another directory for some reason.&lt;/li&gt;&lt;/ol&gt;&lt;br /&gt;&lt;hr size="4" /&gt;&lt;a href="http://www.blogger.com/post-edit.g?blogID=21595493&amp;amp;postID=653830520898698556" name="using_static_archive"&gt;&lt;span style="color: brown;"&gt;&lt;/span&gt;&lt;/a&gt;&lt;br /&gt;&lt;a href="http://www.blogger.com/post-edit.g?blogID=21595493&amp;amp;postID=653830520898698556" name="using_static_archive"&gt;&lt;span style="color: brown;"&gt;&lt;/span&gt;&lt;/a&gt;&lt;br /&gt;&lt;a href="http://www.blogger.com/post-edit.g?blogID=21595493&amp;amp;postID=653830520898698556" name="using_static_archive"&gt;&lt;span style="color: brown;"&gt;&lt;/span&gt;&lt;/a&gt;&lt;br /&gt;&lt;span style="color: brown;"&gt;&lt;h2&gt;Using A "C" Library In A Program&lt;/h2&gt;&lt;/span&gt;After we created our archive, we want to use it in a program. This is done by adding the library's name to the list of object file names given to the linker, using a special flag, normally&amp;nbsp;&lt;code&gt;'-l'&lt;/code&gt;. Here is an example:&lt;br /&gt;&lt;br /&gt;&lt;code&gt;cc main.o -L. -lutil -o prog&amp;nbsp;&lt;/code&gt;&lt;br /&gt;&lt;br /&gt;This will create a program using object file "main.o", and any symbols it requires from the "util" static library. Note that we omitted the "lib" prefix and the ".a" suffix when mentioning the library on the link command. The linker attaches these parts back to the name of the library to create a name of a file to look for. Note also the usage of the&amp;nbsp;&lt;code&gt;'-L'&lt;/code&gt;&amp;nbsp;flag - this flag tells the linker that libraries might be found in the given directory ('.', refering to the current directory), in addition to the standard locations where the compiler looks for system libraries.&lt;br /&gt;For an example of program that uses a static library, try looking at our&amp;nbsp;&lt;a href="http://www.blogger.com/static-lib"&gt;static library example directory&lt;/a&gt;.&lt;br /&gt;&lt;hr size="4" /&gt;&lt;a href="http://www.blogger.com/post-edit.g?blogID=21595493&amp;amp;postID=653830520898698556" name="creating_shared_library"&gt;&lt;span style="color: brown;"&gt;&lt;/span&gt;&lt;/a&gt;&lt;br /&gt;&lt;a href="http://www.blogger.com/post-edit.g?blogID=21595493&amp;amp;postID=653830520898698556" name="creating_shared_library"&gt;&lt;span style="color: brown;"&gt;&lt;/span&gt;&lt;/a&gt;&lt;br /&gt;&lt;a href="http://www.blogger.com/post-edit.g?blogID=21595493&amp;amp;postID=653830520898698556" name="creating_shared_library"&gt;&lt;span style="color: brown;"&gt;&lt;/span&gt;&lt;/a&gt;&lt;br /&gt;&lt;span style="color: brown;"&gt;&lt;h2&gt;Creating A Shared "C" Library Using "ld"&lt;/h2&gt;&lt;/span&gt;The creation of a shared library is rather similar to the creation of a static library. Compile a list of object files, then insert them all into a shared library file. However, there are two major differences:&lt;br /&gt;&lt;ol&gt;&lt;li&gt;&lt;u&gt;Compile for "Position Independent Code" (PIC)&lt;/u&gt;&amp;nbsp;- When the object files are generated, we have no idea where in memory they will be inserted in a program that will use them. Many different programs may use the same library, and each load it into a different memory in address. Thus, we need that all jump calls ("goto", in assembly speak) and subroutine calls will use relative addresses, and not absolute addresses. Thus, we need to use a compiler flag that will cause this type of code to be generated.&lt;br /&gt;In most compilers, this is done by specifying&amp;nbsp;&lt;code&gt;'-fPIC'&lt;/code&gt;&amp;nbsp;or&amp;nbsp;&lt;code&gt;'-fpic'&lt;/code&gt;&amp;nbsp;on the compilation command.&lt;/li&gt;&lt;li&gt;&lt;u&gt;Library File Creation&lt;/u&gt;&amp;nbsp;- unlike a static library, a shared library is not an archive file. It has a format that is specific to the architecture for which it is being created. Thus, we need to use the compiler (either the compiler's driver, or its linker) to generate the library, and tell it that it should create a shared library, not a final program file.&lt;br /&gt;This is done by using the&amp;nbsp;&lt;code&gt;'-G'&lt;/code&gt;&amp;nbsp;flag with some compilers, or the&amp;nbsp;&lt;code&gt;'-shared'&lt;/code&gt;&amp;nbsp;flag with other compilers.&lt;/li&gt;&lt;/ol&gt;&lt;br /&gt;Thus, the set of commands we will use to create a shared library, would be something like this:&lt;br /&gt;&lt;pre&gt;&lt;code&gt;&lt;br /&gt;cc -fPIC -c util_file.c&lt;br /&gt;cc -fPIC -c util_net.c&lt;br /&gt;cc -fPIC -c util_math.c&lt;br /&gt;cc -shared libutil.so util_file.o util_net.o util_math.o&lt;br /&gt;&lt;/code&gt;&lt;/pre&gt;&lt;br /&gt;The first three commands compile the source files with the&amp;nbsp;&lt;code&gt;PIC&lt;/code&gt;&amp;nbsp;option, so they will be suitable for use in a shared library (they may still be used in a program directly, even thought they were compiled with&amp;nbsp;&lt;code&gt;PIC&lt;/code&gt;). The last command asks the compiler to generate a shared library&lt;br /&gt;&lt;hr size="4" /&gt;&lt;a href="http://www.blogger.com/post-edit.g?blogID=21595493&amp;amp;postID=653830520898698556" name="using_shared_library"&gt;&lt;span style="color: brown;"&gt;&lt;/span&gt;&lt;/a&gt;&lt;br /&gt;&lt;a href="http://www.blogger.com/post-edit.g?blogID=21595493&amp;amp;postID=653830520898698556" name="using_shared_library"&gt;&lt;span style="color: brown;"&gt;&lt;/span&gt;&lt;/a&gt;&lt;br /&gt;&lt;a href="http://www.blogger.com/post-edit.g?blogID=21595493&amp;amp;postID=653830520898698556" name="using_shared_library"&gt;&lt;span style="color: brown;"&gt;&lt;/span&gt;&lt;/a&gt;&lt;br /&gt;&lt;span style="color: brown;"&gt;&lt;h2&gt;Using A Shared "C" Library - Quirks And Solutions&lt;/h2&gt;&lt;/span&gt;Using a shared library is done in two steps:&lt;br /&gt;&lt;ol&gt;&lt;li&gt;&lt;u&gt;Compile Time&lt;/u&gt;&amp;nbsp;- here we need to tell the linker to scan the shared library while building the executable program, so it will be convinced that no symbols are missing. It will not really take the object files from the shared library and insert them into the program.&lt;/li&gt;&lt;li&gt;&lt;u&gt;Run Time&lt;/u&gt;&amp;nbsp;- when we run the program, we need to tell the system's dynamic loader (the process in charge of automatically loading and linking shared libraries into the running process) where to find our shared library.&lt;/li&gt;&lt;/ol&gt;&lt;br /&gt;The compilation part is easy. It is done almost the same as when linking with static libraries:&lt;br /&gt;&lt;br /&gt;&lt;code&gt;cc main.o -L. -lutil -o prog&amp;nbsp;&lt;/code&gt;&lt;br /&gt;&lt;br /&gt;The linker will look for the file 'libutil.so' (&lt;code&gt;-lutil&lt;/code&gt;) in the current directory (&lt;code&gt;-L.&lt;/code&gt;), and link it to the program, but will not place its object files inside the resulting executable file, 'prog'.&lt;br /&gt;The run-time part is a little trickier. Normally, the system's dynamic loader looks for shared libraries in some system specified directories (such as /lib, /usr/lib, /usr/X11/lib and so on). When we build a new shared library that is not part of the system, we can use the&amp;nbsp;&lt;code&gt;'LD_LIBRARY_PATH'&lt;/code&gt;&amp;nbsp;environment variable to tell the dynamic loader to look in other directories. The way to do that depends on the type of shell we use ('tcsh' and 'csh', versus 'sh', 'bash', 'ksh' and similar shells), as well as on whether or not&amp;nbsp;&lt;code&gt;'LD_LIBRARY_PATH'&lt;/code&gt;&amp;nbsp;is already defined. To check if you have this variable defined, try:&lt;br /&gt;&lt;br /&gt;&lt;code&gt;echo $LD_LIBRARY_PATH&amp;nbsp;&lt;/code&gt;&lt;br /&gt;&lt;br /&gt;If you get a message such as&amp;nbsp;&lt;code&gt;'LD_LIBRARY_PATH: Undefined variable.'&lt;/code&gt;, then it is not defined.&lt;br /&gt;Here is how to define this variable, in all four cases:&lt;br /&gt;&lt;ol&gt;&lt;li&gt;'tcsh' or 'csh',&amp;nbsp;&lt;code&gt;LD_LIBRARY_PATH&lt;/code&gt;&amp;nbsp;is not defined:&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;pre&gt;&lt;code&gt;&lt;br /&gt;    setenv LD_LIBRARY_PATH /full/path/to/library/directory&lt;br /&gt;    &lt;/code&gt;&lt;/pre&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;/li&gt;&lt;li&gt;'tcsh' or 'csh',&amp;nbsp;&lt;code&gt;LD_LIBRARY_PATH&lt;/code&gt;&amp;nbsp;already defined:&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;pre&gt;&lt;code&gt;&lt;br /&gt;    setenv LD_LIBRARY_PATH /full/path/to/library/directory:${LD_LIBRARY_PATH}&lt;br /&gt;    &lt;/code&gt;&lt;/pre&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;/li&gt;&lt;li&gt;'sh', 'bash' and similar,&amp;nbsp;&lt;code&gt;LD_LIBRARY_PATH&lt;/code&gt;&amp;nbsp;is not defined:&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;pre&gt;&lt;code&gt;&lt;br /&gt;    LD_LIBRARY_PATH=/full/path/to/library/directory&lt;br /&gt;    export LD_LIBRARY_PATH&lt;br /&gt;    &lt;/code&gt;&lt;/pre&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;/li&gt;&lt;li&gt;'sh', 'bash' and similar,&amp;nbsp;&lt;code&gt;LD_LIBRARY_PATH&lt;/code&gt;&amp;nbsp;already defined:&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;pre&gt;&lt;code&gt;&lt;br /&gt;    LD_LIBRARY_PATH=/full/path/to/library/directory:${LD_LIBRARY_PATH}&lt;br /&gt;    export LD_LIBRARY_PATH&lt;br /&gt;    &lt;/code&gt;&lt;/pre&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;/li&gt;&lt;/ol&gt;&lt;br /&gt;After you've defined&amp;nbsp;&lt;code&gt;LD_LIBRARY_PATH&lt;/code&gt;, you can check if the system locates the library properly for a given program linked with this library:&lt;br /&gt;&lt;br /&gt;&lt;code&gt;ldd prog&amp;nbsp;&lt;/code&gt;&lt;br /&gt;&lt;br /&gt;You will get a few lines, each listing a library name on the left, and a full path to the library on the right. If a library is not found in any of the system default directories, or the directories mentioned in&amp;nbsp;&lt;code&gt;'LD_LIBRARY_PATH'&lt;/code&gt;, you will get a 'library not found' message. In such a case, verify that you properly defined the path to the directory inside&amp;nbsp;&lt;code&gt;'LD_LIBRARY_PATH'&lt;/code&gt;, and fix it, if necessary. If all goes well, you can run your program now like running any other program, and see it role...&lt;br /&gt;For an example of a program that uses a shared library, try looking at our&amp;nbsp;&lt;a href="http://www.blogger.com/shared-lib"&gt;shared library example directory&lt;/a&gt;.&lt;br /&gt;&lt;hr size="4" /&gt;&lt;a href="http://www.blogger.com/post-edit.g?blogID=21595493&amp;amp;postID=653830520898698556" name="using_shared_library_dynamically"&gt;&lt;span style="color: brown;"&gt;&lt;/span&gt;&lt;/a&gt;&lt;br /&gt;&lt;a href="http://www.blogger.com/post-edit.g?blogID=21595493&amp;amp;postID=653830520898698556" name="using_shared_library_dynamically"&gt;&lt;span style="color: brown;"&gt;&lt;/span&gt;&lt;/a&gt;&lt;br /&gt;&lt;a href="http://www.blogger.com/post-edit.g?blogID=21595493&amp;amp;postID=653830520898698556" name="using_shared_library_dynamically"&gt;&lt;span style="color: brown;"&gt;&lt;/span&gt;&lt;/a&gt;&lt;br /&gt;&lt;span style="color: brown;"&gt;&lt;h3&gt;Using A Shared "C" Library Dynamically - Programming Interface&lt;/h3&gt;&lt;/span&gt;One of the less-commonly used feature of shared libraries is the ability to link them to a process anytime during its life. The linking method we showed earlier makes the shared library automatically loaded by the dynamic loader of the system. Yet, it is possible to make a linking operation at any other time, using the 'dl' library. This library provides us with a means to load a shared library, reference any of its symbols, call any of its functions, and finally detach it from the process when no longer needed.&lt;br /&gt;Here is a scenario where this might be appealing: suppose that we wrote an application that needs to be able to read files created by different word processors. Normally, our program might need to be able to read tens of different file formats, but in a single run, it is likely that only one or two such document formats will be needed. We could write one shared library for each such format, all having the same interface (&lt;u&gt;readfile&lt;/u&gt;&amp;nbsp;and&amp;nbsp;&lt;u&gt;writefile&lt;/u&gt;&amp;nbsp;for example), and one piece of code that determines the file format. Thus, when our program is asked to open such a file, it will first determine its format, then load the relevant shared library that can read and translate that format, and call its&amp;nbsp;&lt;u&gt;readfile&lt;/u&gt;&amp;nbsp;function to read the document. We might have tens of such libraries, but only one of them will be placed in memory at any given time, making our application use less system resources. It will also allow us to ship the application with a small set of supported file formats, and add new file formats without the need to replace the whole application, by simply sending the client an additional set of shared libraries.&lt;br /&gt;&lt;hr /&gt;&lt;a href="http://www.blogger.com/post-edit.g?blogID=21595493&amp;amp;postID=653830520898698556" name="shared_dlopen"&gt;&lt;span style="color: brown;"&gt;&lt;/span&gt;&lt;/a&gt;&lt;br /&gt;&lt;a href="http://www.blogger.com/post-edit.g?blogID=21595493&amp;amp;postID=653830520898698556" name="shared_dlopen"&gt;&lt;span style="color: brown;"&gt;&lt;/span&gt;&lt;/a&gt;&lt;br /&gt;&lt;a href="http://www.blogger.com/post-edit.g?blogID=21595493&amp;amp;postID=653830520898698556" name="shared_dlopen"&gt;&lt;span style="color: brown;"&gt;&lt;/span&gt;&lt;/a&gt;&lt;br /&gt;&lt;a href="http://www.blogger.com/post-edit.g?blogID=21595493&amp;amp;postID=653830520898698556" name="shared_dlopen"&gt;&lt;span style="color: brown;"&gt;&lt;h3&gt;Loading A Shared Library Using&amp;nbsp;&lt;code&gt;&lt;u&gt;dlopen()&lt;/u&gt;&lt;/code&gt;&lt;/h3&gt;&lt;/span&gt;&lt;/a&gt;In order to open and load the shared library, one should use the&amp;nbsp;&lt;code&gt;&lt;u&gt;dlopen()&lt;/u&gt;&lt;/code&gt;&amp;nbsp;function. It is used this way:&lt;br /&gt;&lt;pre&gt;&lt;code&gt;&lt;br /&gt;#include &lt;dlfcn.h&gt;      &lt;span style="color: brown;"&gt;/* defines dlopen(), etc.       */&lt;/span&gt;&lt;br /&gt;.&lt;br /&gt;.&lt;br /&gt;void* lib_handle;       &lt;span style="color: brown;"&gt;/* handle of the opened library */&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;lib_handle = dlopen("/full/path/to/library", RTLD_LAZY);&lt;br /&gt;if (!lib_handle) {&lt;br /&gt;    fprintf(stderr, "Error during dlopen(): %s\n", dlerror());&lt;br /&gt;    exit(1);&lt;br /&gt;}&lt;br /&gt;&lt;/dlfcn.h&gt;&lt;/code&gt;&lt;/pre&gt;&lt;br /&gt;The&amp;nbsp;&lt;code&gt;&lt;u&gt;dlopen()&lt;/u&gt;&lt;/code&gt;&amp;nbsp;function gets two parameters. One is the full path to the shared library. The other is a flag defining whether all symbols refered to by the library need to be checked immediatly, or only when used. In our case, we may use the lazy approach (&lt;code&gt;&lt;u&gt;RTLD_LAZY&lt;/u&gt;&lt;/code&gt;) of checking only when used. The function returns a pointer to the loaded library, that may later be used to reference symbols in the library. It will return&amp;nbsp;&lt;code&gt;&lt;u&gt;NULL&lt;/u&gt;&lt;/code&gt;&amp;nbsp;in case an error occured. In that case, we may use the&amp;nbsp;&lt;code&gt;&lt;u&gt;dlerror()&lt;/u&gt;&lt;/code&gt;&amp;nbsp;function to print out a human-readable error message, as we did here.&lt;br /&gt;&lt;hr /&gt;&lt;a href="http://www.blogger.com/post-edit.g?blogID=21595493&amp;amp;postID=653830520898698556" name="shared_dlsym"&gt;&lt;span style="color: brown;"&gt;&lt;/span&gt;&lt;/a&gt;&lt;br /&gt;&lt;a href="http://www.blogger.com/post-edit.g?blogID=21595493&amp;amp;postID=653830520898698556" name="shared_dlsym"&gt;&lt;span style="color: brown;"&gt;&lt;/span&gt;&lt;/a&gt;&lt;br /&gt;&lt;a href="http://www.blogger.com/post-edit.g?blogID=21595493&amp;amp;postID=653830520898698556" name="shared_dlsym"&gt;&lt;span style="color: brown;"&gt;&lt;/span&gt;&lt;/a&gt;&lt;br /&gt;&lt;a href="http://www.blogger.com/post-edit.g?blogID=21595493&amp;amp;postID=653830520898698556" name="shared_dlsym"&gt;&lt;span style="color: brown;"&gt;&lt;h3&gt;Calling Functions Dynamically Using&amp;nbsp;&lt;code&gt;&lt;u&gt;dlsym()&lt;/u&gt;&lt;/code&gt;&lt;/h3&gt;&lt;/span&gt;&lt;/a&gt;After we have a handle to a loaded shared library, we can find symbols in it, of both functions and variables. We need to define their types properly, and we need to make sure we made no mistakes. The compiler won't be able to check those declarations, so we should be extra carefull when typing them. Here is how to find the address of a function named 'readfile' that gets one string parameter, and returns a pointer to a&amp;nbsp;&lt;code&gt;&lt;u&gt;'struct local_file'&lt;/u&gt;&lt;/code&gt;&amp;nbsp;structure:&lt;br /&gt;&lt;hr width="40%" /&gt;&lt;pre&gt;&lt;code&gt;&lt;br /&gt;&lt;span style="color: brown;"&gt;/* first define a function pointer variable to hold the function's address */&lt;/span&gt;&lt;br /&gt;struct local_file* (*readfile)(const char* file_path);&lt;br /&gt;&lt;span style="color: brown;"&gt;/* then define a pointer to a possible error string */&lt;/span&gt;&lt;br /&gt;const char* error_msg;&lt;br /&gt;&lt;span style="color: brown;"&gt;/* finally, define a pointer to the returned file */&lt;/span&gt;&lt;br /&gt;struct local_file* a_file;&lt;br /&gt;&lt;br /&gt;&lt;span style="color: brown;"&gt;/* now locate the 'readfile' function in the library */&lt;/span&gt;&lt;br /&gt;readfile = dlsym(lib_handle, "readfile");&lt;br /&gt;&lt;br /&gt;&lt;span style="color: brown;"&gt;/* check that no error occured */&lt;/span&gt;&lt;br /&gt;error_msg = dlerror();&lt;br /&gt;if (error_msg) {&lt;br /&gt;    fprintf(stderr, "Error locating 'readfile' - %s\n", error_msg);&lt;br /&gt;    exit(1);&lt;br /&gt;}&lt;br /&gt;&lt;br /&gt;&lt;span style="color: brown;"&gt;/* finally, call the function, with a given file path */&lt;/span&gt;&lt;br /&gt;a_file = (*readfile)("hello.txt");&lt;br /&gt;&lt;/code&gt;&lt;/pre&gt;&lt;hr width="40%" /&gt;As you can see, errors might occur anywhere along the code, so we should be carefull to make extensive error checking. Surely, you'll also check that 'a_file' is not&amp;nbsp;&lt;code&gt;&lt;u&gt;NULL&lt;/u&gt;&lt;/code&gt;, after you call your function.&lt;br /&gt;&lt;hr /&gt;&lt;a href="http://www.blogger.com/post-edit.g?blogID=21595493&amp;amp;postID=653830520898698556" name="shared_dlclose"&gt;&lt;span style="color: brown;"&gt;&lt;/span&gt;&lt;/a&gt;&lt;br /&gt;&lt;a href="http://www.blogger.com/post-edit.g?blogID=21595493&amp;amp;postID=653830520898698556" name="shared_dlclose"&gt;&lt;span style="color: brown;"&gt;&lt;/span&gt;&lt;/a&gt;&lt;br /&gt;&lt;a href="http://www.blogger.com/post-edit.g?blogID=21595493&amp;amp;postID=653830520898698556" name="shared_dlclose"&gt;&lt;span style="color: brown;"&gt;&lt;/span&gt;&lt;/a&gt;&lt;br /&gt;&lt;a href="http://www.blogger.com/post-edit.g?blogID=21595493&amp;amp;postID=653830520898698556" name="shared_dlclose"&gt;&lt;span style="color: brown;"&gt;&lt;h3&gt;Unloading A Shared Library Using&amp;nbsp;&lt;code&gt;&lt;u&gt;dlclose()&lt;/u&gt;&lt;/code&gt;&lt;/h3&gt;&lt;/span&gt;&lt;/a&gt;The final step is to close down the library, to free the memory it occupies. This should only be done if we are not intending to use it soon. If we do - it is better to leave it open, since library loading takes time. To close down the library, we use something like this:&lt;br /&gt;&lt;br /&gt;&lt;code&gt;dlclose(lib_handle);&amp;nbsp;&lt;/code&gt;&lt;br /&gt;&lt;br /&gt;This will free down all resources taken by the library (in particular, the memory its executable code takes up).&lt;br /&gt;&lt;hr /&gt;&lt;a href="http://www.blogger.com/post-edit.g?blogID=21595493&amp;amp;postID=653830520898698556" name="shared_auto_funcs"&gt;&lt;span style="color: brown;"&gt;&lt;/span&gt;&lt;/a&gt;&lt;br /&gt;&lt;a href="http://www.blogger.com/post-edit.g?blogID=21595493&amp;amp;postID=653830520898698556" name="shared_auto_funcs"&gt;&lt;span style="color: brown;"&gt;&lt;/span&gt;&lt;/a&gt;&lt;br /&gt;&lt;a href="http://www.blogger.com/post-edit.g?blogID=21595493&amp;amp;postID=653830520898698556" name="shared_auto_funcs"&gt;&lt;span style="color: brown;"&gt;&lt;/span&gt;&lt;/a&gt;&lt;br /&gt;&lt;a href="http://www.blogger.com/post-edit.g?blogID=21595493&amp;amp;postID=653830520898698556" name="shared_auto_funcs"&gt;&lt;span style="color: brown;"&gt;&lt;h3&gt;Automatic Startup And Cleanup Functions&lt;/h3&gt;&lt;/span&gt;&lt;/a&gt;Finally, the dynamic loading library gives us the option of defining two special functions in each library, namely&amp;nbsp;&lt;code&gt;&lt;u&gt;_init&lt;/u&gt;&lt;/code&gt;&amp;nbsp;and&amp;nbsp;&lt;code&gt;&lt;u&gt;_fini&lt;/u&gt;&lt;/code&gt;. The&amp;nbsp;&lt;code&gt;&lt;u&gt;_init&lt;/u&gt;&lt;/code&gt;&amp;nbsp;function, if found, is invoked automatically when the library is opened, and before&amp;nbsp;&lt;code&gt;&lt;u&gt;dlopen()&lt;/u&gt;&lt;/code&gt;&amp;nbsp;returns. It may be used to invoke some startup code needed to initialize data structures used by the library, read configuration files, and so on.&lt;br /&gt;The&amp;nbsp;&lt;code&gt;&lt;u&gt;_fini&lt;/u&gt;&lt;/code&gt;&amp;nbsp;function is called when the library is closed using&amp;nbsp;&lt;code&gt;&lt;u&gt;dlclose()&lt;/u&gt;&lt;/code&gt;. It may be used to make cleanup operations required by the library (freeing data structures, closing files, etc.).&lt;br /&gt;For an example of a program that uses the 'dl' interface, try looking at our&amp;nbsp;&lt;a href="http://www.blogger.com/dynamic-shared"&gt;dynamic-shared library example directory&lt;/a&gt;.&lt;br /&gt;&lt;hr size="4" /&gt;&lt;a href="http://www.blogger.com/post-edit.g?blogID=21595493&amp;amp;postID=653830520898698556" name="deeper_linking_understanding"&gt;&lt;span style="color: brown;"&gt;&lt;/span&gt;&lt;/a&gt;&lt;br /&gt;&lt;a href="http://www.blogger.com/post-edit.g?blogID=21595493&amp;amp;postID=653830520898698556" name="deeper_linking_understanding"&gt;&lt;span style="color: brown;"&gt;&lt;/span&gt;&lt;/a&gt;&lt;br /&gt;&lt;a href="http://www.blogger.com/post-edit.g?blogID=21595493&amp;amp;postID=653830520898698556" name="deeper_linking_understanding"&gt;&lt;span style="color: brown;"&gt;&lt;/span&gt;&lt;/a&gt;&lt;br /&gt;&lt;a href="http://www.blogger.com/post-edit.g?blogID=21595493&amp;amp;postID=653830520898698556" name="deeper_linking_understanding"&gt;&lt;span style="color: brown;"&gt;&lt;h2&gt;Getting a Deeper Understanding - The Complete Linking Story&lt;/h2&gt;&lt;/span&gt;&lt;/a&gt;&lt;br /&gt;&lt;hr /&gt;&lt;a href="http://www.blogger.com/post-edit.g?blogID=21595493&amp;amp;postID=653830520898698556" name="link_order"&gt;&lt;span style="color: brown;"&gt;&lt;/span&gt;&lt;/a&gt;&lt;br /&gt;&lt;a href="http://www.blogger.com/post-edit.g?blogID=21595493&amp;amp;postID=653830520898698556" name="link_order"&gt;&lt;span style="color: brown;"&gt;&lt;/span&gt;&lt;/a&gt;&lt;br /&gt;&lt;a href="http://www.blogger.com/post-edit.g?blogID=21595493&amp;amp;postID=653830520898698556" name="link_order"&gt;&lt;span style="color: brown;"&gt;&lt;/span&gt;&lt;/a&gt;&lt;br /&gt;&lt;a href="http://www.blogger.com/post-edit.g?blogID=21595493&amp;amp;postID=653830520898698556" name="link_order"&gt;&lt;span style="color: brown;"&gt;&lt;h3&gt;The Importance Of Linking Order&lt;/h3&gt;&lt;/span&gt;&lt;/a&gt;In order to fully understand the way linking is done, and be able to overcome linking problems, we should bare in mind that the order in which we present the object files and the libraries to the linker, is the order in which the linker links them into the resulting binary file.&lt;br /&gt;The linker checks each file in turn. If it is an object file, it is being placed fully into the executable file. If it is a library, the linker checks to see if any symbols referenced (i.e. used) in the previous object files but not defined (i.e. contained) in them, are in the library. If such a symbol is found, the whole object file from the library that contains the symbol - is being added to the executable file. This process continues until all object files and libraries on the command line were processed.&lt;br /&gt;This process means that if library 'A' uses symbols in library 'B', then library 'A' has to appear on the link command before library 'B'. Otherwise, symbols might be missing - the linker never turns back to libraries it has already processed. If library 'B' also uses symbols found in library 'A' - then the only way to assure successful linking is to mention library 'A' on the link command again after library 'B', like this:&lt;br /&gt;&lt;br /&gt;&lt;code&gt;$(LD) ....... -lA -lB -lA&amp;nbsp;&lt;/code&gt;&lt;br /&gt;&lt;br /&gt;This means that linking will be slower (library 'A' will be processed twice). This also hints that one should try not to have such mutual dependencies between two libraries. If you have such dependencies - then either re-design your libraries' contents, or combine the two libraries into one larger library.&lt;br /&gt;Note that object files found on the command line are always fully included in the executable file, so the order of mentioning them does not really matter. Thus, a good rule is to always mention the libraries after all object files.&lt;br /&gt;&lt;hr /&gt;&lt;a href="http://www.blogger.com/post-edit.g?blogID=21595493&amp;amp;postID=653830520898698556" name="static_vs_dynamic"&gt;&lt;span style="color: brown;"&gt;&lt;/span&gt;&lt;/a&gt;&lt;br /&gt;&lt;a href="http://www.blogger.com/post-edit.g?blogID=21595493&amp;amp;postID=653830520898698556" name="static_vs_dynamic"&gt;&lt;span style="color: brown;"&gt;&lt;/span&gt;&lt;/a&gt;&lt;br /&gt;&lt;a href="http://www.blogger.com/post-edit.g?blogID=21595493&amp;amp;postID=653830520898698556" name="static_vs_dynamic"&gt;&lt;span style="color: brown;"&gt;&lt;/span&gt;&lt;/a&gt;&lt;br /&gt;&lt;a href="http://www.blogger.com/post-edit.g?blogID=21595493&amp;amp;postID=653830520898698556" name="static_vs_dynamic"&gt;&lt;span style="color: brown;"&gt;&lt;h3&gt;Static Linking Vs. Dynamic Linking&lt;/h3&gt;&lt;/span&gt;&lt;/a&gt;When we discussed static libraries we said that the linker will try to look for a file named 'libutil.a'. We lied. Before looking for such a file, it will look for a file named 'libutil.so' - as a shared library. Only if it cannot find a shared library, will it look for 'libutil.a' as a static library. Thus, if we have created two copies of the library, one static and one shared, the shared will be preferred. This can be overridden using some linker flags (&lt;code&gt;'-Wl,static'&lt;/code&gt;&amp;nbsp;with some linkers,&amp;nbsp;&lt;code&gt;'-Bstatic'&lt;/code&gt;&amp;nbsp;with other types of linkers. refer to the compiler's or the linker's manual for info about these flags).&lt;br /&gt;&lt;hr size="4" /&gt;&lt;div align="center"&gt;&lt;img alt="" height="40" src="http://users.actcom.co.il/~choo/lupg/images/lupg_toolbar.gif" usemap="#lupg_map" width="360" /&gt;&lt;map name="lupg_map"&gt;&amp;nbsp;&lt;/map&gt;&lt;br /&gt;[&lt;a href="http://users.actcom.co.il/~choo/lupg/index.html"&gt;LUPG Home&lt;/a&gt;] [&lt;a href="http://users.actcom.co.il/~choo/lupg/tutorials/index.html"&gt;Tutorials&lt;/a&gt;] [&lt;a href="http://users.actcom.co.il/~choo/lupg/related-material.html"&gt;Related Material&lt;/a&gt;] [&lt;a href="http://users.actcom.co.il/~choo/lupg/essays/index.html"&gt;Essays&lt;/a&gt;] [&lt;a href="http://users.actcom.co.il/~choo/lupg/project-ideas/index.html"&gt;Project Ideas&lt;/a&gt;] [&lt;a href="mailto:choo@actcom.co.il"&gt;Send Comments&lt;/a&gt;]&lt;br /&gt;&lt;img alt="" src="http://users.actcom.co.il/~choo/lupg/images/good_bar.gif" /&gt;&lt;br /&gt;&lt;/div&gt;This document is copyright (c) 1998-2002 by guy keren.&lt;br /&gt;&lt;br /&gt;The material in this document is provided AS IS, without any expressed or implied warranty, or claim of fitness for a particular purpose. Neither the author nor any contributers shell be liable for any damages incured directly or indirectly by using the material contained in this document.&lt;br /&gt;&lt;br /&gt;permission to copy this document (electronically or on paper, for personal or organization internal use) or publish it on-line is hereby granted, provided that the document is copied as-is, this copyright notice is preserved, and a link to the original document is written in the document's body, or in the page linking to the copy of this document.&lt;br /&gt;&lt;br /&gt;Permission to make translations of this document is also granted, under these terms - assuming the translation preserves the meaning of the text, the copyright notice is preserved as-is, and a link to the original document is written in the document's body, or in the page linking to the copy of this document.&lt;br /&gt;&lt;br /&gt;For any questions about the document and its license, please&amp;nbsp;&lt;a href="mailto:choo@actcom.co.il"&gt;contact the author&lt;/a&gt;.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/21595493-653830520898698556?l=linux4research.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://linux4research.blogspot.com/feeds/653830520898698556/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=21595493&amp;postID=653830520898698556' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/21595493/posts/default/653830520898698556'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/21595493/posts/default/653830520898698556'/><link rel='alternate' type='text/html' href='http://linux4research.blogspot.com/2009/12/building-and-using-static-and-shared-c.html' title='Building And Using Static And Shared &quot;C&quot; Libraries'/><author><name>Dave</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-21595493.post-5416385922500189649</id><published>2009-12-14T08:46:00.002-06:00</published><updated>2010-05-25T22:06:02.422-05:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='Programming related'/><title type='text'>QString and number format.</title><content type='html'>Question: how to construct 0001.tif, 0002.tif, ..... and 0010.tif using QString?&lt;br /&gt;&lt;br /&gt;With C++, one can use sprintf to do this. sprintf(str, '%04d', i) where str is the output string, i is the iteration number (from 1 to 10). With QString, one can also use sprintf, but as the document mentions it is not the recommended way. Instead, using arg is better.&lt;br /&gt;&lt;br /&gt;Here is one example showing how to use arg to construct number format.&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;#include &amp;lt;_QtCore/QCoreApplication&amp;gt;&lt;br /&gt;#include &amp;lt;_QString&amp;gt;&lt;br /&gt;#include &amp;lt;_QDebug&amp;gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;int main(int argc, char *argv[])&lt;br /&gt;{&lt;br /&gt;&amp;nbsp;&amp;nbsp; &amp;nbsp;QCoreApplication a(argc, argv);&lt;br /&gt;&amp;nbsp;&amp;nbsp; &amp;nbsp;uint d = 90;&lt;br /&gt;&amp;nbsp;&amp;nbsp; &amp;nbsp;QString test("9 is %1");&lt;br /&gt;&amp;nbsp;&amp;nbsp; &amp;nbsp;const QChar fillChar = QLatin1Char('0');&lt;br /&gt;&amp;nbsp;&amp;nbsp; &amp;nbsp;QString testNew = test.arg(d, 5, 10, fillChar);&lt;br /&gt;&amp;nbsp;&amp;nbsp; &amp;nbsp;qDebug() &amp;lt;&amp;lt; "string is: " &amp;lt;&amp;lt; testNew;&lt;br /&gt;&lt;br /&gt;&amp;nbsp;&amp;nbsp; &amp;nbsp;return a.exec();&lt;br /&gt;}&lt;br /&gt;&lt;br /&gt;the output is:&lt;br /&gt;&lt;br /&gt;&lt;div style="-qt-block-indent: 0; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; text-indent: 0px;"&gt;&lt;!--StartFragment--&gt;string is:  "9 is 00090"&amp;nbsp;&lt;!--EndFragment--&gt;&lt;br /&gt;&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/21595493-5416385922500189649?l=linux4research.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://linux4research.blogspot.com/feeds/5416385922500189649/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=21595493&amp;postID=5416385922500189649' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/21595493/posts/default/5416385922500189649'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/21595493/posts/default/5416385922500189649'/><link rel='alternate' type='text/html' href='http://linux4research.blogspot.com/2009/12/qstring-and-number-format.html' title='QString and number format.'/><author><name>Dave</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-21595493.post-4050089872665488319</id><published>2009-10-21T09:38:00.000-05:00</published><updated>2010-05-25T22:06:02.422-05:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='Programming related'/><title type='text'>ffmpeg usage.</title><content type='html'>Using ffmpeg to make movies is much faster than using ImageJ. The followings are the commonly used commands:&lt;br /&gt;&lt;br /&gt;&amp;gt;&amp;gt; ffmpeg -r 60 -i %d.jpg -sameq -s vga out.mp4&lt;br /&gt;&lt;br /&gt;-r 60 means the frame rate of the movie is 60;&lt;br /&gt;-i %d.jpg: inputs are jpg sequences.&lt;br /&gt;-sameq: make sure that the movie frames are the same quality as the input sequential images.&lt;br /&gt;-s vga: constrains the size of the frames to vga size, which is 640x480.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/21595493-4050089872665488319?l=linux4research.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://linux4research.blogspot.com/feeds/4050089872665488319/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=21595493&amp;postID=4050089872665488319' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/21595493/posts/default/4050089872665488319'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/21595493/posts/default/4050089872665488319'/><link rel='alternate' type='text/html' href='http://linux4research.blogspot.com/2009/10/ffmpeg-usage.html' title='ffmpeg usage.'/><author><name>Dave</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-21595493.post-7786077893509225699</id><published>2009-10-18T11:05:00.001-05:00</published><updated>2010-05-25T22:06:02.423-05:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='Programming related'/><category scheme='http://www.blogger.com/atom/ns#' term='Mac'/><title type='text'>compile Qt4.6 on snow leopard.</title><content type='html'>I had trouble with the binary files, both 4.5 and 4.6Beta. The installer freezes at "validating packages". Finally I decided to compile the source files. The first trial failed with a lot of errors related with tiff files. Then I used the following command and successfully compiled the file.&lt;br /&gt;&lt;br /&gt;&amp;gt;&amp;gt; ./configure -qt-libtiff -sdk&lt;br /&gt;&lt;br /&gt;&amp;gt;&amp;gt; make&lt;br /&gt;&lt;br /&gt;&amp;gt;&amp;gt; sudo make install&lt;br /&gt;&lt;br /&gt;So far it seems to work well.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/21595493-7786077893509225699?l=linux4research.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://linux4research.blogspot.com/feeds/7786077893509225699/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=21595493&amp;postID=7786077893509225699' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/21595493/posts/default/7786077893509225699'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/21595493/posts/default/7786077893509225699'/><link rel='alternate' type='text/html' href='http://linux4research.blogspot.com/2009/10/compile-qt46-on-snow-leopard.html' title='compile Qt4.6 on snow leopard.'/><author><name>Dave</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-21595493.post-201111838675311318</id><published>2009-10-15T22:29:00.000-05:00</published><updated>2010-05-25T22:05:05.044-05:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='Mac'/><title type='text'>binutils on snow leopard</title><content type='html'>use the following when config:&lt;br /&gt;&lt;br /&gt;&amp;gt;&amp;gt; ./configure --disable-werror&lt;br /&gt;&lt;br /&gt;otherwise it won't work.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/21595493-201111838675311318?l=linux4research.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://linux4research.blogspot.com/feeds/201111838675311318/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=21595493&amp;postID=201111838675311318' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/21595493/posts/default/201111838675311318'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/21595493/posts/default/201111838675311318'/><link rel='alternate' type='text/html' href='http://linux4research.blogspot.com/2009/10/binutils-on-snow-leopard.html' title='binutils on snow leopard'/><author><name>Dave</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-21595493.post-2489245517882670361</id><published>2009-10-15T14:04:00.002-05:00</published><updated>2010-05-25T22:06:02.423-05:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='Programming related'/><category scheme='http://www.blogger.com/atom/ns#' term='Mac'/><title type='text'>compile openCV 2.0 on snow leopard</title><content type='html'>&lt;span style="font-family: georgia, 'times new roman', serif; font-size: 12px;"&gt;In the command window:&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family: georgia, 'times new roman', serif; font-size: small;"&gt;&lt;span class="Apple-style-span" style="font-size: 12px;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family: georgia, 'times new roman', serif; font-size: 12px;"&gt;&amp;gt;&amp;gt; CXXFLAGS="-m32"&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family: georgia, 'times new roman', serif; font-size: 12px;"&gt;&amp;gt;&amp;gt; &amp;nbsp;LDFLAGS="-m32"&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family: georgia, 'times new roman', serif; font-size: 12px;"&gt;&amp;gt;&amp;gt; &amp;nbsp;./configure&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family: georgia, 'times new roman', serif; font-size: small;"&gt;&lt;span class="Apple-style-span" style="font-size: 12px;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family: georgia, 'times new roman', serif; font-size: small;"&gt;&lt;span class="Apple-style-span" style="font-size: 12px;"&gt;After that, do the following:&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family: georgia, 'times new roman', serif; font-size: small;"&gt;&lt;span class="Apple-style-span" style="font-size: 12px;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family: georgia, 'times new roman', serif; font-size: small;"&gt;&lt;span class="Apple-style-span" style="font-size: 12px;"&gt;&amp;gt;&amp;gt; make&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family: georgia, 'times new roman', serif; font-size: small;"&gt;&lt;span class="Apple-style-span" style="font-size: 12px;"&gt;&amp;gt;&amp;gt; sudo make install (run as root).&amp;nbsp;&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family: georgia, 'times new roman', serif; font-size: small;"&gt;&lt;span class="Apple-style-span" style="font-size: 12px;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family: georgia, 'times new roman', serif; font-size: small;"&gt;&lt;span class="Apple-style-span" style="font-size: 12px;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/span&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/21595493-2489245517882670361?l=linux4research.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://linux4research.blogspot.com/feeds/2489245517882670361/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=21595493&amp;postID=2489245517882670361' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/21595493/posts/default/2489245517882670361'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/21595493/posts/default/2489245517882670361'/><link rel='alternate' type='text/html' href='http://linux4research.blogspot.com/2009/10/compile-opencv-20-on-snow-leopard.html' title='compile openCV 2.0 on snow leopard'/><author><name>Dave</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-21595493.post-8371304350508493022</id><published>2009-10-15T13:11:00.003-05:00</published><updated>2010-05-25T22:05:05.045-05:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='Mac'/><title type='text'>enable root account in Mac (10.6)</title><content type='html'>The easiest way to enable root is to start a terminal session, and type:&lt;br /&gt;&lt;pre style="color: red;"&gt;&lt;b&gt;sudo passwd root&lt;/b&gt;&lt;/pre&gt;You will be prompted for a new password to enable root access.&lt;br /&gt;&lt;br /&gt;If it does not work, following next steps:&lt;br /&gt;&lt;span class="Apple-style-span" style="font-family: 'Lucida Grande', 'Lucida Sans Unicode', Geneva, Verdana, Arial, sans-serif; font-size: 12px; line-height: 19px;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;ol style="list-style-image: initial; list-style-position: initial; list-style-type: decimal; margin-bottom: 1.5em; margin-left: 25px; margin-right: 0px; margin-top: 0.5em; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;"&gt;&lt;li style="margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;"&gt;Open the&amp;nbsp;&lt;strong&gt;Directory Utility&lt;/strong&gt;&amp;nbsp;located in&amp;nbsp;&lt;code style="font-style: normal; font-weight: normal;"&gt;/System/Library/CoreServices/&lt;/code&gt;.&lt;/li&gt;&lt;li style="margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;"&gt;Unlock the application by clicking the padlock icon and entering your Administrator login.&lt;/li&gt;&lt;li style="margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;"&gt;From the&amp;nbsp;&lt;strong&gt;Edit&lt;/strong&gt;&amp;nbsp;menu, select&amp;nbsp;&lt;strong&gt;Enable Root User&lt;/strong&gt;.&lt;/li&gt;&lt;li style="margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;"&gt;Chose&amp;nbsp;&lt;strong&gt;Change Root Password&lt;/strong&gt;&amp;nbsp;from the&amp;nbsp;&lt;strong&gt;Edit&lt;/strong&gt;&amp;nbsp;menu and chose a password for the root user.&lt;/li&gt;&lt;/ol&gt;&lt;div style="margin-bottom: 1.5em; margin-left: 0px; margin-right: 0px; margin-top: 0.5em; padding-bottom: 0px; padding-left: 0px; padding-right: 0px; padding-top: 0px;"&gt;That’s it! Make sure to&amp;nbsp;&lt;strong&gt;lock the application&amp;nbsp;&lt;/strong&gt;by clicking the padlock icon.&lt;br /&gt;&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/21595493-8371304350508493022?l=linux4research.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://linux4research.blogspot.com/feeds/8371304350508493022/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=21595493&amp;postID=8371304350508493022' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/21595493/posts/default/8371304350508493022'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/21595493/posts/default/8371304350508493022'/><link rel='alternate' type='text/html' href='http://linux4research.blogspot.com/2009/10/enable-root-account-in-mac-106.html' title='enable root account in Mac (10.6)'/><author><name>Dave</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-21595493.post-5446156044127673502</id><published>2009-10-12T00:38:00.001-05:00</published><updated>2010-05-25T22:06:02.423-05:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='Programming related'/><title type='text'>QLabel</title><content type='html'>when set the qlabel pixmap, use the following:&lt;br /&gt;&lt;br /&gt;&lt;div style="-qt-block-indent: 0; -qt-user-state: 512; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; text-indent: 0px;"&gt;&amp;nbsp;ui-&amp;gt;label-&amp;gt;setPixmap(QPixmap::fromImage(image));&lt;br /&gt;&lt;/div&gt;&lt;div style="-qt-block-indent: 0; -qt-user-state: 512; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; text-indent: 0px;"&gt;&lt;br /&gt;&lt;/div&gt;&lt;div style="-qt-block-indent: 0; -qt-user-state: 512; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; text-indent: 0px;"&gt;QPixmap::fromImage is a static function.&lt;br /&gt;&lt;/div&gt;&lt;div style="-qt-block-indent: 0; -qt-user-state: 512; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; text-indent: 0px;"&gt;&lt;br /&gt;&lt;/div&gt;&lt;div style="-qt-block-indent: 0; -qt-user-state: 512; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; text-indent: 0px;"&gt;The following codes do not seem to work:&lt;br /&gt;&lt;/div&gt;&lt;div style="-qt-block-indent: 0; -qt-user-state: 512; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; text-indent: 0px;"&gt;QPixmap pixmap;&lt;br /&gt;&lt;/div&gt;&lt;div style="-qt-block-indent: 0; -qt-user-state: 512; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; text-indent: 0px;"&gt;pixmap.fromImage(image);&lt;br /&gt;&lt;/div&gt;&lt;div style="-qt-block-indent: 0; -qt-user-state: 512; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px; text-indent: 0px;"&gt;ui-&amp;gt;label-&amp;gt;setPixmap(pixmap);&lt;br /&gt;&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/21595493-5446156044127673502?l=linux4research.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://linux4research.blogspot.com/feeds/5446156044127673502/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=21595493&amp;postID=5446156044127673502' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/21595493/posts/default/5446156044127673502'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/21595493/posts/default/5446156044127673502'/><link rel='alternate' type='text/html' href='http://linux4research.blogspot.com/2009/10/qlabel.html' title='QLabel'/><author><name>Dave</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-21595493.post-3617386409007658764</id><published>2009-10-07T21:37:00.001-05:00</published><updated>2010-05-25T22:05:05.045-05:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='Mac'/><title type='text'>How to Build Up a Bulleted List in Apple Keynote ’09</title><content type='html'>http://www.ehow.com/how_4929870_build-up-bulleted-list-keynote.html&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/21595493-3617386409007658764?l=linux4research.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://linux4research.blogspot.com/feeds/3617386409007658764/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=21595493&amp;postID=3617386409007658764' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/21595493/posts/default/3617386409007658764'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/21595493/posts/default/3617386409007658764'/><link rel='alternate' type='text/html' href='http://linux4research.blogspot.com/2009/10/how-to-build-up-bulleted-list-in-apple.html' title='How to Build Up a Bulleted List in Apple Keynote ’09'/><author><name>Dave</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-21595493.post-4684125214454100516</id><published>2009-09-30T16:11:00.001-05:00</published><updated>2009-09-30T16:11:28.308-05:00</updated><title type='text'>"arguments too long" error</title><content type='html'>http://en.wikipedia.org/wiki/Xargs&lt;br /&gt;&lt;br /&gt;Use xargs to deal with "arguments too long" error.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/21595493-4684125214454100516?l=linux4research.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://linux4research.blogspot.com/feeds/4684125214454100516/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=21595493&amp;postID=4684125214454100516' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/21595493/posts/default/4684125214454100516'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/21595493/posts/default/4684125214454100516'/><link rel='alternate' type='text/html' href='http://linux4research.blogspot.com/2009/09/arguments-too-long-error.html' title='&quot;arguments too long&quot; error'/><author><name>Dave</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-21595493.post-3148893548037607610</id><published>2009-09-29T22:01:00.000-05:00</published><updated>2009-09-29T22:01:34.564-05:00</updated><title type='text'>use python to manipulate large number of files in a directory.</title><content type='html'>When you have tons of files in a folder and want to manipulate them together, you will have trouble. For example if you use "mv" or "cp", you will get "Arguments are too long". You can use python to do this.&lt;br /&gt;&lt;br /&gt;here is how to do it.&lt;br /&gt;&lt;br /&gt;invoke python first.&lt;br /&gt;&lt;br /&gt;&amp;gt;&amp;gt;&amp;gt; import os, glob, shutil&lt;br /&gt;&amp;gt;&amp;gt;&amp;gt; for file in glob.glob('./directory1/*.tif'):&lt;br /&gt;&amp;nbsp;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; shutil.copy(file, './temp')&lt;br /&gt;&lt;br /&gt;this should work.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/21595493-3148893548037607610?l=linux4research.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://linux4research.blogspot.com/feeds/3148893548037607610/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=21595493&amp;postID=3148893548037607610' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/21595493/posts/default/3148893548037607610'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/21595493/posts/default/3148893548037607610'/><link rel='alternate' type='text/html' href='http://linux4research.blogspot.com/2009/09/use-python-to-manipulate-large-number.html' title='use python to manipulate large number of files in a directory.'/><author><name>Dave</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-21595493.post-6348566130912535962</id><published>2009-09-17T05:52:00.002-05:00</published><updated>2009-09-17T05:52:49.759-05:00</updated><title type='text'>debian (5.0) install more languages.</title><content type='html'>as root&lt;br /&gt;&lt;br /&gt;&amp;gt;&amp;gt; dpkg-reconfigure locales&lt;br /&gt;&lt;br /&gt;Use the above to install more locales.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/21595493-6348566130912535962?l=linux4research.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://linux4research.blogspot.com/feeds/6348566130912535962/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=21595493&amp;postID=6348566130912535962' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/21595493/posts/default/6348566130912535962'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/21595493/posts/default/6348566130912535962'/><link rel='alternate' type='text/html' href='http://linux4research.blogspot.com/2009/09/debian-50-install-more-languages.html' title='debian (5.0) install more languages.'/><author><name>Dave</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-21595493.post-5722985293310458689</id><published>2009-09-14T14:06:00.002-05:00</published><updated>2009-09-14T14:06:43.224-05:00</updated><title type='text'>Image processing libraries!</title><content type='html'>&lt;span class="Apple-style-span" style="font-family: Arial; font-size: 12px; line-height: 18px;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;div class="tit" style="-webkit-background-clip: initial; -webkit-background-origin: initial; background-attachment: initial; background-color: initial; background-image: url(http://.jpg/); background-position: 0% 0%; background-repeat: no-repeat; filter: none; font-family: Arial; font-size: 14px; font-weight: bold; height: 57px; line-height: 18px; overflow-x: hidden; overflow-y: hidden; text-indent: 58px; visibility: visible !important; word-break: break-all; word-wrap: break-word; zoom: 1 !important;"&gt;PL，IPP，openCV，ITK，VTK，visDSK（转）&lt;/div&gt;&lt;div class="date" style="color: black; filter: none; font-family: Arial; font-size: 12px; line-height: 18px; margin-bottom: 8px; margin-left: 0px; margin-right: 0px; margin-top: 5px; visibility: visible !important; word-break: break-all; word-wrap: break-word; zoom: 1 !important;"&gt;2009-03-02 09:18&lt;/div&gt;&lt;table style="table-layout: fixed; width: 709px;"&gt;&lt;tbody&gt;&lt;tr&gt;&lt;td style="filter: none; font-family: Arial; font-size: 12px; line-height: 18px; visibility: visible !important; word-break: break-all; word-wrap: break-word; zoom: 1 !important;"&gt;&lt;div class="cnt" id="blog_text" style="color: #542d24; filter: none; font-family: Arial; font-size: 14px; line-height: 20px; overflow-x: hidden; overflow-y: hidden; position: static; visibility: visible !important; word-break: normal; word-wrap: break-word; zoom: 1 !important;"&gt;&lt;div style="line-height: normal;"&gt;IPL---INTEL 图象处理库 免费 源代码不公开&lt;br style="line-height: normal;" /&gt;openCV--INTEL 图象处理库 免费 源代码公开&lt;br style="line-height: normal;" /&gt;IPP--IPP--INTEL 集成开发环境库（图象处理、信号处理等） 收费 源代码不公开&lt;br style="line-height: normal;" /&gt;visDSK---MICROSOFT 图象处理库 免费 源代码公开&lt;/div&gt;&lt;div style="line-height: normal;"&gt;ITK(Insight Segmentation and Registration ToolKit)提供了一个医学图像分割与配准的算法平台,它源于美国的可视人体项目(The Visual Human Project)[3]。同样地,ITK也支持跨平台开发,以开放源代码的形式发布,目前其稳定版本为1.6,提供了几乎所有主流的医学图像分割与配准算法。&lt;/div&gt;&lt;div style="line-height: normal;"&gt;VTK(The Visualization Toolkit)是美国Kitware公司的一个开放源码的自由软件(open source)。可以应用于图像处理、计算机图形学和科学计算可视化。它在科学计算可视化尤其是三维重建功能如面绘制和体绘制方面具有强大的功能,使其在可视化,尤其是在医学图像领域得到广泛应用。VTK完全采用面向对象的设计思想来设计与开发,提供了超过300个C++类,支持Window,Unix与Linux等多种平台,支持C,C++,Java,Tcl/Tk以及Python等编程语言,目前已发布的稳定版本是4.2。&lt;/div&gt;&lt;div style="line-height: normal;"&gt;&lt;a href="http://home.iitk.ac.in/%7Erksr/adisl.html" style="color: #4c4c4c; line-height: normal; text-decoration: none;" target="_blank"&gt;Advanced Digital Imaging Solutions Laboratory (ADISL)&lt;/a&gt;&lt;br style="line-height: normal;" /&gt;Image Apprentice is a C/C++ based Image Processing Learner’s Toolkit. Students use it as a companion to their favourite Image Processing Textbook. It allows one to use self-written image processing algorithms as plugins.&amp;nbsp;&lt;br style="line-height: normal;" /&gt;It comes with a Plugin Development Kit (PDK) that has a skeleton code having a simple coding style. A student who has attended a 101-level course in C/C++ programming is well-equipped to write an Image Processing plugin for Image Apprentice using Visual C++.&lt;/div&gt;&lt;div style="line-height: normal;"&gt;&lt;a href="http://www.uni-koblenz.de/%7Ejesus/asi/index.php" style="color: #4c4c4c; line-height: normal; text-decoration: none;" target="_blank"&gt;AllSeeingI&lt;/a&gt;&lt;br style="line-height: normal;" /&gt;AllSeeingI (ASI) is the codename for a computer vision and visualization framework. It is a visual programming environment for rapid development and easy reusability.&lt;/div&gt;&lt;div style="line-height: normal;"&gt;&lt;em style="line-height: normal;"&gt;Editor's Note - This project is just getting started but may be a chance for developers to contribute to a brand new vision system.&lt;/em&gt;&lt;/div&gt;&lt;div style="line-height: normal;"&gt;&lt;a href="http://www.cs.nott.ac.uk/%7Ejzg/nottsvision/index.html" style="color: #4c4c4c; line-height: normal; text-decoration: none;" target="_blank"&gt;CamCap and CLAG&lt;/a&gt;&lt;br style="line-height: normal;" /&gt;Links to the Nottingham video processing environment otherwise known collectively as CamCap, for camera and video processing work and CLAG, for command line based image processing/display and prototyping. The environment is windows based and makes use of DirectShow and the intel open source computer vision library (OpenCV).&lt;/div&gt;&lt;div style="line-height: normal;"&gt;&lt;a href="http://cimg.sourceforge.net/" style="color: #4c4c4c; line-height: normal; text-decoration: none;" target="_blank"&gt;CImg&lt;/a&gt;&lt;br style="line-height: normal;" /&gt;The CImg Library is an open source C++ toolkit for image processing. It provides simple classes and functions to load, save, process and display images in your own C++ code. CImg stands for "Cool Image" : It is simple to use and efficient. It's like a STL for image processing!&lt;/div&gt;&lt;div style="line-height: normal;"&gt;&lt;a href="http://www.cs.cmu.edu/%7Ejbruce/cmvision/" style="color: #4c4c4c; line-height: normal; text-decoration: none;" target="_blank"&gt;&lt;span style="color: purple; line-height: normal;"&gt;CMVision&lt;/span&gt;&lt;/a&gt;&lt;br style="line-height: normal;" /&gt;Project goal was to create a simple, robust vision system suitable for real time robotics applications. The system aims to perform global low level color vision at video rates without the use of special purpose harware.&lt;/div&gt;&lt;div style="line-height: normal;"&gt;&lt;a href="http://www.ee.siue.edu/CVIPtools/" style="color: #4c4c4c; line-height: normal; text-decoration: none;" target="_blank"&gt;&lt;span style="color: purple; line-height: normal;"&gt;CVIPtools&lt;/span&gt;&lt;/a&gt;&lt;br style="line-height: normal;" /&gt;One of the primary purposes of the CVIPtools development is to allow students, faculty, and other researchers to explore the power of computer processing of digital images.&amp;nbsp;&lt;br style="line-height: normal;" /&gt;The newest version of CVIPtools, version 4.3, developed at the Computer Vision and Image Processing Laboratory at Southern Illinois University at Edwardsville, under the continuing direction of Dr. Scott E Umbaugh is currently available with the new textbook, Computer Imaging: Digital Image Analysis and Processing.&lt;/div&gt;&lt;div style="line-height: normal;"&gt;&lt;a href="http://www.caip.rutgers.edu/riul/research/code/EDISON/index.html" style="color: #4c4c4c; line-height: normal; text-decoration: none;" target="_blank"&gt;EDISON&lt;/a&gt;&lt;br style="line-height: normal;" /&gt;Code for the Edge Detection and Image SegmentatiON system. This system is a low-level feature extraction tool that integrates confidence based edge detection and mean shift based image segmentation. It was developed by the Robust Image Understanding Laboratory at Rutgers University.&lt;/div&gt;&lt;div style="line-height: normal;"&gt;&lt;a href="http://filters.sourceforge.net/" style="color: #4c4c4c; line-height: normal; text-decoration: none;" target="_blank"&gt;FILTERS&lt;/a&gt;&lt;br style="line-height: normal;" /&gt;Filters is a library (not an application) implementing image filters and image processing functions.&lt;/div&gt;&lt;div style="line-height: normal;"&gt;&lt;a href="http://gandalf-library.sourceforge.net/tutorial/report/report.html" style="color: #4c4c4c; line-height: normal; text-decoration: none;" target="_blank"&gt;Gandalf&lt;/a&gt;&lt;br style="line-height: normal;" /&gt;The Fast Computer Vision and Numerical Library. Gandalf is a C library designed to support the development of computer vision applications.&amp;nbsp;&lt;a href="http://gwyddion.net/" style="color: #4c4c4c; line-height: normal; text-decoration: none;" target="_blank"&gt;Gwyddion&lt;/a&gt;&lt;br style="line-height: normal;" /&gt;Gwyddion is a modular program for SPM (scanning probe microscopy) data analysis. Primarily it is supposed to be used for analysis of height fields obtained by means of scanning probe microscopy techniques (AFM, MFM, STM, NSOM), but generally it can be used for any other height field analysis or image analysis.&lt;/div&gt;&lt;div style="line-height: normal;"&gt;&lt;a href="http://pippin.gimp.org/image_processing/index.html" style="color: #4c4c4c; line-height: normal; text-decoration: none;" target="_blank"&gt;Gluas&lt;/a&gt;&amp;nbsp;plus&amp;nbsp;&lt;a href="http://www.gimp.org/" style="color: #4c4c4c; line-height: normal; text-decoration: none;" target="_blank"&gt;GIMP - GNU Image Manipulation Program&lt;/a&gt;&lt;br style="line-height: normal;" /&gt;Gluas is a GIMP plug-in providing a enviroment for testing algorithms for image processing. The environment contains a simple editor for entering the algorithms. It uses the lua interpreter.&lt;/div&gt;&lt;div style="line-height: normal;"&gt;&lt;a href="http://www.wedesoft.demon.co.uk/hornetseye-api/index.html" style="color: #4c4c4c; line-height: normal; text-decoration: none;" target="_blank"&gt;Hornets Eye&lt;/a&gt;&lt;br style="line-height: normal;" /&gt;HornetsEye also is an attempt to trim down the Mimas library and create a minimalistic and consistent C++/Ruby real-time computer vision library with an interface to Ruby.&lt;/div&gt;&lt;div style="line-height: normal;"&gt;&lt;a href="http://ilab.usc.edu/toolkit/home.shtml" style="color: #4c4c4c; line-height: normal; text-decoration: none;" target="_blank"&gt;iLab Neuromorphic Vision C++ Toolkit (iNVT)&lt;/a&gt;&lt;br style="line-height: normal;" /&gt;The iLab Neuromorphic Vision C++ Toolkit is a comprehensive set of C++ classes for the development of neuromorphic models of vision. Neuromorphic models are computational neuroscience algorithms whose architecture and function is closely inspired from biological brains. The iLab Neuromorphic Vision C++ Toolkit comprises not only base classes for images, neurons, and brain areas, but also fully-developed models such as our model of bottom-up visual attention and of Bayesian surprise.&lt;/div&gt;&lt;div style="line-height: normal;"&gt;&lt;a href="http://www.tecgraf.puc-rio.br/im/" style="color: #4c4c4c; line-height: normal; text-decoration: none;" target="_blank"&gt;IM Toolkit&lt;/a&gt;&lt;br style="line-height: normal;" /&gt;Windows and UNIX - The idea behind IM was to create a toolkit that was not so complex as OpenCV, neither so big as VTK, but that can be used as a solid base to the development of thesis and dissertations, as for commercial applications.&lt;/div&gt;&lt;div style="line-height: normal;"&gt;&lt;a href="http://rsb.info.nih.gov/ij/" style="color: #4c4c4c; line-height: normal; text-decoration: none;" target="_blank"&gt;ImageJ&lt;/a&gt;&lt;br style="line-height: normal;" /&gt;ImageJ is a public domain Java image processing program inspired by NIH Image for the Macintosh. It runs, either as an online applet or as a downloadable application, on any computer with a Java 1.1 or later virtual machine. Downloadable distributions are available for Windows, Mac OS, Mac OS X and Linux.&lt;/div&gt;&lt;div style="line-height: normal;"&gt;&lt;em style="line-height: normal;"&gt;Editor's Note - This project is geared towards medical image analysis. If you need to analyze image cross-sections, break/create image stacks, then this package is worth some attention!&lt;/em&gt;&lt;/div&gt;&lt;div style="line-height: normal;"&gt;&lt;a href="http://sourceforge.net/projects/imlib3d/" style="color: #4c4c4c; line-height: normal; text-decoration: none;" target="_blank"&gt;ImLib3D&lt;/a&gt;&lt;br style="line-height: normal;" /&gt;ImLib3D is a C++ library and visualisation system for 3D image processing. It contains most basic image processing algorithms, and some more sophisticated ones. ImLib3D images are STL-compliant templated containers.&lt;/div&gt;&lt;div style="line-height: normal;"&gt;&lt;a href="http://www-prima.imag.fr/Imalab/" style="color: #4c4c4c; line-height: normal; text-decoration: none;" target="_blank"&gt;Imalab&lt;/a&gt;&lt;br style="line-height: normal;" /&gt;Imalab is a powerful development environment for complex applications in computer vision. It allows for flexible interactive experimentation with the vision modules developed in the Prima team, and can be dynamically extended with new modules. A versatile scripting mechanism provides for fast and convenient interactive development.&lt;/div&gt;&lt;div style="line-height: normal;"&gt;&lt;em style="line-height: normal;"&gt;Editor's Note - Most of the documentation is in French.&lt;/em&gt;&lt;/div&gt;&lt;div style="line-height: normal;"&gt;&lt;a href="http://www.tecgraf.puc-rio.br/%7Escuri/imlab/" style="color: #4c4c4c; line-height: normal; text-decoration: none;" target="_blank"&gt;IMLAB&lt;/a&gt;&lt;br style="line-height: normal;" /&gt;IMLAB is a free open source graphical application for Scientific Image Processing that runs in Windows, Linux and many other UNIX systems. It supports multiple windows, data types including 32 bit integers, 32 bit real numbers and complex numbers. It is implemented in C++ and also in C to provide a very simple way to add new functions. It has many image operations and supports several file formats.&lt;/div&gt;&lt;div style="line-height: normal;"&gt;&lt;a href="http://developer.intel.com/software/products/perflib/ipl/index.htm" style="color: #4c4c4c; line-height: normal; text-decoration: none;" target="_blank"&gt;IPL&lt;/a&gt;&lt;br style="line-height: normal;" /&gt;Intel® Integrated Performance Primitives (Intel® IPP) is a software library of highly optimized functions for multimedia, audio, video, speech, computer vision, image and signal processing.&lt;/div&gt;&lt;div style="line-height: normal;"&gt;&lt;a href="http://dpi.radiology.uiowa.edu/vida/image/improm/impman.html" style="color: #4c4c4c; line-height: normal; text-decoration: none;" target="_blank"&gt;IMPROMPTU&lt;/a&gt;&lt;br style="line-height: normal;" /&gt;IMPROMPTU, which stands for IMage PROcessing Module for the Prototyping, Testing, and Utilization of image analysis processes, is a software package for multi-dimensional image processing. With IMPROMPTU, a user can construct an arbitrary sequence of operations to run automatically on an input volume. This sequence, referred to as a process, can be made up of operations selected from any of several categories. Each category, which represents one general type of image-processing operation, contains a number of functions.&lt;/div&gt;&lt;div style="line-height: normal;"&gt;&lt;a href="http://www.jhlabs.com/ie/index.html" style="color: #4c4c4c; line-height: normal; text-decoration: none;" target="_blank"&gt;JHLabs&lt;/a&gt;&lt;br style="line-height: normal;" /&gt;Jerry's Java Image Processing Pages. A great way to explore many image processing filters by experimenting with Java applets.&amp;nbsp;&lt;br style="line-height: normal;" /&gt;&lt;a href="http://java.sun.com/products/java-media/jai/index.jsp" style="color: #4c4c4c; line-height: normal; text-decoration: none;" target="_blank"&gt;Java Advanced Imaging (JAI) API&lt;/a&gt;&lt;br style="line-height: normal;" /&gt;The Java Advanced Imaging API provides a set of object-oriented interfaces that support a simple, high-level programming model which lets you manipulate images easily.&lt;/div&gt;&lt;div style="line-height: normal;"&gt;&lt;a href="http://www.cmla.ens-cachan.fr/Cmla/Megawave/" style="color: #4c4c4c; line-height: normal; text-decoration: none;" target="_blank"&gt;MegaWave&lt;/a&gt;&lt;br style="line-height: normal;" /&gt;MegaWave2 is a free software intended for image processing. It is made of a C library of modules, that contains original algorithms written by researchers and a Unix/Linux package designed for the fast developpement of new image processing algorithms.&lt;/div&gt;&lt;div style="line-height: normal;"&gt;&lt;a href="http://www.leptonica.com/local-sources.html" style="color: #4c4c4c; line-height: normal; text-decoration: none;" target="_blank"&gt;Leptonica Library&lt;/a&gt;&lt;br style="line-height: normal;" /&gt;This site contains well-tested C code for some basic image processing operations, along with a description of the functions and some design methods. A full set of affine transformations (translation, shear, rotation, scaling) on images of all depths is included, with the exception that some of the scaling methods do not work at all depths. There are also implementations of binary morphology, grayscale morphology, convolution and rank order filters, and applications such as jbig2 image processing and color quantization.&lt;/div&gt;&lt;div style="line-height: normal;"&gt;&lt;a href="http://ltilib.sourceforge.net/doc/homepage/index.shtml" style="color: #4c4c4c; line-height: normal; text-decoration: none;" target="_blank"&gt;LTI-Lib&lt;/a&gt;&lt;br style="line-height: normal;" /&gt;The LTI-Lib is an object oriented library with algorithms and data structures frequently used in image processing and computer vision. It has been developed at the Chair of Technical Computer Science (Lehrstuhl fuer Technische Informatik) LTI at the Aachen University of Technology, as part of many research projects in computer vision dealing with robotics, object recognition and sign language and gesture recognition.&lt;/div&gt;&lt;div style="line-height: normal;"&gt;&lt;a href="http://www.nist.gov/lispix/doc/contents.htm" style="color: #4c4c4c; line-height: normal; text-decoration: none;" target="_blank"&gt;Lispix&lt;/a&gt;&lt;br style="line-height: normal;" /&gt;Lispix is a public domain image analysis program for Microsoft Windows (PC), written and maintained by&amp;nbsp;&lt;a href="http://www.nist.gov/lispix/dsb/dsb.html" style="color: #4c4c4c; line-height: normal; text-decoration: none;" target="_blank"&gt;David Bright&lt;/a&gt;. It features a collection of special purpose research tools for electron microscopy and spectral imaging at NIST. Most of Lispix is written in Common Lisp.&lt;/div&gt;&lt;div style="line-height: normal;"&gt;&lt;a href="http://www.op-fx.com/luamat/" style="color: #4c4c4c; line-height: normal; text-decoration: none;" target="_blank"&gt;LuaMat&lt;/a&gt;&lt;br style="line-height: normal;" /&gt;LuaMat aims to provide a easy to use language to create visual effects and to modify images. LuaMat is a fast way to use the most popular algorithms of Image Processing and Computer Vision. As Lua, becoming the standard for video-game scripting engines, LuaMat is fast and has a simple syntax.&lt;/div&gt;&lt;div style="line-height: normal;"&gt;&lt;a href="http://www.shu.ac.uk/mmvl/research/mimas/index.html" style="color: #4c4c4c; line-height: normal; text-decoration: none;" target="_blank"&gt;The Mimas toolkit&lt;/a&gt;&lt;br style="line-height: normal;" /&gt;Mimas was originally conceived as a platform for real-time machine vision research. Its aim was and still is to reduce the turnaround time of new research into the application workspace. It is written in C++ and is released in source code form subject to the GNU Lesser General Public License (LGPL).&lt;/div&gt;&lt;div style="line-height: normal;"&gt;&lt;a href="http://www.robin-hewitt.com/mavis/index.html" style="color: #4c4c4c; line-height: normal; text-decoration: none;" target="_blank"&gt;Mavis&lt;/a&gt;&lt;br style="line-height: normal;" /&gt;Mavis is computer vision software for mobile robots. It's part of an ongoing, group robotics project, called Leaf.&lt;/div&gt;&lt;div style="line-height: normal;"&gt;&lt;a href="http://bima.astro.umd.edu/miriad/" style="color: #4c4c4c; line-height: normal; text-decoration: none;" target="_blank"&gt;MIRIAD&lt;/a&gt;&lt;br style="line-height: normal;" /&gt;MIRIAD (Multichannel Image Reconstruction, Image Analysis and Display) is a toolbox, in the form of an environment with a large set of moderate-sized program which perform individual tasks, involving calibration, mapping, deconvolution and image analysis of interferometric data. MIRIAD software is also part of the Hat Creek telescope control software; data obtained from the telescopes is directly written into MIRIAD format with a MIRIAD user interface.&lt;/div&gt;&lt;div style="line-height: normal;"&gt;&lt;a href="http://www.lavrsen.dk/twiki/bin/view/Motion/WebHome" style="color: #4c4c4c; line-height: normal; text-decoration: none;" target="_blank"&gt;Motion&lt;/a&gt;&lt;br style="line-height: normal;" /&gt;Motion is a program that monitors the video signal from one or more cameras and is able to detect if a significant part of the picture has changed; in other words, it can detect motion.&lt;/div&gt;&lt;div style="line-height: normal;"&gt;&lt;a href="http://brneurosci.org/tnimage-manual/tnimage-manual.html" style="color: #4c4c4c; line-height: normal; text-decoration: none;" target="_blank"&gt;tnimage&lt;/a&gt;&lt;br style="line-height: normal;" /&gt;tnimage is a scientific image analysis program that allows you to create, edit, analyze, and produce color prints of images. It is particularly useful for analyzing images of SDS and agarose gels and X-ray or MRI images.&lt;/div&gt;&lt;div style="line-height: normal;"&gt;&lt;a href="http://www.neatvision.com/" style="color: #4c4c4c; line-height: normal; text-decoration: none;" target="_blank"&gt;&lt;span style="color: purple; line-height: normal;"&gt;NeatVision&lt;/span&gt;&lt;/a&gt;&lt;br style="line-height: normal;" /&gt;NeatVision is a free Java based image analysis and software development environment, which provides high level access to a wide range of image processing algorithms through well defined and easy to use graphical interface. NeatVision is in its second major release.&lt;/div&gt;&lt;div style="line-height: normal;"&gt;&lt;a href="http://rsb.info.nih.gov/nih-image/" style="color: #4c4c4c; line-height: normal; text-decoration: none;" target="_blank"&gt;NIH IMAGE&lt;/a&gt;&lt;br style="line-height: normal;" /&gt;NIH Image is a public domain image processing and analysis program for the Macintosh. It was developed at the Research Services Branch (RSB) of the National Institute of Mental Health (NIMH), part of the National Institutes of Health (NIH).&lt;/div&gt;&lt;div style="line-height: normal;"&gt;&lt;em style="line-height: normal;"&gt;Editor's Note - The NIH IMAGE project is similar to ImageJ. In fact they are documented side by side. ImageJ is recommended to be used by PC based users as NIH IMAGE is a Mac based program.&lt;/em&gt;&lt;/div&gt;&lt;div style="line-height: normal;"&gt;&lt;a href="http://www.intel.com/technology/computing/opencv/index.htm" style="color: #4c4c4c; line-height: normal; text-decoration: none;" target="_blank"&gt;OpenCV&lt;/a&gt;&lt;br style="line-height: normal;" /&gt;OpenCV is an extensive open-source image processing library, built on the Intel Image Processing Library (IPL). OpenCV aids commercial uses of computer vision in human-computer interface, robotics, monitoring, biometrics and security by providing a free and open infrastructure where the distributed efforts of the vision community can be consolidated and performance optimized.&lt;/div&gt;&lt;div style="line-height: normal;"&gt;&lt;a href="http://www.csse.uwa.edu.au/%7Epk/Research/MatlabFns/" style="color: #4c4c4c; line-height: normal; text-decoration: none;" target="_blank"&gt;Peter Kovesi Research&lt;/a&gt;&lt;br style="line-height: normal;" /&gt;MATLAB and Octave Functions for Computer Vision and Image Processing.&lt;/div&gt;&lt;div style="line-height: normal;"&gt;&lt;a href="http://www.cv.iit.nrc.ca/%7Egerhard/PVT/" style="color: #4c4c4c; line-height: normal; text-decoration: none;" target="_blank"&gt;Projective Vision Toolkit&lt;/a&gt;&lt;br style="line-height: normal;" /&gt;The Projective Vision Toolkit (PVT) is a series of utilities that allows one to take an image sequence and compute the fundamental matrix and trilinear tensor.&lt;br style="line-height: normal;" /&gt;This can be used for such problems as camera selfcalibration, structure from motion, camera motion annotation, image stabilization, 3D tracking and recognition, etc.&lt;/div&gt;&lt;div style="line-height: normal;"&gt;&lt;a href="http://ravl.sourceforge.net/" style="color: #4c4c4c; line-height: normal; text-decoration: none;" target="_blank"&gt;RAVL - Recognition And Vision Library&lt;/a&gt;&lt;br style="line-height: normal;" /&gt;RAVL provides a base C++ class library, together with a range of computer vision, pattern recognition and supporting tools. The aim of RAVL is to move software developed within the Centre for Vision, Speech and Signal Processing at the University of Surrey, England for research purposes into the public domain and to support its use in a wider community.&lt;/div&gt;&lt;div style="line-height: normal;"&gt;&lt;a href="http://www.roborealm.com/" style="color: #4c4c4c; line-height: normal; text-decoration: none;" target="_blank"&gt;RoboRealm&lt;/a&gt;&lt;br style="line-height: normal;" /&gt;Using RoboRealm you can create a low cost vision software solution with a standard webcam that allows you to explore the very complex world of image analysis and image processing. Through an easy to use analysis pipeline you can add image processing filters to translate an image into robotic movements, computer actions, or just plain fun! RoboRealm is free to&amp;nbsp;&lt;a href="http://www.roborealm.com/download.php" style="color: #4c4c4c; line-height: normal; text-decoration: none;"&gt;download&lt;/a&gt;!&lt;/div&gt;&lt;div style="line-height: normal;"&gt;&lt;a href="http://www.robotvision2.com/RvCAD.html" style="color: #4c4c4c; line-height: normal; text-decoration: none;" target="_blank"&gt;RobotVisionCAD&lt;/a&gt;&lt;br style="line-height: normal;" /&gt;RobotVisionCAD or in short RvCAD is a computer aided design for Image Processing and Computer Vision. RvCAD's GUI presents users with a view where users drag and drop Image Processor Elements, and visually connecting them to form Image Processing Pipeline. RvCAD supports real-time live video processing from VideoForWindow, DirectShow(WDM) and Video4Linux on linux, compatible capture device.&lt;/div&gt;&lt;div style="line-height: normal;"&gt;&lt;a href="http://www.wadsworth.org/spider_doc/spider/docs/spider.html" style="color: #4c4c4c; line-height: normal; text-decoration: none;" target="_blank"&gt;SPIDER&lt;/a&gt;&lt;br style="line-height: normal;" /&gt;SPIDER (System for Processing Image Data from Electron microscopy and Related fields) is an image processing system for electron microscopy.&lt;/div&gt;&lt;div style="line-height: normal;"&gt;&lt;a href="http://www.tina-vision.net/" style="color: #4c4c4c; line-height: normal; text-decoration: none;" target="_blank"&gt;TINA&lt;/a&gt;&lt;br style="line-height: normal;" /&gt;TINA (TINA Is No Acronym) is an open source environment developed to accelerate the process of image analysis research. TINA provides functionality to assist in all areas of image analysis including handling of image, image feature and geometrical data; statistical and numerical analysis of data; GUI development as well as transmission and containment of data. TINA also provides a range of high-level analysis techniques for both machine vision (3D object location, 2D object recognition, temporal-stereo depth estimation, etc) and medical image analysis (MR tissue segmentation, blood flow analysis, etc).&lt;/div&gt;&lt;div style="line-height: normal;"&gt;&lt;a href="http://www.cs.cmu.edu/%7Edst/Tekkotsu/Tutorial/" style="color: #4c4c4c; line-height: normal; text-decoration: none;" target="_blank"&gt;Tekkotsu&lt;/a&gt;&lt;br style="line-height: normal;" /&gt;Exploring Tekkotsu Programming on the Sony AIBO. Tekkotsu (see www.Tekkotsu.org) is an application development framework for the Sony AIBO robot dog. ("Tekkotsu" literally means iron bones in Japanese, and refers to a metal framework, such as the skeleton of a building.) At its lowest level, Tekkotsu provides primitives for sensory processing, smooth control of effectors, and event-based communication.&lt;/div&gt;&lt;div style="line-height: normal;"&gt;&lt;a href="http://www.idiap.ch/%7Emarcel/en/torch3/introduction.php" style="color: #4c4c4c; line-height: normal; text-decoration: none;" target="_blank"&gt;Torch3vision&lt;/a&gt;&lt;br style="line-height: normal;" /&gt;It's a machine vision library, written in simple C++ and based on the Torch machine-learning library. This package contains Basic image processing and feature extraction algorithms such as rotation, flip, photometric normalizations (Histogram Equalization, Multiscale Retinex, Self-Quotient Image or Gross-Brajovic), edge detection, 2D DCT, 2D FFT, 2D Gabor, PCA to do Eigen-Faces, LDA to do Fisher-Faces&lt;/div&gt;&lt;div style="line-height: normal;"&gt;&lt;a href="http://ddsdx.uthscsa.edu/dig/itdesc.html" style="color: #4c4c4c; line-height: normal; text-decoration: none;" target="_blank"&gt;UTHSCSA ImageTool&lt;/a&gt;&lt;br style="line-height: normal;" /&gt;UTHSCSA ImageTool (IT) is a free image processing and analysis program for Microsoft Windows 9x, Windows ME or Windows NT. IT can acquire, display, edit, analyze, process, compress, save and print gray scale and color images.IT can read and write over 22 common file formats including BMP, PCX, TIF, GIF and JPEG.&lt;/div&gt;&lt;div style="line-height: normal;"&gt;&lt;a href="http://vxl.sourceforge.net/" style="color: #4c4c4c; line-height: normal; text-decoration: none;" target="_blank"&gt;VXL&lt;/a&gt;&lt;br style="line-height: normal;" /&gt;VXL (the Vision-something-Libraries) is a collection of C++ libraries designed for computer vision research and implementation. It was created from TargetJr and the IUE with the aim of making a light, fast and consistent system. VXL is written in ANSI/ISO C++ and is designed to be portable over many platforms. There are libraries covering numerical algorithms, image processing, co-ordinate systems, camera geometry, stereo, video manipulation, structure recovery from motion, probability modelling, GUI design, classification, robust estimation, feature tracking, topology, structure manipulation, 3d imaging, and much more.&lt;/div&gt;&lt;div style="line-height: normal;"&gt;&lt;a href="http://amiserver.dis.ulpgc.es/xmwgus/" style="color: #4c4c4c; line-height: normal; text-decoration: none;" target="_blank"&gt;XMegaWave&lt;/a&gt;&lt;br style="line-height: normal;" /&gt;XMegaWave (XMW) is a freeware graphical windows environment oriented towards image processing. The development of XMW has been based on the collaboration between researchers from the University of the Balearic Islands (Spain), the University of Las Palmas de Gran Canaria (Spain) and the University of Paris IX Dauphine (France).&lt;/div&gt;&lt;div style="line-height: normal;"&gt;&lt;a href="http://www.cs.jhu.edu/CIPS/xvision/" style="color: #4c4c4c; line-height: normal; text-decoration: none;" target="_blank"&gt;XVision&lt;/a&gt;&lt;br style="line-height: normal;" /&gt;XVision provides an application independent set of tools for visual feature tracking optimized to be simple to configure at the user level, yet extremely fast to execute.&lt;/div&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;&lt;/tbody&gt;&lt;/table&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/21595493-5722985293310458689?l=linux4research.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://linux4research.blogspot.com/feeds/5722985293310458689/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=21595493&amp;postID=5722985293310458689' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/21595493/posts/default/5722985293310458689'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/21595493/posts/default/5722985293310458689'/><link rel='alternate' type='text/html' href='http://linux4research.blogspot.com/2009/09/image-processing-libraries.html' title='Image processing libraries!'/><author><name>Dave</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-21595493.post-3090983910649264242</id><published>2009-09-11T10:45:00.001-05:00</published><updated>2009-09-11T12:38:40.476-05:00</updated><title type='text'>Matlab memory management.</title><content type='html'>Here is the &lt;a href="http://www.mathworks.com/support/tech-notes/1100/1107.html"&gt;office site&lt;/a&gt; describing how to use memory efficiently with Matlab.&lt;br /&gt;One common pit is the following:&lt;br /&gt;&lt;br /&gt;&amp;gt;&amp;gt; a=rand(100e6,1);&lt;br /&gt;&lt;br /&gt;The above command will generate vector a; now if you want to generate another set of random numbers and store in a, you may think you just type in:&lt;br /&gt;&lt;br /&gt;&amp;gt;&amp;gt; a = rand(100e6, 1)&lt;br /&gt;&lt;br /&gt;This will not work!!!&lt;br /&gt;&lt;br /&gt;You need to do the following:&lt;br /&gt;&amp;gt;&amp;gt; a = rand(100e6, 1);&lt;br /&gt;&amp;gt;&amp;gt; clear;&lt;br /&gt;&amp;gt;&amp;gt; a= rand(100e6, 1);&lt;br /&gt;&lt;br /&gt;This way, basically you clear out the old variable "a" first, then you generate a new one and store it in a. Basically the biggest memory to use to allocate the variable is half of your memory in this case.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/21595493-3090983910649264242?l=linux4research.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://linux4research.blogspot.com/feeds/3090983910649264242/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=21595493&amp;postID=3090983910649264242' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/21595493/posts/default/3090983910649264242'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/21595493/posts/default/3090983910649264242'/><link rel='alternate' type='text/html' href='http://linux4research.blogspot.com/2009/09/matlab-memory-management.html' title='Matlab memory management.'/><author><name>Dave</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-21595493.post-1415914214188135418</id><published>2009-09-09T14:28:00.000-05:00</published><updated>2010-11-17T20:09:40.428-06:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='Mac'/><title type='text'>Mac keynote 2009 format.</title><content type='html'>&lt;span class="Apple-style-span" style="color: #000033; font-family: verdana, tahoma, helvetica, arial, sans-serif; font-size: 12px; line-height: 17px;"&gt;he new iWork '09 suite includes a new file format that packs all the data into a single file, rather than using a package bundle, as did iWork '08.&lt;/span&gt;&lt;br /&gt;&lt;span style="color: #000033; font-family: verdana, tahoma, helvetica, arial, sans-serif; font-size: small;"&gt;&lt;span class="Apple-style-span" style="font-size: 12px; line-height: 17px;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="color: #000033; font-family: verdana, tahoma, helvetica, arial, sans-serif; font-size: small;"&gt;&lt;span class="Apple-style-span" style="font-size: 12px; line-height: 17px;"&gt;To get the folder, just change the extension of the file from .key to .zip. Then you can just unzip it to a folder. Change back from .zip to .key will give you the intact keynote file.&amp;nbsp;&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="color: #000033; font-family: verdana, tahoma, helvetica, arial, sans-serif; font-size: small;"&gt;&lt;span class="Apple-style-span" style="font-size: 12px; line-height: 17px;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="color: #000033; font-family: verdana, tahoma, helvetica, arial, sans-serif; font-size: small;"&gt;&lt;span class="Apple-style-span" style="font-size: 12px; line-height: 17px;"&gt;To get the old formats back, simply go into Preferences in each iWork application, and under the General tab, check the box that says&amp;nbsp;&lt;em&gt;Save new documents as packages&lt;/em&gt;.&amp;nbsp;&lt;/span&gt;&lt;/span&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/21595493-1415914214188135418?l=linux4research.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://linux4research.blogspot.com/feeds/1415914214188135418/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=21595493&amp;postID=1415914214188135418' title='1 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/21595493/posts/default/1415914214188135418'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/21595493/posts/default/1415914214188135418'/><link rel='alternate' type='text/html' href='http://linux4research.blogspot.com/2009/09/mac-keynote-2009-format.html' title='Mac keynote 2009 format.'/><author><name>Dave</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>1</thr:total></entry><entry><id>tag:blogger.com,1999:blog-21595493.post-3659596167002332908</id><published>2009-05-18T19:49:00.002-05:00</published><updated>2009-05-18T19:52:13.660-05:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='tricks'/><title type='text'>Tricks to search emails in gmail.</title><content type='html'>To search all the unread emails:&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;In the search box, type "is:unread" without quotes. It will show you all the unread emails. By using "is:unread label:inbox", you will get all the unread emails in the inbox. &lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/21595493-3659596167002332908?l=linux4research.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://linux4research.blogspot.com/feeds/3659596167002332908/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=21595493&amp;postID=3659596167002332908' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/21595493/posts/default/3659596167002332908'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/21595493/posts/default/3659596167002332908'/><link rel='alternate' type='text/html' href='http://linux4research.blogspot.com/2009/05/tricks-to-search-emails-in-gmail.html' title='Tricks to search emails in gmail.'/><author><name>Dave</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-21595493.post-6401933955940175253</id><published>2009-04-15T15:25:00.000-05:00</published><updated>2010-11-17T20:09:40.428-06:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='Mac'/><title type='text'>delete locked files on Mac</title><content type='html'>&lt;span class="Apple-style-span" style="color: rgb(51, 51, 51); font-family: 'Lucida Grande'; font-size: 12px; line-height: 18px; "&gt;&lt;p style="margin-top: 0px; margin-right: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; margin-bottom: 18px; "&gt;&lt;b style="font-weight: bold; "&gt;Advanced tip about deleting locked files&lt;/b&gt;&lt;br /&gt;&lt;br /&gt;If there are several locked files in the Trash, you can unlock them all at the same time at the command line. Follow these steps:&lt;/p&gt;&lt;ol style="margin-top: 0px; margin-right: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; margin-bottom: 18px; list-style-type: decimal; list-style-position: initial; list-style-image: initial; margin-left: 2.2em; "&gt;&lt;li style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-left: 0px; padding-bottom: 10px; "&gt;Open Terminal. It's located in /Applications/Utilities.&lt;br /&gt;&lt;br /&gt;Type: &lt;tt&gt;chflags -R nouchg &lt;br /&gt;&lt;/tt&gt;&lt;b style="font-weight: bold; "&gt;Note: &lt;/b&gt;Type one space (not pictured) after nouchg in the line above, so that it ends in &lt;tt&gt;"nouchg "&lt;/tt&gt;. Do not press Return yet.&lt;/li&gt;&lt;li style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-left: 0px; padding-bottom: 10px; "&gt;Double-click the Trash icon in the Dock to reveal the contents of the Trash. If necessary, arrange the Finder window so that a portion of the Terminal window is still visible.&lt;/li&gt;&lt;li style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-left: 0px; padding-bottom: 10px; "&gt;Press the Command-A key combination to select all files in the Trash.&lt;/li&gt;&lt;li style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-left: 0px; padding-bottom: 10px; "&gt;Drag the files from the Trash to the Terminal window. &lt;br /&gt;&lt;b style="font-weight: bold; "&gt;Note: &lt;/b&gt;This automatically enters the pathname for each file. This eliminates the need to individually empty multiple Trash directories, particularly when multiple disks or volumes are present.&lt;/li&gt;&lt;li style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-left: 0px; padding-bottom: 10px; "&gt;Press Return. No special text message will be shown indicating that the command was successful.&lt;/li&gt;&lt;li style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-left: 0px; padding-bottom: 10px; "&gt;Empty the Trash.&lt;/li&gt;&lt;/ol&gt;&lt;p style="margin-top: 0px; margin-right: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; margin-bottom: 18px; "&gt;&lt;br /&gt;If the Trash does not empty or if you see a message in Terminal that says "usage: chflags [-R [-H | -L | -P]] flags file..." you most likely did not type the text in step 2 as indicated or did not leave a space. Repeat the steps if this happens.&lt;/p&gt;&lt;p style="margin-top: 0px; margin-right: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; margin-bottom: 18px; "&gt;&lt;br /&gt;&lt;/p&gt;&lt;p style="margin-top: 0px; margin-right: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; margin-bottom: 18px; "&gt;originally from: http://support.apple.com/kb/HT1526&lt;/p&gt;&lt;/span&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/21595493-6401933955940175253?l=linux4research.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://linux4research.blogspot.com/feeds/6401933955940175253/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=21595493&amp;postID=6401933955940175253' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/21595493/posts/default/6401933955940175253'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/21595493/posts/default/6401933955940175253'/><link rel='alternate' type='text/html' href='http://linux4research.blogspot.com/2009/04/delete-locked-files-on-mac.html' title='delete locked files on Mac'/><author><name>Dave</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-21595493.post-2632078619820624026</id><published>2009-01-09T21:53:00.001-06:00</published><updated>2009-01-09T21:56:50.060-06:00</updated><title type='text'>Qt link error</title><content type='html'>I install Qt (4.4.3) version of dmg files and debug files (dmg file) the instalation is full. I type&lt;br /&gt;&lt;br /&gt;qmake -project (create project.pro)&lt;br /&gt;qmake (create project.xcodeproj)&lt;br /&gt;&lt;br /&gt;I open xcodeproj file in xcode (version 2.2.1) and copile project. The stage of compiler is good but the stage of linking send me this error:&lt;br /&gt;&lt;em&gt;&lt;br /&gt;/usr/bin/ld: /Library/Frameworks/&lt;span class="highlight"&gt;QtGui&lt;/span&gt;.framework/&lt;span class="highlight"&gt;QtGui&lt;/span&gt; load &lt;span class="highlight"&gt;command&lt;/span&gt; &lt;span class="highlight"&gt;6&lt;/span&gt; &lt;span class="highlight"&gt;unknown&lt;/span&gt; cmd &lt;span class="highlight"&gt;field&lt;/span&gt;&lt;/em&gt;&lt;br /&gt;&lt;br /&gt;&lt;em&gt;/usr/bin/ld: /Library/Frameworks/QtCore.framework/QtCore load &lt;span class="highlight"&gt;command&lt;/span&gt; 5 &lt;span class="highlight"&gt;unknown&lt;/span&gt; cmd &lt;span class="highlight"&gt;field&lt;/span&gt;&lt;/em&gt;&lt;br /&gt;&lt;br /&gt;&lt;em&gt;collect2: ld returned 1 exit status&lt;br /&gt;---------------------------------------------------------------------------------------------------------&lt;br /&gt;&lt;span style="font-weight: bold;"&gt;I solved this problem by upgrading my xcode to version 2.5. Now the program can be compiled. &lt;/span&gt;&lt;br /&gt;&lt;/em&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/21595493-2632078619820624026?l=linux4research.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://linux4research.blogspot.com/feeds/2632078619820624026/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=21595493&amp;postID=2632078619820624026' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/21595493/posts/default/2632078619820624026'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/21595493/posts/default/2632078619820624026'/><link rel='alternate' type='text/html' href='http://linux4research.blogspot.com/2009/01/qt-link-error.html' title='Qt link error'/><author><name>Dave</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-21595493.post-7134471375694248283</id><published>2009-01-05T19:11:00.001-06:00</published><updated>2010-11-17T20:09:40.429-06:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='Mac'/><title type='text'>Recover old version of Qt on Mac (Tiger)</title><content type='html'>&lt;blockquote type="cite"&gt;I have problems with Qt 4.4 on my &lt;a itxtdid="7751026" target="_blank" href="http://osdir.com/ml/lib.qt.general/2008-05/msg00262.html#" style="border-bottom: 0.075em solid blue ! important; font-weight: normal ! important; font-size: 100% ! important; text-decoration: underline ! important; padding-bottom: 1px ! important; color: blue ! important; background-color: transparent ! important;" classname="iAs" class="iAs"&gt;Mac&lt;/a&gt; (tiger) and I posted my questions. But so far no real solution yet. I want to switch back to Qt &lt;a rel="nofollow" href="http://4.3.4./" target="_blank"&gt;4.3.4.&lt;/a&gt; But when I used the dmg file to install it, the &lt;a itxtdid="7398904" target="_blank" href="http://osdir.com/ml/lib.qt.general/2008-05/msg00262.html#" style="border-bottom: 0.075em solid blue ! important; font-weight: normal ! important; font-size: 100% ! important; text-decoration: underline ! important; padding-bottom: 1px ! important; color: blue ! important; background-color: transparent ! important;" classname="iAs" class="iAs"&gt;computer&lt;/a&gt; says "there is nothing to install".  How can I deal with this? &lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;&lt;span&gt;&lt;/span&gt;&lt;/div&gt;&lt;/blockquote&gt;&lt;div&gt;&lt;span&gt;Navigate to /Library/Receipts, find the Reciept from the last time you used the package installer to install 4.3.4 (back before you had 4.4.0), and delete it/them. Looking at my machine, it looks like there might be several packages named something like Qt_libraries, Qt_docs, etc. The installer should be happy then. No guarantees as to how well this will actually work with the 4.4.0 install though. I THINK it should work.&lt;br /&gt;&lt;div&gt;&lt;span style="color: rgb(0, 0, 0);"&gt;&lt;div style=""&gt;&lt;br /&gt;&lt;/div&gt;&lt;/span&gt;&lt;/div&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/21595493-7134471375694248283?l=linux4research.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://linux4research.blogspot.com/feeds/7134471375694248283/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=21595493&amp;postID=7134471375694248283' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/21595493/posts/default/7134471375694248283'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/21595493/posts/default/7134471375694248283'/><link rel='alternate' type='text/html' href='http://linux4research.blogspot.com/2009/01/recover-old-version-of-qt-on-mac-tiger.html' title='Recover old version of Qt on Mac (Tiger)'/><author><name>Dave</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-21595493.post-6854334040295266456</id><published>2008-12-30T15:48:00.001-06:00</published><updated>2010-11-17T20:09:40.429-06:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='Mac'/><title type='text'>Mac and ldconfig</title><content type='html'>In Mac system, there is NO ldconfig which exists in Linux system. The corresponding command in Mac is called "dyld". You can find out more details by "man dyld"&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/21595493-6854334040295266456?l=linux4research.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://linux4research.blogspot.com/feeds/6854334040295266456/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=21595493&amp;postID=6854334040295266456' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/21595493/posts/default/6854334040295266456'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/21595493/posts/default/6854334040295266456'/><link rel='alternate' type='text/html' href='http://linux4research.blogspot.com/2008/12/mac-and-ldconfig.html' title='Mac and ldconfig'/><author><name>Dave</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-21595493.post-2891582249565383600</id><published>2008-12-18T20:01:00.003-06:00</published><updated>2008-12-18T20:12:19.999-06:00</updated><title type='text'>Switch between gdm and kdm</title><content type='html'>First make sure that you installed gdm and kdm. Then use the following command in a console.&lt;br /&gt;&lt;br /&gt;&gt;&gt; sudo dpkg-reconfigure gdm&lt;br /&gt;&lt;br /&gt;From the dialog choose either gdm or kdm.&lt;br /&gt;&lt;br /&gt;&lt;a onblur="try {parent.deselectBloggerImageGracefully();} catch(e) {}" href="http://www.howtogeek.com/wp-content/uploads/2006/12/WindowsLiveWriter/HowtoSwitchBetweenGDMandKDMonUbuntu_6751/configgdm.png"&gt;&lt;img style="margin: 0px auto 10px; display: block; text-align: center; cursor: pointer; width: 463px; height: 266px;" src="http://www.howtogeek.com/wp-content/uploads/2006/12/WindowsLiveWriter/HowtoSwitchBetweenGDMandKDMonUbuntu_6751/configgdm.png" alt="" border="0" /&gt;&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;&lt;img src="file:///tmp/moz-screenshot.jpg" alt="" /&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/21595493-2891582249565383600?l=linux4research.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://linux4research.blogspot.com/feeds/2891582249565383600/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=21595493&amp;postID=2891582249565383600' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/21595493/posts/default/2891582249565383600'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/21595493/posts/default/2891582249565383600'/><link rel='alternate' type='text/html' href='http://linux4research.blogspot.com/2008/12/switch-between-gdm-and-kdm.html' title='Switch between gdm and kdm'/><author><name>Dave</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-21595493.post-5694979448133861420</id><published>2008-09-21T13:35:00.003-05:00</published><updated>2008-09-21T13:41:40.216-05:00</updated><title type='text'>C++ Virtual function</title><content type='html'>&lt;h2&gt;&lt;span class="mw-headline"&gt;Purpose&lt;/span&gt;&lt;/h2&gt;  &lt;p&gt;The concept of the virtual function solves the following problem:&lt;/p&gt; &lt;p&gt;In OOP when a derived class inherits from a base class, an object of the derived class may be referred to (or cast) as either being the base class type or the derived class type. If there are base class functions overridden by the derived class, a problem then arises when a derived object has been cast as the base class type. When a derived object is referred to as being of the base's type, the desired function call behavior is ambiguous.&lt;/p&gt; &lt;p&gt;The distinction between virtual and not virtual resolves this ambiguity. If the function in question is designated "virtual" in the base class then the derived class's function would be called (if it exists). If it is not virtual, the base class's function would be called.&lt;/p&gt; &lt;p&gt;Virtual functions overcome the problems with the type-field solution by allowing the programmer to declare functions in a base class that can be redefined in each derived class.&lt;/p&gt; &lt;p&gt;&lt;a name="Example" id="Example"&gt;&lt;/a&gt;&lt;/p&gt; &lt;h2&gt;&lt;span class="editsection"&gt;&lt;/span&gt;&lt;span class="mw-headline"&gt;Example&lt;/span&gt;&lt;/h2&gt; &lt;p&gt;For example, a base class &lt;code&gt;Animal&lt;/code&gt; could have a virtual function &lt;code&gt;eat&lt;/code&gt;. Subclass &lt;code&gt;Fish&lt;/code&gt; would implement &lt;code&gt;eat()&lt;/code&gt; differently than subclass &lt;code&gt;Wolf&lt;/code&gt;, but you can invoke &lt;code&gt;eat()&lt;/code&gt; on any class instance referred to as Animal, and get the &lt;code&gt;eat()&lt;/code&gt; behavior of the specific subclass.&lt;/p&gt; &lt;p&gt;This allows a programmer to process a list of objects of class &lt;code&gt;Animal&lt;/code&gt;, telling each in turn to eat (by calling &lt;code&gt;eat()&lt;/code&gt;), &lt;a href="http://en.wikipedia.org/wiki/Polymorphism_%28computer_science%29" title="Polymorphism (computer science)" class="mw-redirect"&gt;with no knowledge of what kind&lt;/a&gt; of animal may be in the list. You also do not need to have knowledge of how each animal eats, or what the complete set of possible animal types might be.&lt;/p&gt; &lt;p&gt;The following is an example in C++:&lt;/p&gt; &lt;div dir="ltr" style="text-align: left;"&gt; &lt;pre class="source-cpp"&gt;&lt;span class="co2"&gt;#include &lt;iostream&gt;&lt;/span&gt;&lt;br /&gt;&lt;span class="kw2"&gt;using&lt;/span&gt; &lt;span class="kw2"&gt;namespace&lt;/span&gt; std;&lt;br /&gt;&lt;br /&gt;&lt;span class="kw2"&gt;class&lt;/span&gt; Animal&lt;br /&gt;&lt;span class="br0"&gt;{&lt;/span&gt;&lt;br /&gt;&lt;span class="kw2"&gt;public&lt;/span&gt;:&lt;br /&gt;  &lt;span class="kw2"&gt;virtual&lt;/span&gt; &lt;span class="kw4"&gt;void&lt;/span&gt; eat&lt;span class="br0"&gt;(&lt;/span&gt;&lt;span class="br0"&gt;)&lt;/span&gt; &lt;span class="br0"&gt;{&lt;/span&gt; &lt;span class="kw3"&gt;cout&lt;/span&gt; &lt;&lt; &lt;span class="st0"&gt;"I eat like a generic Animal."&lt;/span&gt; &lt;&lt; class="br0"&gt;}&lt;/span&gt;&lt;br /&gt;&lt;span class="br0"&gt;}&lt;/span&gt;;&lt;br /&gt;&lt;br /&gt;&lt;span class="kw2"&gt;class&lt;/span&gt; Wolf : &lt;span class="kw2"&gt;public&lt;/span&gt; Animal&lt;br /&gt;&lt;span class="br0"&gt;{&lt;/span&gt;&lt;br /&gt;&lt;span class="kw2"&gt;public&lt;/span&gt;:&lt;br /&gt;  &lt;span class="kw4"&gt;void&lt;/span&gt; eat&lt;span class="br0"&gt;(&lt;/span&gt;&lt;span class="br0"&gt;)&lt;/span&gt; &lt;span class="br0"&gt;{&lt;/span&gt; &lt;span class="kw3"&gt;cout&lt;/span&gt; &lt;&lt; &lt;span class="st0"&gt;"I eat like a wolf!"&lt;/span&gt; &lt;&lt; class="br0"&gt;}&lt;/span&gt;&lt;br /&gt;&lt;span class="br0"&gt;}&lt;/span&gt;;&lt;br /&gt;&lt;br /&gt;&lt;span class="kw2"&gt;class&lt;/span&gt; Fish : &lt;span class="kw2"&gt;public&lt;/span&gt; Animal&lt;br /&gt;&lt;span class="br0"&gt;{&lt;/span&gt;&lt;br /&gt;&lt;span class="kw2"&gt;public&lt;/span&gt;:&lt;br /&gt;  &lt;span class="kw4"&gt;void&lt;/span&gt; eat&lt;span class="br0"&gt;(&lt;/span&gt;&lt;span class="br0"&gt;)&lt;/span&gt; &lt;span class="br0"&gt;{&lt;/span&gt; &lt;span class="kw3"&gt;cout&lt;/span&gt; &lt;&lt; &lt;span class="st0"&gt;"I eat like a fish!"&lt;/span&gt; &lt;&lt; class="br0"&gt;}&lt;/span&gt;&lt;br /&gt;&lt;span class="br0"&gt;}&lt;/span&gt;;&lt;br /&gt;&lt;br /&gt;&lt;span class="kw2"&gt;class&lt;/span&gt; GoldFish : &lt;span class="kw2"&gt;public&lt;/span&gt; Fish&lt;br /&gt;&lt;span class="br0"&gt;{&lt;/span&gt;&lt;br /&gt;&lt;span class="kw2"&gt;public&lt;/span&gt;:&lt;br /&gt;  &lt;span class="kw4"&gt;void&lt;/span&gt; eat&lt;span class="br0"&gt;(&lt;/span&gt;&lt;span class="br0"&gt;)&lt;/span&gt; &lt;span class="br0"&gt;{&lt;/span&gt; &lt;span class="kw3"&gt;cout&lt;/span&gt; &lt;&lt; &lt;span class="st0"&gt;"I eat like a goldfish!"&lt;/span&gt; &lt;&lt; class="br0"&gt;}&lt;/span&gt;&lt;br /&gt;&lt;span class="br0"&gt;}&lt;/span&gt;;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;span class="kw2"&gt;class&lt;/span&gt; OtherAnimal : &lt;span class="kw2"&gt;public&lt;/span&gt; Animal&lt;br /&gt;&lt;span class="br0"&gt;{&lt;/span&gt;&lt;br /&gt;&lt;span class="br0"&gt;}&lt;/span&gt;;&lt;br /&gt;&lt;br /&gt;&lt;span class="kw4"&gt;int&lt;/span&gt; main&lt;span class="br0"&gt;(&lt;/span&gt;&lt;span class="br0"&gt;)&lt;/span&gt;&lt;br /&gt;&lt;span class="br0"&gt;{&lt;/span&gt;&lt;br /&gt;  Animal* anAnimal&lt;span class="br0"&gt;[&lt;/span&gt;&lt;span class="nu0"&gt;5&lt;/span&gt;&lt;span class="br0"&gt;]&lt;/span&gt;;&lt;br /&gt;&lt;br /&gt;  anAnimal&lt;span class="br0"&gt;[&lt;/span&gt;&lt;span class="nu0"&gt;0&lt;/span&gt;&lt;span class="br0"&gt;]&lt;/span&gt; = &lt;span class="kw3"&gt;new&lt;/span&gt; Animal&lt;span class="br0"&gt;(&lt;/span&gt;&lt;span class="br0"&gt;)&lt;/span&gt;;&lt;br /&gt;  anAnimal&lt;span class="br0"&gt;[&lt;/span&gt;&lt;span class="nu0"&gt;1&lt;/span&gt;&lt;span class="br0"&gt;]&lt;/span&gt; = &lt;span class="kw3"&gt;new&lt;/span&gt; Wolf&lt;span class="br0"&gt;(&lt;/span&gt;&lt;span class="br0"&gt;)&lt;/span&gt;;&lt;br /&gt;  anAnimal&lt;span class="br0"&gt;[&lt;/span&gt;&lt;span class="nu0"&gt;2&lt;/span&gt;&lt;span class="br0"&gt;]&lt;/span&gt; = &lt;span class="kw3"&gt;new&lt;/span&gt; Fish&lt;span class="br0"&gt;(&lt;/span&gt;&lt;span class="br0"&gt;)&lt;/span&gt;;&lt;br /&gt;  anAnimal&lt;span class="br0"&gt;[&lt;/span&gt;&lt;span class="nu0"&gt;3&lt;/span&gt;&lt;span class="br0"&gt;]&lt;/span&gt; = &lt;span class="kw3"&gt;new&lt;/span&gt; GoldFish&lt;span class="br0"&gt;(&lt;/span&gt;&lt;span class="br0"&gt;)&lt;/span&gt;;&lt;br /&gt;  anAnimal&lt;span class="br0"&gt;[&lt;/span&gt;&lt;span class="nu0"&gt;4&lt;/span&gt;&lt;span class="br0"&gt;]&lt;/span&gt; = &lt;span class="kw3"&gt;new&lt;/span&gt; OtherAnimal&lt;span class="br0"&gt;(&lt;/span&gt;&lt;span class="br0"&gt;)&lt;/span&gt;;&lt;br /&gt;&lt;br /&gt;  &lt;span class="kw1"&gt;for&lt;/span&gt; &lt;span class="br0"&gt;(&lt;/span&gt;&lt;span class="kw4"&gt;int&lt;/span&gt; i = &lt;span class="nu0"&gt;0&lt;/span&gt;; i &lt; &lt;span class="nu0"&gt;5&lt;/span&gt;; i++&lt;span class="br0"&gt;)&lt;/span&gt; &lt;span class="br0"&gt;{&lt;/span&gt;&lt;br /&gt;     anAnimal&lt;span class="br0"&gt;[&lt;/span&gt;i&lt;span class="br0"&gt;]&lt;/span&gt;-&gt;eat&lt;span class="br0"&gt;(&lt;/span&gt;&lt;span class="br0"&gt;)&lt;/span&gt;;&lt;br /&gt;     &lt;span class="kw3"&gt;delete&lt;/span&gt; anAnimal&lt;span class="br0"&gt;[&lt;/span&gt;i&lt;span class="br0"&gt;]&lt;/span&gt;;&lt;br /&gt; &lt;span class="br0"&gt;}&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;  &lt;span class="kw1"&gt;return&lt;/span&gt; &lt;span class="nu0"&gt;0&lt;/span&gt;;&lt;br /&gt;&lt;span class="br0"&gt;}&lt;/span&gt;&lt;br /&gt;&lt;/pre&gt;&lt;/div&gt; &lt;p&gt;Output with the virtual method &lt;code&gt;Animal::eat()&lt;/code&gt;:&lt;/p&gt; &lt;pre&gt;I eat like a generic Animal.&lt;br /&gt;I eat like a wolf!&lt;br /&gt;I eat like a fish!&lt;br /&gt;I eat like a goldfish!&lt;br /&gt;I eat like a generic Animal.&lt;br /&gt;&lt;/pre&gt; &lt;p&gt;Output if &lt;code&gt;Animal::eat()&lt;/code&gt; were not declared as virtual:&lt;/p&gt; &lt;pre&gt;I eat like a generic Animal.&lt;br /&gt;I eat like a generic Animal.&lt;br /&gt;I eat like a generic Animal.&lt;br /&gt;I eat like a generic Animal.&lt;br /&gt;I eat like a generic Animal.&lt;br /&gt;&lt;br /&gt;&lt;span style="font-size:180%;"&gt;&lt;span style="font-weight: bold;"&gt;Pure virtual function and virtual function&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;from &lt;a href="http://www.learncpp.com/cpp-tutorial/126-pure-virtual-functions-abstract-base-classes-and-interface-classes/"&gt;here&lt;/a&gt;&lt;br /&gt;&lt;/pre&gt;&lt;p&gt;Finally, we arrive at the end of our long journey through inheritance! This is the last topic we will cover on the subject. So congratulations in advance on making it through the hardest part of the language!&lt;/p&gt; &lt;p&gt;&lt;strong&gt;Pure virtual (abstract) functions and abstract base classes&lt;/strong&gt;&lt;/p&gt; &lt;p&gt;So far, all of the virtual functions we have written have a body (a definition). However, C++ allows you to create a special kind of virtual function called a &lt;strong&gt;pure virtual function&lt;/strong&gt; (or &lt;strong&gt;abstract function&lt;/strong&gt;) that has no body at all! A pure virtual function simply acts as a placeholder that is meant to be redefined by derived classes.&lt;/p&gt; &lt;p&gt;To create a pure virtual function, rather than define a body for the function, we simply assign the function the value 0.&lt;/p&gt; &lt;div class="dp-highlighter"&gt;&lt;div class="bar"&gt;&lt;div class="tools"&gt;&lt;a href="http://www.learncpp.com/cpp-tutorial/126-pure-virtual-functions-abstract-base-classes-and-interface-classes/#" onclick="dp.sh.Toolbar.Command('ViewSource',this);return false;"&gt;view plain&lt;/a&gt;&lt;a href="http://www.learncpp.com/cpp-tutorial/126-pure-virtual-functions-abstract-base-classes-and-interface-classes/#" onclick="dp.sh.Toolbar.Command('CopyToClipboard',this);return false;"&gt;copy to clipboard&lt;/a&gt;&lt;a href="http://www.learncpp.com/cpp-tutorial/126-pure-virtual-functions-abstract-base-classes-and-interface-classes/#" onclick="dp.sh.Toolbar.Command('PrintSource',this);return false;"&gt;print&lt;/a&gt;&lt;a href="http://www.learncpp.com/cpp-tutorial/126-pure-virtual-functions-abstract-base-classes-and-interface-classes/#" onclick="dp.sh.Toolbar.Command('About',this);return false;"&gt;?&lt;/a&gt;&lt;/div&gt;&lt;/div&gt;&lt;ol class="dp-cpp" start="1"&gt;&lt;li class="alt"&gt;&lt;span&gt;&lt;span class="keyword"&gt;class&lt;/span&gt;&lt;span&gt; Base  &lt;/span&gt;&lt;/span&gt;&lt;/li&gt;&lt;li class=""&gt;&lt;span&gt;{  &lt;/span&gt;&lt;/li&gt;&lt;li class="alt"&gt;&lt;span&gt;&lt;span class="keyword"&gt;public&lt;/span&gt;&lt;span&gt;:  &lt;/span&gt;&lt;/span&gt;&lt;/li&gt;&lt;li class=""&gt;&lt;span&gt;    &lt;span class="keyword"&gt;const&lt;/span&gt;&lt;span&gt; &lt;/span&gt;&lt;span class="datatypes"&gt;char&lt;/span&gt;&lt;span&gt;* SayHi() { &lt;/span&gt;&lt;span class="keyword"&gt;return&lt;/span&gt;&lt;span&gt; &lt;/span&gt;&lt;span class="string"&gt;"Hi"&lt;/span&gt;&lt;span&gt;; } &lt;/span&gt;&lt;span class="comment"&gt;// a normal non-virtual function    &lt;/span&gt;&lt;span&gt;  &lt;/span&gt;&lt;/span&gt;&lt;/li&gt;&lt;li class="alt"&gt;&lt;span&gt;  &lt;/span&gt;&lt;/li&gt;&lt;li class=""&gt;&lt;span&gt;    &lt;span class="keyword"&gt;virtual&lt;/span&gt;&lt;span&gt; &lt;/span&gt;&lt;span class="keyword"&gt;const&lt;/span&gt;&lt;span&gt; &lt;/span&gt;&lt;span class="datatypes"&gt;char&lt;/span&gt;&lt;span&gt;* GetName() { &lt;/span&gt;&lt;span class="keyword"&gt;return&lt;/span&gt;&lt;span&gt; &lt;/span&gt;&lt;span class="string"&gt;"Base"&lt;/span&gt;&lt;span&gt;; } &lt;/span&gt;&lt;span class="comment"&gt;// a normal virtual function&lt;/span&gt;&lt;span&gt;  &lt;/span&gt;&lt;/span&gt;&lt;/li&gt;&lt;li class="alt"&gt;&lt;span&gt;  &lt;/span&gt;&lt;/li&gt;&lt;li class=""&gt;&lt;span&gt;    &lt;span class="keyword"&gt;virtual&lt;/span&gt;&lt;span&gt; &lt;/span&gt;&lt;span class="datatypes"&gt;int&lt;/span&gt;&lt;span&gt; GetValue() = 0; &lt;/span&gt;&lt;span class="comment"&gt;// a pure virtual function&lt;/span&gt;&lt;span&gt;  &lt;/span&gt;&lt;/span&gt;&lt;/li&gt;&lt;li class="alt"&gt;&lt;span&gt;};  &lt;/span&gt;&lt;/li&gt;&lt;/ol&gt;&lt;/div&gt;class Base { public:     const char* SayHi() { return "Hi"; } // a normal non-virtual function          virtual const char* GetName() { return "Base"; } // a normal virtual function      virtual int GetValue() = 0; // a pure virtual function };  &lt;p&gt;When we add a pure virtual function to our class, we are effectively saying, “it is up to the derived classes to implement this function”.&lt;/p&gt; &lt;p&gt;Using a pure virtual function has two main consequences: First, any class with one or more virtual functions becomes an &lt;strong&gt;abstract base class&lt;/strong&gt;, which means that it can not be instantiated!  Consider what would happen if we could create an instance of Base:&lt;/p&gt; &lt;div class="dp-highlighter"&gt;&lt;div class="bar"&gt;&lt;div class="tools"&gt;&lt;a href="http://www.learncpp.com/cpp-tutorial/126-pure-virtual-functions-abstract-base-classes-and-interface-classes/#" onclick="dp.sh.Toolbar.Command('ViewSource',this);return false;"&gt;view plain&lt;/a&gt;&lt;a href="http://www.learncpp.com/cpp-tutorial/126-pure-virtual-functions-abstract-base-classes-and-interface-classes/#" onclick="dp.sh.Toolbar.Command('CopyToClipboard',this);return false;"&gt;copy to clipboard&lt;/a&gt;&lt;a href="http://www.learncpp.com/cpp-tutorial/126-pure-virtual-functions-abstract-base-classes-and-interface-classes/#" onclick="dp.sh.Toolbar.Command('PrintSource',this);return false;"&gt;print&lt;/a&gt;&lt;a href="http://www.learncpp.com/cpp-tutorial/126-pure-virtual-functions-abstract-base-classes-and-interface-classes/#" onclick="dp.sh.Toolbar.Command('About',this);return false;"&gt;?&lt;/a&gt;&lt;/div&gt;&lt;/div&gt;&lt;ol class="dp-cpp" start="1"&gt;&lt;li class="alt"&gt;&lt;span&gt;&lt;span class="datatypes"&gt;int&lt;/span&gt;&lt;span&gt; main()  &lt;/span&gt;&lt;/span&gt;&lt;/li&gt;&lt;li class=""&gt;&lt;span&gt;{  &lt;/span&gt;&lt;/li&gt;&lt;li class="alt"&gt;&lt;span&gt;    Base cBase; &lt;span class="comment"&gt;// pretend this was legal&lt;/span&gt;&lt;span&gt;  &lt;/span&gt;&lt;/span&gt;&lt;/li&gt;&lt;li class=""&gt;&lt;span&gt;    cBase.GetValue(); &lt;span class="comment"&gt;// what would this do?&lt;/span&gt;&lt;span&gt;  &lt;/span&gt;&lt;/span&gt;&lt;/li&gt;&lt;li class="alt"&gt;&lt;span&gt;}  &lt;/span&gt;&lt;/li&gt;&lt;/ol&gt;&lt;/div&gt;int main() {     Base cBase; // pretend this was legal     cBase.GetValue(); // what would this do? }  &lt;p&gt;Second, any derived class must define a body for this function, or that derived class will be considered an abstract base class as well.&lt;/p&gt; &lt;p&gt;Let’s take a look at an example of a pure virtual function in action. In a previous lesson, we wrote a simple Animal base class and derived a Cat and a Dog class from it. Here’s the code as we left it:&lt;/p&gt; &lt;div class="dp-highlighter"&gt;&lt;div class="bar"&gt;&lt;div class="tools"&gt;&lt;a href="http://www.learncpp.com/cpp-tutorial/126-pure-virtual-functions-abstract-base-classes-and-interface-classes/#" onclick="dp.sh.Toolbar.Command('ViewSource',this);return false;"&gt;view plain&lt;/a&gt;&lt;a href="http://www.learncpp.com/cpp-tutorial/126-pure-virtual-functions-abstract-base-classes-and-interface-classes/#" onclick="dp.sh.Toolbar.Command('CopyToClipboard',this);return false;"&gt;copy to clipboard&lt;/a&gt;&lt;a href="http://www.learncpp.com/cpp-tutorial/126-pure-virtual-functions-abstract-base-classes-and-interface-classes/#" onclick="dp.sh.Toolbar.Command('PrintSource',this);return false;"&gt;print&lt;/a&gt;&lt;a href="http://www.learncpp.com/cpp-tutorial/126-pure-virtual-functions-abstract-base-classes-and-interface-classes/#" onclick="dp.sh.Toolbar.Command('About',this);return false;"&gt;?&lt;/a&gt;&lt;/div&gt;&lt;/div&gt;&lt;ol class="dp-cpp" start="1"&gt;&lt;li class="alt"&gt;&lt;span&gt;&lt;span class="preprocessor"&gt;#include &lt;string&gt;&lt;/span&gt;&lt;span&gt;  &lt;/span&gt;&lt;/span&gt;&lt;/li&gt;&lt;li class=""&gt;&lt;span&gt;&lt;span class="keyword"&gt;class&lt;/span&gt;&lt;span&gt; Animal  &lt;/span&gt;&lt;/span&gt;&lt;/li&gt;&lt;li class="alt"&gt;&lt;span&gt;{  &lt;/span&gt;&lt;/li&gt;&lt;li class=""&gt;&lt;span&gt;&lt;span class="keyword"&gt;protected&lt;/span&gt;&lt;span&gt;:  &lt;/span&gt;&lt;/span&gt;&lt;/li&gt;&lt;li class="alt"&gt;&lt;span&gt;    std::string m_strName;  &lt;/span&gt;&lt;/li&gt;&lt;li class=""&gt;&lt;span&gt;  &lt;/span&gt;&lt;/li&gt;&lt;li class="alt"&gt;&lt;span&gt;    &lt;span class="comment"&gt;// We're making this constructor protected because&lt;/span&gt;&lt;span&gt;  &lt;/span&gt;&lt;/span&gt;&lt;/li&gt;&lt;li class=""&gt;&lt;span&gt;    &lt;span class="comment"&gt;// we don't want people creating Animal objects directly,&lt;/span&gt;&lt;span&gt;  &lt;/span&gt;&lt;/span&gt;&lt;/li&gt;&lt;li class="alt"&gt;&lt;span&gt;    &lt;span class="comment"&gt;// but we still want derived classes to be able to use it.&lt;/span&gt;&lt;span&gt;  &lt;/span&gt;&lt;/span&gt;&lt;/li&gt;&lt;li class=""&gt;&lt;span&gt;    Animal(std::string strName)  &lt;/span&gt;&lt;/li&gt;&lt;li class="alt"&gt;&lt;span&gt;        : m_strName(strName)  &lt;/span&gt;&lt;/li&gt;&lt;li class=""&gt;&lt;span&gt;    {  &lt;/span&gt;&lt;/li&gt;&lt;li class="alt"&gt;&lt;span&gt;    }  &lt;/span&gt;&lt;/li&gt;&lt;li class=""&gt;&lt;span&gt;  &lt;/span&gt;&lt;/li&gt;&lt;li class="alt"&gt;&lt;span&gt;&lt;span class="keyword"&gt;public&lt;/span&gt;&lt;span&gt;:  &lt;/span&gt;&lt;/span&gt;&lt;/li&gt;&lt;li class=""&gt;&lt;span&gt;    std::string GetName() { &lt;span class="keyword"&gt;return&lt;/span&gt;&lt;span&gt; m_strName; }  &lt;/span&gt;&lt;/span&gt;&lt;/li&gt;&lt;li class="alt"&gt;&lt;span&gt;    &lt;span class="keyword"&gt;virtual&lt;/span&gt;&lt;span&gt; &lt;/span&gt;&lt;span class="keyword"&gt;const&lt;/span&gt;&lt;span&gt; &lt;/span&gt;&lt;span class="datatypes"&gt;char&lt;/span&gt;&lt;span&gt;* Speak() { &lt;/span&gt;&lt;span class="keyword"&gt;return&lt;/span&gt;&lt;span&gt; &lt;/span&gt;&lt;span class="string"&gt;"???"&lt;/span&gt;&lt;span&gt;; }  &lt;/span&gt;&lt;/span&gt;&lt;/li&gt;&lt;li class=""&gt;&lt;span&gt;};  &lt;/span&gt;&lt;/li&gt;&lt;li class="alt"&gt;&lt;span&gt;  &lt;/span&gt;&lt;/li&gt;&lt;li class=""&gt;&lt;span&gt;&lt;span class="keyword"&gt;class&lt;/span&gt;&lt;span&gt; Cat: &lt;/span&gt;&lt;span class="keyword"&gt;public&lt;/span&gt;&lt;span&gt; Animal  &lt;/span&gt;&lt;/span&gt;&lt;/li&gt;&lt;li class="alt"&gt;&lt;span&gt;{  &lt;/span&gt;&lt;/li&gt;&lt;li class=""&gt;&lt;span&gt;&lt;span class="keyword"&gt;public&lt;/span&gt;&lt;span&gt;:  &lt;/span&gt;&lt;/span&gt;&lt;/li&gt;&lt;li class="alt"&gt;&lt;span&gt;    Cat(std::string strName)  &lt;/span&gt;&lt;/li&gt;&lt;li class=""&gt;&lt;span&gt;        : Animal(strName)  &lt;/span&gt;&lt;/li&gt;&lt;li class="alt"&gt;&lt;span&gt;    {  &lt;/span&gt;&lt;/li&gt;&lt;li class=""&gt;&lt;span&gt;    }  &lt;/span&gt;&lt;/li&gt;&lt;li class="alt"&gt;&lt;span&gt;  &lt;/span&gt;&lt;/li&gt;&lt;li class=""&gt;&lt;span&gt;    &lt;span class="keyword"&gt;virtual&lt;/span&gt;&lt;span&gt; &lt;/span&gt;&lt;span class="keyword"&gt;const&lt;/span&gt;&lt;span&gt; &lt;/span&gt;&lt;span class="datatypes"&gt;char&lt;/span&gt;&lt;span&gt;* Speak() { &lt;/span&gt;&lt;span class="keyword"&gt;return&lt;/span&gt;&lt;span&gt; &lt;/span&gt;&lt;span class="string"&gt;"Meow"&lt;/span&gt;&lt;span&gt;; }  &lt;/span&gt;&lt;/span&gt;&lt;/li&gt;&lt;li class="alt"&gt;&lt;span&gt;};  &lt;/span&gt;&lt;/li&gt;&lt;li class=""&gt;&lt;span&gt;  &lt;/span&gt;&lt;/li&gt;&lt;li class="alt"&gt;&lt;span&gt;&lt;span class="keyword"&gt;class&lt;/span&gt;&lt;span&gt; Dog: &lt;/span&gt;&lt;span class="keyword"&gt;public&lt;/span&gt;&lt;span&gt; Animal  &lt;/span&gt;&lt;/span&gt;&lt;/li&gt;&lt;li class=""&gt;&lt;span&gt;{  &lt;/span&gt;&lt;/li&gt;&lt;li class="alt"&gt;&lt;span&gt;&lt;span class="keyword"&gt;public&lt;/span&gt;&lt;span&gt;:  &lt;/span&gt;&lt;/span&gt;&lt;/li&gt;&lt;li class=""&gt;&lt;span&gt;    Dog(std::string strName)  &lt;/span&gt;&lt;/li&gt;&lt;li class="alt"&gt;&lt;span&gt;        : Animal(strName)  &lt;/span&gt;&lt;/li&gt;&lt;li class=""&gt;&lt;span&gt;    {  &lt;/span&gt;&lt;/li&gt;&lt;li class="alt"&gt;&lt;span&gt;    }  &lt;/span&gt;&lt;/li&gt;&lt;li class=""&gt;&lt;span&gt;  &lt;/span&gt;&lt;/li&gt;&lt;li class="alt"&gt;&lt;span&gt;    &lt;span class="keyword"&gt;virtual&lt;/span&gt;&lt;span&gt; &lt;/span&gt;&lt;span class="keyword"&gt;const&lt;/span&gt;&lt;span&gt; &lt;/span&gt;&lt;span class="datatypes"&gt;char&lt;/span&gt;&lt;span&gt;* Speak() { &lt;/span&gt;&lt;span class="keyword"&gt;return&lt;/span&gt;&lt;span&gt; &lt;/span&gt;&lt;span class="string"&gt;"Woof"&lt;/span&gt;&lt;span&gt;; }  &lt;/span&gt;&lt;/span&gt;&lt;/li&gt;&lt;li class=""&gt;&lt;span&gt;};  &lt;/span&gt;&lt;/li&gt;&lt;/ol&gt;&lt;/div&gt;#include &lt;string&gt; class Animal { protected:     std::string m_strName;      // We're making this constructor protected because     // we don't want people creating Animal objects directly,     // but we still want derived classes to be able to use it.     Animal(std::string strName)         : m_strName(strName)     {     }  public:     std::string GetName() { return m_strName; }     virtual const char* Speak() { return "???"; } };  class Cat: public Animal { public:     Cat(std::string strName)         : Animal(strName)     {     }      virtual const char* Speak() { return "Meow"; } };  class Dog: public Animal { public:     Dog(std::string strName)         : Animal(strName)     {     }      virtual const char* Speak() { return "Woof"; } };  &lt;p&gt;We’ve prevented people from allocating objects of type Animal by making the constructor protected. However, there’s one problem that has not been addressed. It is still possible to create derived classes that do not redefine Speak(). For example:&lt;/p&gt; &lt;div class="dp-highlighter"&gt;&lt;div class="bar"&gt;&lt;div class="tools"&gt;&lt;a href="http://www.learncpp.com/cpp-tutorial/126-pure-virtual-functions-abstract-base-classes-and-interface-classes/#" onclick="dp.sh.Toolbar.Command('ViewSource',this);return false;"&gt;view plain&lt;/a&gt;&lt;a href="http://www.learncpp.com/cpp-tutorial/126-pure-virtual-functions-abstract-base-classes-and-interface-classes/#" onclick="dp.sh.Toolbar.Command('CopyToClipboard',this);return false;"&gt;copy to clipboard&lt;/a&gt;&lt;a href="http://www.learncpp.com/cpp-tutorial/126-pure-virtual-functions-abstract-base-classes-and-interface-classes/#" onclick="dp.sh.Toolbar.Command('PrintSource',this);return false;"&gt;print&lt;/a&gt;&lt;a href="http://www.learncpp.com/cpp-tutorial/126-pure-virtual-functions-abstract-base-classes-and-interface-classes/#" onclick="dp.sh.Toolbar.Command('About',this);return false;"&gt;?&lt;/a&gt;&lt;/div&gt;&lt;/div&gt;&lt;ol class="dp-cpp" start="1"&gt;&lt;li class="alt"&gt;&lt;span&gt;&lt;span class="keyword"&gt;class&lt;/span&gt;&lt;span&gt; Cow: &lt;/span&gt;&lt;span class="keyword"&gt;public&lt;/span&gt;&lt;span&gt; Animal  &lt;/span&gt;&lt;/span&gt;&lt;/li&gt;&lt;li class=""&gt;&lt;span&gt;{  &lt;/span&gt;&lt;/li&gt;&lt;li class="alt"&gt;&lt;span&gt;&lt;span class="keyword"&gt;public&lt;/span&gt;&lt;span&gt;:  &lt;/span&gt;&lt;/span&gt;&lt;/li&gt;&lt;li class=""&gt;&lt;span&gt;    Cow(std::string strName)  &lt;/span&gt;&lt;/li&gt;&lt;li class="alt"&gt;&lt;span&gt;        : Animal(strName)  &lt;/span&gt;&lt;/li&gt;&lt;li class=""&gt;&lt;span&gt;    {  &lt;/span&gt;&lt;/li&gt;&lt;li class="alt"&gt;&lt;span&gt;    }  &lt;/span&gt;&lt;/li&gt;&lt;li class=""&gt;&lt;span&gt;  &lt;/span&gt;&lt;/li&gt;&lt;li class="alt"&gt;&lt;span&gt;    &lt;span class="comment"&gt;// We forgot to redefine Speak&lt;/span&gt;&lt;span&gt;  &lt;/span&gt;&lt;/span&gt;&lt;/li&gt;&lt;li class=""&gt;&lt;span&gt;};  &lt;/span&gt;&lt;/li&gt;&lt;li class="alt"&gt;&lt;span&gt;  &lt;/span&gt;&lt;/li&gt;&lt;li class=""&gt;&lt;span&gt;&lt;span class="datatypes"&gt;int&lt;/span&gt;&lt;span&gt; main()  &lt;/span&gt;&lt;/span&gt;&lt;/li&gt;&lt;li class="alt"&gt;&lt;span&gt;{  &lt;/span&gt;&lt;/li&gt;&lt;li class=""&gt;&lt;span&gt;    Cow cCow(&lt;span class="string"&gt;"Betsy"&lt;/span&gt;&lt;span&gt;);  &lt;/span&gt;&lt;/span&gt;&lt;/li&gt;&lt;li class="alt"&gt;&lt;span&gt;    cout &lt;&lt; class="string"&gt;" says "&lt;/span&gt;&lt;span&gt; &lt;&lt;&gt;&lt;/span&gt;&lt;/li&gt;&lt;li class=""&gt;&lt;span&gt;}  &lt;/span&gt;&lt;/li&gt;&lt;/ol&gt;&lt;/div&gt;class Cow: public Animal { public:     Cow(std::string strName)         : Animal(strName)     {     }      // We forgot to redefine Speak };  int main() {     Cow cCow("Betsy");     cout &lt;&lt;&gt;This will print:&lt;/p&gt; Betsy says ???  &lt;p&gt;What happened?  We forgot to redefine Speak, so cCow.Speak() resolved to Animal.Speak(), which isn’t what we wanted.&lt;/p&gt; &lt;p&gt;A better solution to this problem is to use a pure virtual function:&lt;/p&gt; &lt;div class="dp-highlighter"&gt;&lt;div class="bar"&gt;&lt;div class="tools"&gt;&lt;a href="http://www.learncpp.com/cpp-tutorial/126-pure-virtual-functions-abstract-base-classes-and-interface-classes/#" onclick="dp.sh.Toolbar.Command('ViewSource',this);return false;"&gt;view plain&lt;/a&gt;&lt;a href="http://www.learncpp.com/cpp-tutorial/126-pure-virtual-functions-abstract-base-classes-and-interface-classes/#" onclick="dp.sh.Toolbar.Command('CopyToClipboard',this);return false;"&gt;copy to clipboard&lt;/a&gt;&lt;a href="http://www.learncpp.com/cpp-tutorial/126-pure-virtual-functions-abstract-base-classes-and-interface-classes/#" onclick="dp.sh.Toolbar.Command('PrintSource',this);return false;"&gt;print&lt;/a&gt;&lt;a href="http://www.learncpp.com/cpp-tutorial/126-pure-virtual-functions-abstract-base-classes-and-interface-classes/#" onclick="dp.sh.Toolbar.Command('About',this);return false;"&gt;?&lt;/a&gt;&lt;/div&gt;&lt;/div&gt;&lt;ol class="dp-cpp" start="1"&gt;&lt;li class="alt"&gt;&lt;span&gt;&lt;span class="preprocessor"&gt;#include &lt;string&gt;&lt;/span&gt;&lt;span&gt;  &lt;/span&gt;&lt;/span&gt;&lt;/li&gt;&lt;li class=""&gt;&lt;span&gt;&lt;span class="keyword"&gt;class&lt;/span&gt;&lt;span&gt; Animal  &lt;/span&gt;&lt;/span&gt;&lt;/li&gt;&lt;li class="alt"&gt;&lt;span&gt;{  &lt;/span&gt;&lt;/li&gt;&lt;li class=""&gt;&lt;span&gt;&lt;span class="keyword"&gt;protected&lt;/span&gt;&lt;span&gt;:  &lt;/span&gt;&lt;/span&gt;&lt;/li&gt;&lt;li class="alt"&gt;&lt;span&gt;    std::string m_strName;  &lt;/span&gt;&lt;/li&gt;&lt;li class=""&gt;&lt;span&gt;  &lt;/span&gt;&lt;/li&gt;&lt;li class="alt"&gt;&lt;span&gt;&lt;span class="keyword"&gt;public&lt;/span&gt;&lt;span&gt;:  &lt;/span&gt;&lt;/span&gt;&lt;/li&gt;&lt;li class=""&gt;&lt;span&gt;    Animal(std::string strName)  &lt;/span&gt;&lt;/li&gt;&lt;li class="alt"&gt;&lt;span&gt;        : m_strName(strName)  &lt;/span&gt;&lt;/li&gt;&lt;li class=""&gt;&lt;span&gt;    {  &lt;/span&gt;&lt;/li&gt;&lt;li class="alt"&gt;&lt;span&gt;    }  &lt;/span&gt;&lt;/li&gt;&lt;li class=""&gt;&lt;span&gt;  &lt;/span&gt;&lt;/li&gt;&lt;li class="alt"&gt;&lt;span&gt;    std::string GetName() { &lt;span class="keyword"&gt;return&lt;/span&gt;&lt;span&gt; m_strName; }  &lt;/span&gt;&lt;/span&gt;&lt;/li&gt;&lt;li class=""&gt;&lt;span&gt;    &lt;span class="keyword"&gt;virtual&lt;/span&gt;&lt;span&gt; &lt;/span&gt;&lt;span class="keyword"&gt;const&lt;/span&gt;&lt;span&gt; &lt;/span&gt;&lt;span class="datatypes"&gt;char&lt;/span&gt;&lt;span&gt;* Speak() = 0; &lt;/span&gt;&lt;span class="comment"&gt;// pure virtual function&lt;/span&gt;&lt;span&gt;  &lt;/span&gt;&lt;/span&gt;&lt;/li&gt;&lt;li class="alt"&gt;&lt;span&gt;};  &lt;/span&gt;&lt;/li&gt;&lt;/ol&gt;&lt;/div&gt;#include &lt;string&gt; class Animal { protected:     std::string m_strName;  public:     Animal(std::string strName)         : m_strName(strName)     {     }      std::string GetName() { return m_strName; }     virtual const char* Speak() = 0; // pure virtual function };  &lt;p&gt;There are a couple of things to note here. First, Speak() is now a pure virtual function. This means Animal is an abstract base class, and can not be instantiated. Consequently, we do not need to make the constructor protected any longer (though it doesn’t hurt). Second, because our Cow class was derived from Animal, but we did not define Cow::Speak(), Cow is also an abstract base class. Now when we try to compile this code:&lt;/p&gt; &lt;div class="dp-highlighter"&gt;&lt;div class="bar"&gt;&lt;div class="tools"&gt;&lt;a href="http://www.learncpp.com/cpp-tutorial/126-pure-virtual-functions-abstract-base-classes-and-interface-classes/#" onclick="dp.sh.Toolbar.Command('ViewSource',this);return false;"&gt;view plain&lt;/a&gt;&lt;a href="http://www.learncpp.com/cpp-tutorial/126-pure-virtual-functions-abstract-base-classes-and-interface-classes/#" onclick="dp.sh.Toolbar.Command('CopyToClipboard',this);return false;"&gt;copy to clipboard&lt;/a&gt;&lt;a href="http://www.learncpp.com/cpp-tutorial/126-pure-virtual-functions-abstract-base-classes-and-interface-classes/#" onclick="dp.sh.Toolbar.Command('PrintSource',this);return false;"&gt;print&lt;/a&gt;&lt;a href="http://www.learncpp.com/cpp-tutorial/126-pure-virtual-functions-abstract-base-classes-and-interface-classes/#" onclick="dp.sh.Toolbar.Command('About',this);return false;"&gt;?&lt;/a&gt;&lt;/div&gt;&lt;/div&gt;&lt;ol class="dp-cpp" start="1"&gt;&lt;li class="alt"&gt;&lt;span&gt;&lt;span class="keyword"&gt;class&lt;/span&gt;&lt;span&gt; Cow: &lt;/span&gt;&lt;span class="keyword"&gt;public&lt;/span&gt;&lt;span&gt; Animal  &lt;/span&gt;&lt;/span&gt;&lt;/li&gt;&lt;li class=""&gt;&lt;span&gt;{  &lt;/span&gt;&lt;/li&gt;&lt;li class="alt"&gt;&lt;span&gt;&lt;span class="keyword"&gt;public&lt;/span&gt;&lt;span&gt;:  &lt;/span&gt;&lt;/span&gt;&lt;/li&gt;&lt;li class=""&gt;&lt;span&gt;    Cow(std::string strName)  &lt;/span&gt;&lt;/li&gt;&lt;li class="alt"&gt;&lt;span&gt;        : Animal(strName)  &lt;/span&gt;&lt;/li&gt;&lt;li class=""&gt;&lt;span&gt;    {  &lt;/span&gt;&lt;/li&gt;&lt;li class="alt"&gt;&lt;span&gt;    }  &lt;/span&gt;&lt;/li&gt;&lt;li class=""&gt;&lt;span&gt;  &lt;/span&gt;&lt;/li&gt;&lt;li class="alt"&gt;&lt;span&gt;    &lt;span class="comment"&gt;// We forgot to redefine Speak&lt;/span&gt;&lt;span&gt;  &lt;/span&gt;&lt;/span&gt;&lt;/li&gt;&lt;li class=""&gt;&lt;span&gt;};  &lt;/span&gt;&lt;/li&gt;&lt;li class="alt"&gt;&lt;span&gt;  &lt;/span&gt;&lt;/li&gt;&lt;li class=""&gt;&lt;span&gt;&lt;span class="datatypes"&gt;int&lt;/span&gt;&lt;span&gt; main()  &lt;/span&gt;&lt;/span&gt;&lt;/li&gt;&lt;li class="alt"&gt;&lt;span&gt;{  &lt;/span&gt;&lt;/li&gt;&lt;li class=""&gt;&lt;span&gt;    Cow cCow(&lt;span class="string"&gt;"Betsy"&lt;/span&gt;&lt;span&gt;);  &lt;/span&gt;&lt;/span&gt;&lt;/li&gt;&lt;li class="alt"&gt;&lt;span&gt;    cout &lt;&lt; class="string"&gt;" says "&lt;/span&gt;&lt;span&gt; &lt;&lt;&gt;&lt;/span&gt;&lt;/li&gt;&lt;li class=""&gt;&lt;span&gt;}  &lt;/span&gt;&lt;/li&gt;&lt;/ol&gt;&lt;/div&gt;class Cow: public Animal { public:     Cow(std::string strName)         : Animal(strName)     {     }      // We forgot to redefine Speak };  int main() {     Cow cCow("Betsy");     cout &lt;&lt;&gt;The compiler will give us a warning because Cow is an abstract base class and we can not create instances of abstract base classes:&lt;/p&gt; C:\\Test.cpp(141) : error C2259: 'Cow' : cannot instantiate abstract class due to following members:         C:\Test.cpp(128) : see declaration of 'Cow' C:\\Test.cpp(141) : warning C4259: 'const char *__thiscall Animal::Speak(void)' : pure virtual function was not defined  &lt;p&gt;This tells us that we will only be able to instantiate Cow if Cow provides a body for Speak().&lt;/p&gt; &lt;p&gt;Let’s go ahead and do that:&lt;/p&gt; &lt;div class="dp-highlighter"&gt;&lt;div class="bar"&gt;&lt;div class="tools"&gt;&lt;a href="http://www.learncpp.com/cpp-tutorial/126-pure-virtual-functions-abstract-base-classes-and-interface-classes/#" onclick="dp.sh.Toolbar.Command('ViewSource',this);return false;"&gt;view plain&lt;/a&gt;&lt;a href="http://www.learncpp.com/cpp-tutorial/126-pure-virtual-functions-abstract-base-classes-and-interface-classes/#" onclick="dp.sh.Toolbar.Command('CopyToClipboard',this);return false;"&gt;copy to clipboard&lt;/a&gt;&lt;a href="http://www.learncpp.com/cpp-tutorial/126-pure-virtual-functions-abstract-base-classes-and-interface-classes/#" onclick="dp.sh.Toolbar.Command('PrintSource',this);return false;"&gt;print&lt;/a&gt;&lt;a href="http://www.learncpp.com/cpp-tutorial/126-pure-virtual-functions-abstract-base-classes-and-interface-classes/#" onclick="dp.sh.Toolbar.Command('About',this);return false;"&gt;?&lt;/a&gt;&lt;/div&gt;&lt;/div&gt;&lt;ol class="dp-cpp" start="1"&gt;&lt;li class="alt"&gt;&lt;span&gt;&lt;span class="keyword"&gt;class&lt;/span&gt;&lt;span&gt; Cow: &lt;/span&gt;&lt;span class="keyword"&gt;public&lt;/span&gt;&lt;span&gt; Animal  &lt;/span&gt;&lt;/span&gt;&lt;/li&gt;&lt;li class=""&gt;&lt;span&gt;{  &lt;/span&gt;&lt;/li&gt;&lt;li class="alt"&gt;&lt;span&gt;&lt;span class="keyword"&gt;public&lt;/span&gt;&lt;span&gt;:  &lt;/span&gt;&lt;/span&gt;&lt;/li&gt;&lt;li class=""&gt;&lt;span&gt;    Cow(std::string strName)  &lt;/span&gt;&lt;/li&gt;&lt;li class="alt"&gt;&lt;span&gt;        : Animal(strName)  &lt;/span&gt;&lt;/li&gt;&lt;li class=""&gt;&lt;span&gt;    {  &lt;/span&gt;&lt;/li&gt;&lt;li class="alt"&gt;&lt;span&gt;    }  &lt;/span&gt;&lt;/li&gt;&lt;li class=""&gt;&lt;span&gt;  &lt;/span&gt;&lt;/li&gt;&lt;li class="alt"&gt;&lt;span&gt;    &lt;span class="keyword"&gt;virtual&lt;/span&gt;&lt;span&gt; &lt;/span&gt;&lt;span class="keyword"&gt;const&lt;/span&gt;&lt;span&gt; &lt;/span&gt;&lt;span class="datatypes"&gt;char&lt;/span&gt;&lt;span&gt;* Speak() { &lt;/span&gt;&lt;span class="keyword"&gt;return&lt;/span&gt;&lt;span&gt; &lt;/span&gt;&lt;span class="string"&gt;"Moo"&lt;/span&gt;&lt;span&gt;; }  &lt;/span&gt;&lt;/span&gt;&lt;/li&gt;&lt;li class=""&gt;&lt;span&gt;};  &lt;/span&gt;&lt;/li&gt;&lt;li class="alt"&gt;&lt;span&gt;  &lt;/span&gt;&lt;/li&gt;&lt;li class=""&gt;&lt;span&gt;&lt;span class="datatypes"&gt;int&lt;/span&gt;&lt;span&gt; main()  &lt;/span&gt;&lt;/span&gt;&lt;/li&gt;&lt;li class="alt"&gt;&lt;span&gt;{  &lt;/span&gt;&lt;/li&gt;&lt;li class=""&gt;&lt;span&gt;    Cow cCow(&lt;span class="string"&gt;"Betsy"&lt;/span&gt;&lt;span&gt;);  &lt;/span&gt;&lt;/span&gt;&lt;/li&gt;&lt;li class="alt"&gt;&lt;span&gt;    cout &lt;&lt; class="string"&gt;" says "&lt;/span&gt;&lt;span&gt; &lt;&lt;&gt;&lt;/span&gt;&lt;/li&gt;&lt;li class=""&gt;&lt;span&gt;}  &lt;/span&gt;&lt;/li&gt;&lt;/ol&gt;&lt;/div&gt;class Cow: public Animal { public:     Cow(std::string strName)         : Animal(strName)     {     }      virtual const char* Speak() { return "Moo"; } };  int main() {     Cow cCow("Betsy");     cout &lt;&lt;&gt;Now this program will compile and print:&lt;/p&gt; Betsy says Moo  &lt;p&gt;A pure virtual function is useful when we have a function that we want to put in the base class, but only the derived classes know what it should return. A pure virtual function makes it so the base class can not be instantiated, and the derived classes are forced to define these function before they can be instantiated. This helps ensure the derived classes do not forget to redefine functions that the base class was expecting them to.&lt;/p&gt; &lt;p&gt;&lt;strong&gt;Interface classes&lt;/strong&gt;&lt;/p&gt; &lt;p&gt;An &lt;strong&gt;interface class&lt;/strong&gt; is a class that has no members variables, and where all of the functions are pure virtual! In other words, the class is purely a definition, and has no actual implementation. Interfaces are useful when you want to define the functionality that derived classes must implement, but leave the details of how the derived class implements that functionality entirely up to the derived class.&lt;/p&gt; &lt;p&gt;Interface classes are often named beginning with an I.  Here’s a sample interface class:&lt;/p&gt; &lt;div class="dp-highlighter"&gt;&lt;div class="bar"&gt;&lt;div class="tools"&gt;&lt;a href="http://www.learncpp.com/cpp-tutorial/126-pure-virtual-functions-abstract-base-classes-and-interface-classes/#" onclick="dp.sh.Toolbar.Command('ViewSource',this);return false;"&gt;view plain&lt;/a&gt;&lt;a href="http://www.learncpp.com/cpp-tutorial/126-pure-virtual-functions-abstract-base-classes-and-interface-classes/#" onclick="dp.sh.Toolbar.Command('CopyToClipboard',this);return false;"&gt;copy to clipboard&lt;/a&gt;&lt;a href="http://www.learncpp.com/cpp-tutorial/126-pure-virtual-functions-abstract-base-classes-and-interface-classes/#" onclick="dp.sh.Toolbar.Command('PrintSource',this);return false;"&gt;print&lt;/a&gt;&lt;a href="http://www.learncpp.com/cpp-tutorial/126-pure-virtual-functions-abstract-base-classes-and-interface-classes/#" onclick="dp.sh.Toolbar.Command('About',this);return false;"&gt;?&lt;/a&gt;&lt;/div&gt;&lt;/div&gt;&lt;ol class="dp-cpp" start="1"&gt;&lt;li class="alt"&gt;&lt;span&gt;&lt;span class="keyword"&gt;class&lt;/span&gt;&lt;span&gt; IErrorLog  &lt;/span&gt;&lt;/span&gt;&lt;/li&gt;&lt;li class=""&gt;&lt;span&gt;{  &lt;/span&gt;&lt;/li&gt;&lt;li class="alt"&gt;&lt;span&gt;    &lt;span class="keyword"&gt;virtual&lt;/span&gt;&lt;span&gt; &lt;/span&gt;&lt;span class="datatypes"&gt;bool&lt;/span&gt;&lt;span&gt; OpenLog(&lt;/span&gt;&lt;span class="keyword"&gt;const&lt;/span&gt;&lt;span&gt; &lt;/span&gt;&lt;span class="datatypes"&gt;char&lt;/span&gt;&lt;span&gt; *strFilename) = 0;  &lt;/span&gt;&lt;/span&gt;&lt;/li&gt;&lt;li class=""&gt;&lt;span&gt;    &lt;span class="keyword"&gt;virtual&lt;/span&gt;&lt;span&gt; &lt;/span&gt;&lt;span class="datatypes"&gt;bool&lt;/span&gt;&lt;span&gt; CloseLog() = 0;  &lt;/span&gt;&lt;/span&gt;&lt;/li&gt;&lt;li class="alt"&gt;&lt;span&gt;  &lt;/span&gt;&lt;/li&gt;&lt;li class=""&gt;&lt;span&gt;    &lt;span class="keyword"&gt;virtual&lt;/span&gt;&lt;span&gt; &lt;/span&gt;&lt;span class="datatypes"&gt;bool&lt;/span&gt;&lt;span&gt; WriteError(&lt;/span&gt;&lt;span class="keyword"&gt;const&lt;/span&gt;&lt;span&gt; &lt;/span&gt;&lt;span class="datatypes"&gt;char&lt;/span&gt;&lt;span&gt; *strErrorMessage) = 0;  &lt;/span&gt;&lt;/span&gt;&lt;/li&gt;&lt;li class="alt"&gt;&lt;span&gt;};  &lt;/span&gt;&lt;/li&gt;&lt;/ol&gt;&lt;/div&gt;class IErrorLog {     virtual bool OpenLog(const char *strFilename) = 0;     virtual bool CloseLog() = 0;      virtual bool WriteError(const char *strErrorMessage) = 0; };  &lt;p&gt;Any class inheriting from IErrorLog must provide implementations for all three functions in order to be instantiated. You could derive a class named FileErrorLog, where OpenLog() opens a file on disk, CloseLog() closes it, and WriteError() writes the message to the file. You could derive another class called ScreenErrorLog, where OpenLog() and CloseLog() do nothing, and WriteError() prints the message in a pop-up message box on the screen.&lt;/p&gt; &lt;p&gt;Now, let’s say you need to write some code that uses an error log. If you write your code so it includes FileErrorLog or ScreenErrorLog directly, then you’re effectively stuck using that kind of error log. For example, the following function effectively forces callers of MySqrt() to use a FileErrorLog, which may or may not be what they want. &lt;/p&gt; &lt;div class="dp-highlighter"&gt;&lt;div class="bar"&gt;&lt;div class="tools"&gt;&lt;a href="http://www.learncpp.com/cpp-tutorial/126-pure-virtual-functions-abstract-base-classes-and-interface-classes/#" onclick="dp.sh.Toolbar.Command('ViewSource',this);return false;"&gt;view plain&lt;/a&gt;&lt;a href="http://www.learncpp.com/cpp-tutorial/126-pure-virtual-functions-abstract-base-classes-and-interface-classes/#" onclick="dp.sh.Toolbar.Command('CopyToClipboard',this);return false;"&gt;copy to clipboard&lt;/a&gt;&lt;a href="http://www.learncpp.com/cpp-tutorial/126-pure-virtual-functions-abstract-base-classes-and-interface-classes/#" onclick="dp.sh.Toolbar.Command('PrintSource',this);return false;"&gt;print&lt;/a&gt;&lt;a href="http://www.learncpp.com/cpp-tutorial/126-pure-virtual-functions-abstract-base-classes-and-interface-classes/#" onclick="dp.sh.Toolbar.Command('About',this);return false;"&gt;?&lt;/a&gt;&lt;/div&gt;&lt;/div&gt;&lt;ol class="dp-cpp" start="1"&gt;&lt;li class="alt"&gt;&lt;span&gt;&lt;span class="datatypes"&gt;double&lt;/span&gt;&lt;span&gt; MySqrt(&lt;/span&gt;&lt;span class="datatypes"&gt;double&lt;/span&gt;&lt;span&gt; dValue, FileErrorLog &amp;amp;cLog)  &lt;/span&gt;&lt;/span&gt;&lt;/li&gt;&lt;li class=""&gt;&lt;span&gt;{  &lt;/span&gt;&lt;/li&gt;&lt;li class="alt"&gt;&lt;span&gt;    &lt;span class="keyword"&gt;if&lt;/span&gt;&lt;span&gt; (dValue &lt;&gt;&lt;/span&gt;&lt;/li&gt;&lt;li class=""&gt;&lt;span&gt;    {  &lt;/span&gt;&lt;/li&gt;&lt;li class="alt"&gt;&lt;span&gt;        cLog.WriteError(&lt;span class="string"&gt;"Tried to take square root of value less than 0"&lt;/span&gt;&lt;span&gt;);  &lt;/span&gt;&lt;/span&gt;&lt;/li&gt;&lt;li class=""&gt;&lt;span&gt;        &lt;span class="keyword"&gt;return&lt;/span&gt;&lt;span&gt; 0.0;  &lt;/span&gt;&lt;/span&gt;&lt;/li&gt;&lt;li class="alt"&gt;&lt;span&gt;    }  &lt;/span&gt;&lt;/li&gt;&lt;li class=""&gt;&lt;span&gt;    &lt;span class="keyword"&gt;else&lt;/span&gt;&lt;span&gt;  &lt;/span&gt;&lt;/span&gt;&lt;/li&gt;&lt;li class="alt"&gt;&lt;span&gt;        &lt;span class="keyword"&gt;return&lt;/span&gt;&lt;span&gt; dValue;  &lt;/span&gt;&lt;/span&gt;&lt;/li&gt;&lt;li class=""&gt;&lt;span&gt;}  &lt;/span&gt;&lt;/li&gt;&lt;/ol&gt;&lt;/div&gt;double MySqrt(double dValue, FileErrorLog &amp;amp;cLog) {     if (dValue &lt;&gt;A much better way to implement this function is to use IErrorLog instead:&lt;/p&gt; &lt;div class="dp-highlighter"&gt;&lt;div class="bar"&gt;&lt;div class="tools"&gt;&lt;a href="http://www.learncpp.com/cpp-tutorial/126-pure-virtual-functions-abstract-base-classes-and-interface-classes/#" onclick="dp.sh.Toolbar.Command('ViewSource',this);return false;"&gt;view plain&lt;/a&gt;&lt;a href="http://www.learncpp.com/cpp-tutorial/126-pure-virtual-functions-abstract-base-classes-and-interface-classes/#" onclick="dp.sh.Toolbar.Command('CopyToClipboard',this);return false;"&gt;copy to clipboard&lt;/a&gt;&lt;a href="http://www.learncpp.com/cpp-tutorial/126-pure-virtual-functions-abstract-base-classes-and-interface-classes/#" onclick="dp.sh.Toolbar.Command('PrintSource',this);return false;"&gt;print&lt;/a&gt;&lt;a href="http://www.learncpp.com/cpp-tutorial/126-pure-virtual-functions-abstract-base-classes-and-interface-classes/#" onclick="dp.sh.Toolbar.Command('About',this);return false;"&gt;?&lt;/a&gt;&lt;/div&gt;&lt;/div&gt;&lt;ol class="dp-cpp" start="1"&gt;&lt;li class="alt"&gt;&lt;span&gt;&lt;span class="datatypes"&gt;double&lt;/span&gt;&lt;span&gt; MySqrt(&lt;/span&gt;&lt;span class="datatypes"&gt;double&lt;/span&gt;&lt;span&gt; dValue, IErrorLog &amp;amp;cLog)  &lt;/span&gt;&lt;/span&gt;&lt;/li&gt;&lt;li class=""&gt;&lt;span&gt;{  &lt;/span&gt;&lt;/li&gt;&lt;li class="alt"&gt;&lt;span&gt;    &lt;span class="keyword"&gt;if&lt;/span&gt;&lt;span&gt; (dValue &lt;&gt;&lt;/span&gt;&lt;/li&gt;&lt;li class=""&gt;&lt;span&gt;    {  &lt;/span&gt;&lt;/li&gt;&lt;li class="alt"&gt;&lt;span&gt;        cLog.WriteError(&lt;span class="string"&gt;"Tried to take square root of value less than 0"&lt;/span&gt;&lt;span&gt;);  &lt;/span&gt;&lt;/span&gt;&lt;/li&gt;&lt;li class=""&gt;&lt;span&gt;        &lt;span class="keyword"&gt;return&lt;/span&gt;&lt;span&gt; 0.0;  &lt;/span&gt;&lt;/span&gt;&lt;/li&gt;&lt;li class="alt"&gt;&lt;span&gt;    }  &lt;/span&gt;&lt;/li&gt;&lt;li class=""&gt;&lt;span&gt;    &lt;span class="keyword"&gt;else&lt;/span&gt;&lt;span&gt;  &lt;/span&gt;&lt;/span&gt;&lt;/li&gt;&lt;li class="alt"&gt;&lt;span&gt;        &lt;span class="keyword"&gt;return&lt;/span&gt;&lt;span&gt; dValue;  &lt;/span&gt;&lt;/span&gt;&lt;/li&gt;&lt;li class=""&gt;&lt;span&gt;}  &lt;/span&gt;&lt;/li&gt;&lt;/ol&gt;&lt;/div&gt;double MySqrt(double dValue, IErrorLog &amp;amp;cLog) {     if (dValue &lt;&gt;Now the caller can pass in any class that conforms to the IErrorLog interface. If they want the error to go to a file, they can pass in an instance of FileErrorLog. If they want it to go to the screen, they can pass in an instance of ScreenErrorLog. Or if they want to do something you haven’t even thought of, such as sending an email to someone when there’s an error, they can derive a new class from IErrorLog (eg. EmailErrorLog) and use an instance of that! By using IErrorLog, your function becomes more independent and flexible.&lt;/p&gt; &lt;p&gt;Interface classes have become extremely popular because they are easy to use, easy to extend, and easy to maintain. In fact, some modern languages, such as Java and C#, have added an “interface” keyword that allows programmers to directly define an interface class without having to explicitly mark all of the member functions as abstract. Furthermore, although Java and C# will not let you use multiple inheritance on normal classes, they will let you multiply inherit as many interfaces as you like. Because interfaces have no data and no function bodies, they avoid a lot of the traditional problems with multiple inheritance while still providing much of the flexibility.&lt;/p&gt;&lt;pre&gt;&lt;br /&gt;&lt;/pre&gt; &lt;p&gt;&lt;a name="Java" id="Java"&gt;&lt;/a&gt;&lt;span class="editsection"&gt;&lt;/span&gt; &lt;span class="mw-headline"&gt;&lt;/span&gt;&lt;/p&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/21595493-5694979448133861420?l=linux4research.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://linux4research.blogspot.com/feeds/5694979448133861420/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=21595493&amp;postID=5694979448133861420' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/21595493/posts/default/5694979448133861420'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/21595493/posts/default/5694979448133861420'/><link rel='alternate' type='text/html' href='http://linux4research.blogspot.com/2008/09/c-virtual-function.html' title='C++ Virtual function'/><author><name>Dave</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-21595493.post-3500177946273529107</id><published>2008-09-21T11:00:00.003-05:00</published><updated>2008-10-06T23:18:38.894-05:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='linux tips'/><title type='text'>Using rsync to synchronize the files.</title><content type='html'>&lt;span style="font-style: italic; font-weight: bold;"&gt; rsync -autv username@xxx.xxx.xxx.edu:/source_directory/    ./dest_directory&lt;br /&gt;&lt;/span&gt;&lt;br /&gt;Use "-autv" options. This will make sure that if the files in the dest_directory is newer, it will not be overwritten.&lt;br /&gt;"t" will preserve the time stamp.&lt;br /&gt;"a" archive&lt;br /&gt;"u" update; skip files that are newer on the receiver&lt;br /&gt;"v" print out information&lt;br /&gt;&lt;br /&gt;Another thing needs to be careful is that "/" after source_directory is needed if you want to synchronize the files inside source_directory. If "/" is ignored, then source_directory will be copied to dest_directory.&lt;br /&gt;&lt;br /&gt;For example:  If you have source_directory inside which you have source1, source2 two files. Now you want to synchronize the files with your directory "dest_dir" which at this moment is empty.&lt;br /&gt;&lt;br /&gt;&gt; &lt;span style="font-weight: bold; font-style: italic;"&gt;rsync -autv ./source_directory/ ./dest_dir&lt;/span&gt;&lt;br /&gt;The above command will copy source1 and source2 to ./dest_dir (since at this moment ./dest_dir is still empty, so the files inside ./source_directory is newer).&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight: bold;"&gt;What if you want to exclude ./tmp directory?&lt;br /&gt;&lt;span style="font-style: italic;"&gt;&gt; rsync -autv --exclude "tmp/" ./source_directory/ ./dest_dir&lt;br /&gt;temp &lt;/span&gt;&lt;/span&gt;is relative to the directory you are trying to backup, which is ./source_directory/ here.&lt;br /&gt;&lt;span style="font-weight: bold;"&gt;&lt;span style="font-style: italic;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;/span&gt;&lt;br /&gt;&gt; &lt;span style="font-weight: bold; font-style: italic;"&gt;rsync -autv ./source_directory  ./dest_dir&lt;/span&gt;&lt;br /&gt;However, the above command will copy ./source_directory to ./dest_dir. It copy it as a directory. After the command, inside your ./dest_dir you will have another folder called "source_directory".&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/21595493-3500177946273529107?l=linux4research.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://linux4research.blogspot.com/feeds/3500177946273529107/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=21595493&amp;postID=3500177946273529107' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/21595493/posts/default/3500177946273529107'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/21595493/posts/default/3500177946273529107'/><link rel='alternate' type='text/html' href='http://linux4research.blogspot.com/2007/03/using-rsync-to-synchronize-files.html' title='Using rsync to synchronize the files.'/><author><name>Dave</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-21595493.post-5294910273966997004</id><published>2008-09-16T07:53:00.000-05:00</published><updated>2008-09-16T07:55:33.717-05:00</updated><title type='text'>42 of the Best Free Linux Graphics Software</title><content type='html'>&lt;h1&gt;42 of the Best Free Linux Graphics Software&lt;/h1&gt;The original post is &lt;a href="http://www.linuxlinks.com/article/2008091312364896/Graphics.html"&gt;here&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;&lt;table style="text-align: left; float: left; width: 220px;" border="0" cellpadding="0" cellspacing="0"&gt;   &lt;tbody&gt;     &lt;tr&gt;       &lt;td&gt;                   &lt;br /&gt;&lt;/td&gt;     &lt;/tr&gt;   &lt;/tbody&gt; &lt;/table&gt; &lt;p&gt;Linux is a very strong platform for budding artists, photographers, animators, and designers.  With inexpensive hardware, free software, and a modicum of talent and inspiration, anyone can create professional-looking computer graphics.&lt;/p&gt; &lt;p&gt;There is a huge range of Open Source software available to create, modify and convert 2D and 3D computer graphics. To provide an insight into the software that is available, we have compiled a list of 42 high quality Linux graphics applications. The vast majority of the software featured here sports an attractive graphical front-end, although we have not neglected console based applications.&lt;br /&gt;&lt;/p&gt;&lt;p&gt;&lt;br /&gt;&lt;/p&gt;&lt;p&gt;Now, let's explore the 42 graphics applications at hand. For each title we have compiled its own portal page, providing a screenshot of the software in action, a full description with an in-depth analysis of its features, together with links to relevant resources and reviews.&lt;/p&gt;          &lt;table style="clear: none; min-width: 300pt; max-width: 600pt; background-color: rgb(255, 255, 255); width: 564px; text-align: left; margin-left: auto; margin-right: auto;" border="0" cellpadding="3" cellspacing="2"&gt;&lt;tbody&gt;&lt;tr&gt;       &lt;td colspan="2" rowspan="1" style="color: rgb(255, 255, 255); background-color: rgb(57, 0, 57);"&gt;&lt;span style="font-weight: bold;"&gt;3D Modeling and Rendering&lt;/span&gt;&lt;/td&gt;     &lt;/tr&gt;     &lt;tr&gt;       &lt;td&gt;&lt;a href="http://www.linuxlinks.com/article/20080314212427590/Art_of_Illusion.html"&gt;Art of Illusion&lt;/a&gt;&lt;/td&gt;       &lt;td&gt;3D-modeler, renderer and raytracer&lt;/td&gt;     &lt;/tr&gt;     &lt;tr&gt;       &lt;td style="background-color: rgb(247, 247, 249);"&gt;&lt;a href="http://www.linuxlinks.com/article/20070723110901522/Blender.html"&gt;Blender&lt;/a&gt;&lt;/td&gt;       &lt;td style="background-color: rgb(247, 247, 249);"&gt;Very fast and versatile 3D modeler/renderer &lt;/td&gt;     &lt;/tr&gt;     &lt;tr&gt;       &lt;td&gt;&lt;a href="http://www.linuxlinks.com/article/2007072312280657/K-3D.html"&gt;K-3D&lt;/a&gt;&lt;/td&gt;       &lt;td&gt;3D modeling and animation system&lt;/td&gt;     &lt;/tr&gt;     &lt;tr&gt;       &lt;td style="background-color: rgb(247, 247, 249);"&gt;&lt;a href="http://www.linuxlinks.com/article/20080914074634424/Pixie.html"&gt;Pixie&lt;/a&gt;&lt;/td&gt;       &lt;td style="background-color: rgb(247, 247, 249);"&gt;Photorealistic raytracing renderer for generating photorealistic images&lt;/td&gt;     &lt;/tr&gt;     &lt;tr&gt;       &lt;td&gt;&lt;a href="http://www.linuxlinks.com/article/20080914074636939/POV-Ray.html"&gt;POV-Ray&lt;/a&gt;&lt;/td&gt;       &lt;td&gt;Full-featured ray tracer&lt;/td&gt;     &lt;/tr&gt;     &lt;tr&gt;       &lt;td style="background-color: rgb(247, 247, 249);"&gt;&lt;a href="http://www.linuxlinks.com/article/20080914074637489/Radiance.html"&gt;Radiance&lt;/a&gt;&lt;/td&gt;       &lt;td style="background-color: rgb(247, 247, 249);"&gt;Suite of tools for performing lighting simulation&lt;/td&gt;     &lt;/tr&gt;     &lt;tr&gt;       &lt;td&gt;&lt;a href="http://www.linuxlinks.com/article/20080914074641273/SunFlow.html"&gt;Sunflow&lt;/a&gt;&lt;/td&gt;       &lt;td&gt;Rendering system for photo-realistic image synthesis&lt;/td&gt;     &lt;/tr&gt;     &lt;tr&gt;       &lt;td style="background-color: rgb(247, 247, 249);"&gt;&lt;a href="http://www.linuxlinks.com/article/20080914074639331/YafRay.html"&gt;YafRay&lt;/a&gt;&lt;/td&gt;       &lt;td style="background-color: rgb(247, 247, 249);"&gt;Powerful raytracer&lt;/td&gt;     &lt;/tr&gt;     &lt;tr&gt;       &lt;td&gt;&lt;br /&gt;&lt;/td&gt;       &lt;td&gt;&lt;br /&gt;&lt;/td&gt;     &lt;/tr&gt;     &lt;tr&gt;       &lt;td colspan="2" rowspan="1" style="color: rgb(255, 255, 255); background-color: rgb(57, 0, 57);"&gt;&lt;span style="font-weight: bold;"&gt;Raster Graphics Editor&lt;/span&gt;&lt;/td&gt;     &lt;/tr&gt;     &lt;tr&gt;       &lt;td&gt;&lt;a href="http://www.linuxlinks.com/article/20070724130631918/CinePaint.html"&gt;CinePaint&lt;/a&gt;&lt;/td&gt;       &lt;td&gt;Painting, manipulation and image processing&lt;/td&gt;     &lt;/tr&gt;     &lt;tr&gt;       &lt;td style="background-color: rgb(247, 247, 249);"&gt;&lt;a href="http://www.linuxlinks.com/article/20070724140959990/GIMP.html"&gt;GIMP&lt;/a&gt;&lt;/td&gt;       &lt;td style="background-color: rgb(247, 247, 249);"&gt;GNU Image Manipulation Program &lt;/td&gt;     &lt;/tr&gt;     &lt;tr&gt;       &lt;td&gt;&lt;a href="http://www.linuxlinks.com/article/20070724143611960/Gimpshop.html"&gt;Gimpshop&lt;/a&gt;&lt;/td&gt;       &lt;td&gt;Fork of GIMP mimicing Adobe Photoshop's interface&lt;/td&gt;     &lt;/tr&gt;     &lt;tr&gt;       &lt;td style="background-color: rgb(247, 247, 249);"&gt;&lt;a href="http://www.linuxlinks.com/article/20070724161833486/Krita.html"&gt;Krita&lt;/a&gt;&lt;/td&gt;       &lt;td style="background-color: rgb(247, 247, 249);"&gt;Edit and paint images&lt;/td&gt;     &lt;/tr&gt;     &lt;tr&gt;       &lt;td&gt;&lt;br /&gt;&lt;/td&gt;       &lt;td&gt;&lt;br /&gt;&lt;/td&gt;     &lt;/tr&gt;     &lt;tr&gt;       &lt;td colspan="2" rowspan="1" style="color: rgb(255, 255, 255); background-color: rgb(57, 0, 57);"&gt;&lt;span style="font-weight: bold;"&gt;Vector Graphics Editor&lt;/span&gt;&lt;/td&gt;     &lt;/tr&gt;     &lt;tr&gt;       &lt;td&gt;&lt;a href="http://www.linuxlinks.com/article/2007072405231037/Inkscape.html"&gt;Inkscape&lt;/a&gt;&lt;/td&gt;       &lt;td&gt;Vector-based drawing program&lt;/td&gt;     &lt;/tr&gt;     &lt;tr&gt;       &lt;td style="background-color: rgb(247, 247, 249);"&gt;&lt;a href="http://www.linuxlinks.com/article/20070728085841755/OpenOffice.html"&gt;OpenOffice.org Draw&lt;/a&gt;&lt;/td&gt;       &lt;td style="background-color: rgb(247, 247, 249);"&gt;Produces simple diagrams, flowcharts and 3-D artwork&lt;/td&gt;     &lt;/tr&gt;     &lt;tr&gt;       &lt;td&gt;&lt;a href="http://www.linuxlinks.com/article/20070724105721177/Xara_Xtreme.html"&gt;Xara Xtreme&lt;/a&gt;&lt;/td&gt;       &lt;td&gt;Heavyweight vector graphics, illustration and DTP program&lt;/td&gt;     &lt;/tr&gt;     &lt;tr&gt;       &lt;td style="background-color: rgb(247, 247, 249);"&gt;&lt;br /&gt;&lt;/td&gt;       &lt;td style="background-color: rgb(247, 247, 249);"&gt;&lt;br /&gt;&lt;/td&gt;     &lt;/tr&gt;     &lt;tr&gt;     &lt;/tr&gt;     &lt;tr&gt;       &lt;td style="color: rgb(255, 255, 255); background-color: rgb(57, 0, 57);" colspan="2" rowspan="1"&gt;&lt;span style="font-weight: bold;"&gt;Animation&lt;/span&gt;&lt;/td&gt;     &lt;/tr&gt;     &lt;tr&gt;       &lt;td&gt;&lt;a href="http://www.linuxlinks.com/article/200809140438210/Pencil.html"&gt;Pencil&lt;/a&gt;&lt;/td&gt;       &lt;td&gt;Create traditional hand-drawn animation using bitmap and vector graphics&lt;/td&gt;     &lt;/tr&gt;     &lt;tr&gt;       &lt;td style="background-color: rgb(247, 247, 249);"&gt;&lt;a href="http://www.linuxlinks.com/article/20080914041641301/KToon.html"&gt;Ktoon&lt;/a&gt;&lt;/td&gt;       &lt;td style="background-color: rgb(247, 247, 249);"&gt;Produce professional cartoons&lt;/td&gt;     &lt;/tr&gt;     &lt;tr&gt;       &lt;td&gt;&lt;a href="http://www.linuxlinks.com/article/20080914043739108/Synfig.html"&gt;Synfig&lt;/a&gt;&lt;/td&gt;       &lt;td&gt;Create and edit 2D animations and compositions&lt;/td&gt;     &lt;/tr&gt;     &lt;tr&gt;       &lt;td style="background-color: rgb(247, 247, 249);"&gt;&lt;br /&gt;&lt;/td&gt;       &lt;td style="background-color: rgb(247, 247, 249);"&gt;&lt;br /&gt;&lt;/td&gt;     &lt;/tr&gt;     &lt;tr&gt;       &lt;td colspan="2" rowspan="1" style="color: rgb(255, 255, 255); background-color: rgb(57, 0, 57);"&gt;&lt;span style="font-weight: bold;"&gt;Drawing&lt;/span&gt;&lt;/td&gt;     &lt;/tr&gt;     &lt;tr&gt;       &lt;td&gt;&lt;a href="http://www.linuxlinks.com/article/20070729154703795/ArgoUML.html"&gt;ArgoUML&lt;/a&gt;&lt;/td&gt;       &lt;td&gt;UML modelling tool&lt;/td&gt;     &lt;/tr&gt;     &lt;tr&gt;       &lt;td style="background-color: rgb(247, 247, 249);"&gt;&lt;a href="http://www.linuxlinks.com/article/20070729165154995/Dia.html"&gt;Dia&lt;/a&gt;&lt;/td&gt;       &lt;td style="background-color: rgb(247, 247, 249);"&gt;Diagram editor&lt;/td&gt;     &lt;/tr&gt;     &lt;tr&gt;       &lt;td&gt;&lt;a href="http://www.linuxlinks.com/article/20070722063345970/Kivio.html"&gt;Kivio&lt;/a&gt;&lt;/td&gt;       &lt;td&gt;Flowcharting program for the KDE Office Suite&lt;/td&gt;     &lt;/tr&gt;     &lt;tr&gt;       &lt;td style="background-color: rgb(247, 247, 249);"&gt;&lt;a href="http://www.linuxlinks.com/article/20070724090902964/Skencil.html"&gt;Skencil&lt;/a&gt;&lt;/td&gt;       &lt;td style="background-color: rgb(247, 247, 249);"&gt;Interactive vector drawing program&lt;/td&gt;     &lt;/tr&gt;     &lt;tr&gt;       &lt;td&gt;&lt;br /&gt;&lt;/td&gt;       &lt;td&gt;&lt;br /&gt;&lt;/td&gt;     &lt;/tr&gt;     &lt;tr&gt;       &lt;td colspan="2" rowspan="1" style="color: rgb(255, 255, 255); background-color: rgb(57, 0, 57);"&gt;&lt;span style="font-weight: bold;"&gt;Photo Management&lt;/span&gt;&lt;/td&gt;     &lt;/tr&gt;     &lt;tr&gt;       &lt;td&gt;&lt;a href="http://www.linuxlinks.com/article/20080323054551897/blueMarine.html"&gt;blueMarine&lt;/a&gt;&lt;/td&gt;       &lt;td&gt;Digital photo manipulation software&lt;/td&gt;     &lt;/tr&gt;     &lt;tr&gt;       &lt;td style="background-color: rgb(247, 247, 249);"&gt;&lt;a href="http://www.linuxlinks.com/article/20080321102840171/F-Spot.html"&gt;F-Spot&lt;/a&gt;&lt;/td&gt;       &lt;td style="background-color: rgb(247, 247, 249);"&gt;Personal photo management application&lt;/td&gt;     &lt;/tr&gt;     &lt;tr&gt;       &lt;td&gt;&lt;br /&gt;&lt;/td&gt;       &lt;td&gt;&lt;br /&gt;&lt;/td&gt;     &lt;/tr&gt;     &lt;tr&gt;       &lt;td colspan="2" rowspan="1" style="color: rgb(255, 255, 255); background-color: rgb(57, 0, 57);"&gt;&lt;span style="font-weight: bold;"&gt;Viewers&lt;/span&gt;&lt;/td&gt;     &lt;/tr&gt;     &lt;tr&gt;       &lt;td&gt;&lt;a href="http://www.linuxlinks.com/article/20070825132443569/Cornice.html"&gt;Cornice&lt;/a&gt;&lt;/td&gt;       &lt;td&gt;Designed to be a free replacement of ACDSee&lt;/td&gt;     &lt;/tr&gt;     &lt;tr&gt;       &lt;td style="background-color: rgb(247, 247, 249);"&gt;&lt;a href="http://www.linuxlinks.com/article/20080330154644929/gThumb.html"&gt;gThumb&lt;/a&gt;&lt;/td&gt;       &lt;td style="background-color: rgb(247, 247, 249);"&gt;Advanced image viewer and browser&lt;/td&gt;     &lt;/tr&gt;     &lt;tr&gt;       &lt;td&gt;&lt;a href="http://www.linuxlinks.com/article/20080312133529530/Gwenview.html"&gt;Gwenview&lt;/a&gt;&lt;/td&gt;       &lt;td&gt;Simple image viewer for KDE 4&lt;/td&gt;     &lt;/tr&gt;     &lt;tr&gt;       &lt;td style="background-color: rgb(247, 247, 249);"&gt;&lt;a href="http://www.linuxlinks.com/article/20080913200227444/EyeofGNOME.html"&gt;Eye of Gnome&lt;/a&gt;&lt;/td&gt;       &lt;td style="background-color: rgb(247, 247, 249);"&gt;Fast and functional image viewer&lt;/td&gt;     &lt;/tr&gt;     &lt;tr&gt;       &lt;td&gt;&lt;a href="http://www.linuxlinks.com/article/20070825173957890/Imgv.html"&gt;Imgv&lt;/a&gt;&lt;/td&gt;       &lt;td&gt;Powerful image viewer&lt;/td&gt;     &lt;/tr&gt;     &lt;tr&gt;       &lt;td style="background-color: rgb(247, 247, 249);"&gt;&lt;br /&gt;&lt;/td&gt;       &lt;td style="background-color: rgb(247, 247, 249);"&gt;&lt;br /&gt;&lt;/td&gt;     &lt;/tr&gt;     &lt;tr&gt;       &lt;td colspan="2" rowspan="1" style="color: rgb(255, 255, 255); background-color: rgb(57, 0, 57);"&gt;&lt;span style="font-weight: bold;"&gt;Camera&lt;/span&gt;&lt;/td&gt;     &lt;/tr&gt;     &lt;tr&gt;       &lt;td&gt;&lt;a href="http://www.linuxlinks.com/article/20080914034837498/Cheese.html"&gt;Cheese&lt;/a&gt;&lt;/td&gt;       &lt;td&gt;Take pictures and videos from your webcam&lt;/td&gt;     &lt;/tr&gt;     &lt;tr&gt;       &lt;td style="background-color: rgb(247, 247, 249);"&gt;&lt;a href="http://www.linuxlinks.com/article/20070825123954399/digiKam.html"&gt;digiKam&lt;/a&gt;&lt;/td&gt;       &lt;td style="background-color: rgb(247, 247, 249);"&gt;Digital photo management application for KDE&lt;/td&gt;     &lt;/tr&gt;     &lt;tr&gt;       &lt;td&gt;&lt;a href="http://www.linuxlinks.com/article/20080914043338277/gphoto.html"&gt;gphoto2&lt;/a&gt;&lt;/td&gt;       &lt;td&gt;Set of digital camera software applications&lt;/td&gt;     &lt;/tr&gt;     &lt;tr&gt;       &lt;td style="background-color: rgb(247, 247, 249);"&gt;&lt;a href="http://www.linuxlinks.com/article/20080914043800648/Rawstudio.html"&gt;Rawstudio&lt;/a&gt;&lt;/td&gt;       &lt;td style="background-color: rgb(247, 247, 249);"&gt;Raw-image converter and manipulation&lt;/td&gt;     &lt;/tr&gt;     &lt;tr&gt;       &lt;td&gt;&lt;br /&gt;&lt;/td&gt;       &lt;td&gt;&lt;br /&gt;&lt;/td&gt;     &lt;/tr&gt;     &lt;tr&gt;       &lt;td colspan="2" rowspan="1" style="color: rgb(255, 255, 255); background-color: rgb(57, 0, 57);"&gt;&lt;span style="font-weight: bold;"&gt;Scanning&lt;/span&gt;&lt;/td&gt;     &lt;/tr&gt;     &lt;tr&gt;       &lt;td&gt;&lt;a href="http://www.linuxlinks.com/article/20070902033212955/Kooka.html"&gt;Kooka&lt;/a&gt;&lt;/td&gt;       &lt;td&gt;Scanner program for KDE&lt;/td&gt;     &lt;/tr&gt;     &lt;tr&gt;       &lt;td style="background-color: rgb(247, 247, 249);"&gt;&lt;a href="http://www.linuxlinks.com/article/20080914071429754/Tesseract.html"&gt;Tesseract&lt;/a&gt;&lt;/td&gt;       &lt;td style="background-color: rgb(247, 247, 249);"&gt;Optical Character Recognition Engine&lt;/td&gt;     &lt;/tr&gt;     &lt;tr&gt;       &lt;td&gt;&lt;a href="http://www.linuxlinks.com/article/20080914071428380/XSane.html"&gt;XSane&lt;/a&gt;&lt;/td&gt;       &lt;td&gt;Featureful graphical frontend for SANE&lt;/td&gt;     &lt;/tr&gt;     &lt;tr&gt;     &lt;/tr&gt;     &lt;tr&gt;       &lt;td style="background-color: rgb(247, 247, 249);"&gt;&lt;br /&gt;&lt;/td&gt;       &lt;td style="background-color: rgb(247, 247, 249);"&gt;&lt;br /&gt;&lt;/td&gt;     &lt;/tr&gt;     &lt;tr&gt;       &lt;td colspan="2" rowspan="1" style="color: rgb(255, 255, 255); background-color: rgb(57, 0, 57);"&gt;&lt;span style="font-weight: bold;"&gt;CAD&lt;/span&gt;&lt;/td&gt;     &lt;/tr&gt;     &lt;tr&gt;       &lt;td&gt;&lt;a href="http://www.linuxlinks.com/article/20070725041552789/QCad.html"&gt;QCad&lt;/a&gt;&lt;/td&gt;       &lt;td&gt;Professional CAD System&lt;/td&gt;     &lt;/tr&gt;     &lt;tr&gt;       &lt;td style="background-color: rgb(247, 247, 249);"&gt;&lt;a href="http://www.linuxlinks.com/article/20070725044827558/BRL-CAD.html"&gt;BRL-CAD&lt;/a&gt;&lt;/td&gt;       &lt;td style="background-color: rgb(247, 247, 249);"&gt;Constructive Solid Geometry (CSG) solid modeling system&lt;/td&gt;     &lt;/tr&gt;     &lt;tr&gt;       &lt;td&gt;&lt;br /&gt;&lt;/td&gt;       &lt;td&gt;&lt;br /&gt;&lt;/td&gt;     &lt;/tr&gt;     &lt;tr&gt;       &lt;td colspan="2" rowspan="1" style="color: rgb(255, 255, 255); background-color: rgb(57, 0, 57);"&gt;&lt;span style="font-weight: bold;"&gt;Fractals&lt;/span&gt;&lt;/td&gt;     &lt;/tr&gt;     &lt;tr&gt;       &lt;td&gt;&lt;a href="http://www.linuxlinks.com/article/20080914071426504/Gnofract4D.html"&gt;Gnofract 4D&lt;/a&gt;&lt;br /&gt;      &lt;/td&gt;       &lt;td&gt;GNOME based fractal generator&lt;/td&gt;     &lt;/tr&gt;     &lt;tr&gt;       &lt;td style="background-color: rgb(247, 247, 249);"&gt;&lt;a href="http://www.linuxlinks.com/article/20080914071424710/XaoS.html"&gt;XaoS&lt;/a&gt;&lt;/td&gt;       &lt;td style="background-color: rgb(247, 247, 249);"&gt;Real-time interactive fractal zoomer&lt;/td&gt;     &lt;/tr&gt;     &lt;tr&gt;       &lt;td&gt;&lt;br /&gt;&lt;/td&gt;       &lt;td&gt;&lt;br /&gt;&lt;/td&gt;     &lt;/tr&gt;     &lt;tr&gt;       &lt;td style="color: rgb(255, 255, 255); background-color: rgb(57, 0, 57);" colspan="2" rowspan="1"&gt;&lt;span style="font-weight: bold;"&gt;Utilities&lt;/span&gt;&lt;/td&gt;     &lt;/tr&gt;     &lt;tr&gt;       &lt;td&gt;&lt;a href="http://www.linuxlinks.com/article/20080914071406442/Agave.html"&gt;Agave&lt;/a&gt;&lt;/td&gt;       &lt;td&gt;Colorscheme designer for the GNOME desktop&lt;/td&gt;     &lt;/tr&gt;     &lt;tr&gt;       &lt;td style="background-color: rgb(247, 247, 249);"&gt;&lt;a href="http://www.linuxlinks.com/article/20080914071338782/ImageMagick.html"&gt;ImageMagick&lt;/a&gt;&lt;/td&gt;       &lt;td style="background-color: rgb(247, 247, 249);"&gt;Software suite to create, edit, and compose bitmap images       &lt;/td&gt;&lt;/tr&gt;&lt;/tbody&gt;&lt;/table&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/21595493-5294910273966997004?l=linux4research.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://linux4research.blogspot.com/feeds/5294910273966997004/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=21595493&amp;postID=5294910273966997004' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/21595493/posts/default/5294910273966997004'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/21595493/posts/default/5294910273966997004'/><link rel='alternate' type='text/html' href='http://linux4research.blogspot.com/2008/09/42-of-best-free-linux-graphics-software.html' title='42 of the Best Free Linux Graphics Software'/><author><name>Dave</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-21595493.post-6816909433851036181</id><published>2008-07-04T10:16:00.001-05:00</published><updated>2010-11-17T20:09:40.429-06:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='Mac'/><title type='text'>HOWTO: Backup Your Mac With rsync</title><content type='html'>&lt;h1&gt;About This Document&lt;/h1&gt;  &lt;ul&gt;&lt;li&gt;Created: 26 January 2005&lt;/li&gt;&lt;li&gt;Updated: 18 December 2005: added note for Mac OS X 10.4 and general    clean up.&lt;/li&gt;&lt;li&gt;Updated: 18 February 2006: added note about using -x switch to    reduce need for specified excludes. From suggestion by Mike    Bremford.&lt;/li&gt;&lt;/ul&gt;  &lt;p&gt;Author: Matthew Phillips &lt;backup@mattp.name&gt;&lt;/p&gt;  &lt;p&gt;This document describes how to setup a system for automatically backing up a Mac (OS X 10.2 or later) to an external drive using the freely available &lt;code&gt;rsync&lt;/code&gt; utility. This applies to any kind of external drive including FireWire, USB and network drives. It does not apply to CD-R or DVD-R media. It also does not app
