<?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-20512314</id><updated>2011-12-15T08:17:48.136+05:30</updated><title type='text'>FastCode</title><subtitle type='html'>FastCode - Quick Lookup for Small Solutions to Small Programming Problems : FastCode will have code snippets and programming tips to help me (and any one else who is interested) write code fast. Sources of these tips will be mentioned whereever possible. This is only a repository, and no more, for C, C++, Java and Python and Perl code snippets and tips. If   you want to submit tips, send me email.</subtitle><link rel='http://schemas.google.com/g/2005#feed' type='application/atom+xml' href='http://fastcode.blogspot.com/feeds/posts/default'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/20512314/posts/default?max-results=100'/><link rel='alternate' type='text/html' href='http://fastcode.blogspot.com/'/><link rel='hub' href='http://pubsubhubbub.appspot.com/'/><author><name>Atul Nene</name><uri>http://www.blogger.com/profile/02422430814424388606</uri><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>10</openSearch:totalResults><openSearch:startIndex>1</openSearch:startIndex><openSearch:itemsPerPage>100</openSearch:itemsPerPage><entry><id>tag:blogger.com,1999:blog-20512314.post-115798463619186365</id><published>2006-09-11T19:47:00.000+05:30</published><updated>2006-09-11T19:53:56.210+05:30</updated><title type='text'>The Software Development Process</title><content type='html'>Here are a few quotes I found out there that I thought make sense:&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight:bold;"&gt;Quote 1&lt;/span&gt;:&lt;br /&gt;The game says there is a "process" that takes "inputs", generates "subtasks", and "schedules", which go to "motivated programmers" that "follow the clear directions", and use "laest tools" to generate "quality code" that can be "integrated" and "tested" and "shipped".&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight:bold;"&gt;Quote 2&lt;/span&gt;:&lt;br /&gt;Whatever you do, choose a process with rapid prototyping and testing that also allows for the specification to be changed because the majority of the bugs will be in there.&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight:bold;"&gt;Quote 3&lt;/span&gt;:&lt;br /&gt;People may write requirements in abundance but they do not write what they need the system to do and which functionality they prefer over the vast list "essential" features! That part is discovered during the development. If your process is cheap, you can work your way out of it - if it is "formal" you will die under a mountain of papers, inspection records, progress meetings and what not.&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight:bold;"&gt;Quote 4&lt;/span&gt;:&lt;br /&gt;Program bottom-up until it works. Then go top-down and clean it up.&lt;br /&gt;Most people just skip that last step.&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight:bold;"&gt;Quote 5&lt;/span&gt;:&lt;br /&gt;0. Plan the code&lt;br /&gt;1. Write code&lt;br /&gt;2. Read code&lt;br /&gt;3. Test code&lt;br /&gt;4. Release&lt;br /&gt;but most people skip 2, sometimes 3. Also, if you program bottom-up, 0 is a continuous process.&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight:bold;"&gt;Quote 6&lt;/span&gt;:&lt;br /&gt;The fastest way to get it working is to slow down and do it right the first time.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/20512314-115798463619186365?l=fastcode.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://fastcode.blogspot.com/feeds/115798463619186365/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=20512314&amp;postID=115798463619186365' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/20512314/posts/default/115798463619186365'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/20512314/posts/default/115798463619186365'/><link rel='alternate' type='text/html' href='http://fastcode.blogspot.com/2006/09/software-development-process.html' title='The Software Development Process'/><author><name>Atul Nene</name><uri>http://www.blogger.com/profile/02422430814424388606</uri><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-20512314.post-114163165612459032</id><published>2006-03-06T13:20:00.000+05:30</published><updated>2006-03-06T13:24:16.136+05:30</updated><title type='text'>C++ | 'Good Classes' should have virtual destructors</title><content type='html'>&lt;span style="font-family: courier new;"&gt;I know this sounds like "Good boys should behave BLA BLA BLA" but heres why :)&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style="font-family: courier new;"&gt;When you write a class, make sure you write a virtual destructor for it. Also, when you want to subclass an existing class, make sure the parent class has a virtual destructor(s). &lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style="font-family: courier new;"&gt;Pointers and references to the base class object can actually point to a derived class object. If the derived class object is deleted using the base class pointer and the destructor of the base class is virtual, the destructor chain (through all subclasses) will be called. Therefore, one should publicly inherit only from classes with virtual destructors. &lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style="font-family: courier new;"&gt;Heres a bad example :&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style="font-family: courier new;"&gt;class Base { &lt;/span&gt;&lt;br /&gt;&lt;span style="font-family: courier new;"&gt;  public: ~Base()  {  // non virtual&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family: courier new;"&gt;    // ... &lt;/span&gt;&lt;br /&gt;&lt;span style="font-family: courier new;"&gt;  } &lt;/span&gt;&lt;br /&gt;&lt;span style="font-family: courier new;"&gt;}; &lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style="font-family: courier new;"&gt;class Derived: public Base  { // yikes ! parent has a non virtual destructor&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family: courier new;"&gt;  public: ~Derived() { &lt;/span&gt;&lt;br /&gt;&lt;span style="font-family: courier new;"&gt;    // ... &lt;/span&gt;&lt;br /&gt;&lt;span style="font-family: courier new;"&gt;  } &lt;/span&gt;&lt;br /&gt;&lt;span style="font-family: courier new;"&gt;}; &lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style="font-family: courier new;"&gt;int main() { &lt;/span&gt;&lt;br /&gt;&lt;span style="font-family: courier new;"&gt;  Base * p = new Derived; //seems OK&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family: courier new;"&gt;  delete p; //trouble, Derived's destructor not called&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family: courier new;"&gt;} &lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style="font-family: courier new;"&gt;So be sure to double check this recommendation everytime you write a new class or inherit from an existing one. &lt;/span&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/20512314-114163165612459032?l=fastcode.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://fastcode.blogspot.com/feeds/114163165612459032/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=20512314&amp;postID=114163165612459032' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/20512314/posts/default/114163165612459032'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/20512314/posts/default/114163165612459032'/><link rel='alternate' type='text/html' href='http://fastcode.blogspot.com/2006/03/c-good-classes-should-have-virtual.html' title='C++ | &apos;Good Classes&apos; should have virtual destructors'/><author><name>Atul Nene</name><uri>http://www.blogger.com/profile/02422430814424388606</uri><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-20512314.post-113920530052165936</id><published>2006-02-06T11:20:00.000+05:30</published><updated>2006-02-06T11:27:44.443+05:30</updated><title type='text'>C++ |  What are Smart Pointers Anyway ?</title><content type='html'>&lt;span style="font-family:courier new;"&gt;Smart pointers are objects which store pointers to dynamically allocated (heap)     objects. They behave much like built-in C++ pointers except that they     automatically delete the object pointed to at the appropriate time. &lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style="font-family:courier new;"&gt;Conceptually, smart pointers are seen as owning the object pointed to, and thus     responsible for deletion of the object when it is no longer needed.&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style="font-family:courier new;"&gt;Smart Pointers (currently Boost Smart Pointers), are expected to make their way to the C++ Standard. You can find all relevant details at &lt;a href="http://boost.org/libs/smart_ptr/smart_ptr.htm"&gt;http://boost.org/libs/smart_ptr/smart_ptr.htm&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/20512314-113920530052165936?l=fastcode.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://fastcode.blogspot.com/feeds/113920530052165936/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=20512314&amp;postID=113920530052165936' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/20512314/posts/default/113920530052165936'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/20512314/posts/default/113920530052165936'/><link rel='alternate' type='text/html' href='http://fastcode.blogspot.com/2006/02/c-what-are-smart-pointers-anyway.html' title='C++ |  What are Smart Pointers Anyway ?'/><author><name>Atul Nene</name><uri>http://www.blogger.com/profile/02422430814424388606</uri><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-20512314.post-113871127804912037</id><published>2006-01-31T18:05:00.000+05:30</published><updated>2006-01-31T18:11:18.060+05:30</updated><title type='text'>Python | Declaring 'Class' and 'Instance' variables</title><content type='html'>&lt;span style="font-family: courier new;"&gt;How should one declare 'class' and 'instance' variables in Python ?&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style="font-family: courier new;"&gt;Well, in Python, assignment is declaration. You just need to assign the variables in the appropriate place. &lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style="font-family: courier new;"&gt;If you intend to declare a 'class' variable, that is, a variable stored for the class and accessible through each instance, you code 'name = value' for that variable inside the class statement. &lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style="font-family: courier new;"&gt;If you intend to declare a separate attribute for each instance, you code 'name = value' for that variable it in the '__init__' method.&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family: courier new;"&gt; &lt;/span&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/20512314-113871127804912037?l=fastcode.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://fastcode.blogspot.com/feeds/113871127804912037/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=20512314&amp;postID=113871127804912037' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/20512314/posts/default/113871127804912037'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/20512314/posts/default/113871127804912037'/><link rel='alternate' type='text/html' href='http://fastcode.blogspot.com/2006/01/python-declaring-class-and-instance.html' title='Python | Declaring &apos;Class&apos; and &apos;Instance&apos; variables'/><author><name>Atul Nene</name><uri>http://www.blogger.com/profile/02422430814424388606</uri><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-20512314.post-113811211458280107</id><published>2006-01-24T19:38:00.000+05:30</published><updated>2006-01-24T19:45:14.596+05:30</updated><title type='text'>Python | Socket Starter</title><content type='html'>&lt;span style="font-family: courier new;"&gt;I dont know why, but almost every programmer who learns a new language want's to program sockets right away.  If you are one of these species, and you've just learnt python, here's how it can be done. Very simple really.&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style="font-family: courier new;font-size:100%;" &gt;import sockets&lt;br /&gt;&lt;/span&gt;&lt;span style="font-family: courier new;font-size:100%;" &gt;session = socket.socket(socket.AF_INET, socket.SOCK_STREAM)&lt;br /&gt;&lt;/span&gt;&lt;span style="font-family: courier new;font-size:100%;" &gt;session.connect((ipaddress, port))&lt;br /&gt;&lt;br /&gt;thats it !&lt;br /&gt;&lt;br /&gt;Of course you will need to understand more than that. So here's a URL for you.&lt;br /&gt;&lt;/span&gt;&lt;span style="font-family: courier new;font-size:100%;" &gt;&lt;a href="http://heather.cs.ucdavis.edu/%7Ematloff/Python/PyNet.pdf"&gt;http://heather.cs.ucdavis.edu/~matloff/Python/PyNet.pdf&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/20512314-113811211458280107?l=fastcode.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://fastcode.blogspot.com/feeds/113811211458280107/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=20512314&amp;postID=113811211458280107' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/20512314/posts/default/113811211458280107'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/20512314/posts/default/113811211458280107'/><link rel='alternate' type='text/html' href='http://fastcode.blogspot.com/2006/01/python-socket-starter.html' title='Python | Socket Starter'/><author><name>Atul Nene</name><uri>http://www.blogger.com/profile/02422430814424388606</uri><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-20512314.post-113801485128439794</id><published>2006-01-23T16:31:00.000+05:30</published><updated>2006-01-23T16:44:11.330+05:30</updated><title type='text'>C | C++ | Python | Control Rounding when converting Floats to Integers</title><content type='html'>&lt;span style="font-family: courier new;"&gt;I have faced this problem in the past, but had not thought of a solution yet. Was chatting with a friend lately, and he suggested a very simple idea.&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style="font-family: courier new;"&gt;The problem is that when converting Floats to Integers, they always round down. But you want them to round up sometimes, for whatever reason. You could do this :&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style="font-family: courier new;"&gt;Integer = Float + 0.5f&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family: courier new;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family: courier new;"&gt;This will add .5 to the float number, and it will round down to either trunc (float) or trunc (float + 1).&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family: courier new;"&gt;&lt;br /&gt;Thus, 1.1 rounds to 1, and 1.7 to 2. You get the idea.&lt;/span&gt;&lt;span style="font-family: courier new;"&gt;&lt;/span&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/20512314-113801485128439794?l=fastcode.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://fastcode.blogspot.com/feeds/113801485128439794/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=20512314&amp;postID=113801485128439794' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/20512314/posts/default/113801485128439794'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/20512314/posts/default/113801485128439794'/><link rel='alternate' type='text/html' href='http://fastcode.blogspot.com/2006/01/c-c-python-control-rounding-when.html' title='C | C++ | Python | Control Rounding when converting Floats to Integers'/><author><name>Atul Nene</name><uri>http://www.blogger.com/profile/02422430814424388606</uri><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-20512314.post-113775341072452215</id><published>2006-01-20T16:00:00.000+05:30</published><updated>2006-01-20T16:07:58.860+05:30</updated><title type='text'>C++ | Be careful when writing assignment operators</title><content type='html'>&lt;span style="font-family:courier new;"&gt;If you are writing an assignment operator for a class, be very careful and ensure each of the following :&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style="font-family:courier new;"&gt;- that you have copied all the attributes&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:courier new;"&gt;- that you have allocated new memory for each non-stack attribute (i.e. pointer variable) before copying it.&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style="font-family:courier new;"&gt;The second one is the one where most mistakes are made. One tends to copy the address pointed to by the source variable into the destination variable, which is perfectly legal but rarely intended. And then somewhere during runtime, the address in the source copy is freed and later, the address in the destination copy is accessed. And then guess what happens !&lt;/span&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/20512314-113775341072452215?l=fastcode.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://fastcode.blogspot.com/feeds/113775341072452215/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=20512314&amp;postID=113775341072452215' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/20512314/posts/default/113775341072452215'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/20512314/posts/default/113775341072452215'/><link rel='alternate' type='text/html' href='http://fastcode.blogspot.com/2006/01/c-be-careful-when-writing-assignment.html' title='C++ | Be careful when writing assignment operators'/><author><name>Atul Nene</name><uri>http://www.blogger.com/profile/02422430814424388606</uri><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-20512314.post-113766273183767025</id><published>2006-01-19T14:44:00.000+05:30</published><updated>2006-01-20T16:09:39.376+05:30</updated><title type='text'>Python | limiting lines to 80 chars ? Are you crazy ? Is this COBOL or what ?</title><content type='html'>&lt;span style="font-family:courier new;"&gt;A Python Style Question : &lt;/span&gt;&lt;span style=";font-family:courier new;font-size:100%;"  &gt;according to PEP-8 &lt;a href="http://www.python.org/peps/pep-0008.html"&gt;http://www.python.org/peps/pep-0008.html&lt;/a&gt; lines should have a max of 79 characters because "There are still many devices around that are limited to 80 character lines".  My question is this, should i try and force myself to write code in this style?&lt;br /&gt;&lt;br /&gt;Answers :&lt;br /&gt;&lt;br /&gt;1. &lt;/span&gt;&lt;span style=";font-family:courier new;font-size:100%;"  &gt;Follow it wherever possible, &lt;/span&gt;&lt;span style=";font-family:courier new;font-size:100%;"  &gt;a better reason to follow that is that longer lines are harder to read.&lt;br /&gt;2. &lt;/span&gt;&lt;span style=";font-family:courier new;font-size:100%;"  &gt;I don't count mine at all, &lt;/span&gt;&lt;span style=";font-family:courier new;font-size:100%;"  &gt;however I try to keep them short enough to read easily&lt;br /&gt;3. &lt;/span&gt;&lt;span style=";font-family:courier new;font-size:100%;"  &gt;That style guide is for code in the mainline python, &lt;/span&gt;&lt;span style=";font-family:courier new;font-size:100%;"  &gt;that document doesn't suggest that *your* code should follow that guide&lt;br /&gt;4. &lt;/span&gt;&lt;span style=";font-family:courier new;font-size:100%;"  &gt;I do work on 80 char terminals at times and yeah, it's very annoying when lines wrap &lt;/span&gt;&lt;span style=";font-family:courier new;font-size:100%;"  &gt;but even if I'm in X, I find long lines difficult to read. &lt;/span&gt;&lt;span style=";font-family:courier new;font-size:100%;"  &gt;Also, short lines make interactive debugging easier.&lt;/span&gt;&lt;br /&gt;&lt;span style=";font-family:courier new;font-size:100%;"  &gt;&lt;br /&gt;&lt;/span&gt;&lt;span style=";font-family:courier new;font-size:100%;"  &gt;Fundamentally, writing readable code is more about common sense than following style guides, they &lt;/span&gt;&lt;span style=";font-family:courier new;font-size:100%;"  &gt;cannot account for every contingency, and, like all things, are imperfect.&lt;br /&gt;&lt;br /&gt;&lt;/span&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/20512314-113766273183767025?l=fastcode.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://fastcode.blogspot.com/feeds/113766273183767025/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=20512314&amp;postID=113766273183767025' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/20512314/posts/default/113766273183767025'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/20512314/posts/default/113766273183767025'/><link rel='alternate' type='text/html' href='http://fastcode.blogspot.com/2006/01/python-limiting-lines-to-80-chars-are.html' title='Python | limiting lines to 80 chars ? Are you crazy ? Is this COBOL or what ?'/><author><name>Atul Nene</name><uri>http://www.blogger.com/profile/02422430814424388606</uri><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-20512314.post-113645286365318433</id><published>2006-01-05T14:46:00.000+05:30</published><updated>2006-01-05T15:21:14.203+05:30</updated><title type='text'>C|C++|The correct way to include header files</title><content type='html'>&lt;span style="font-family:courier new;"&gt;&lt;code&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:courier new;"&gt;The compiler searches for the files in different locations based on the the way they are included.&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:courier new;"&gt;If included with &lt; &gt; , it searches in the predefined include path, and if included with " ", then it searches in the current directory.&lt;br /&gt;Examples :&lt;br /&gt;&lt;br /&gt;#include &lt;&gt;&lt;stdio.h&gt;&lt;br /&gt;#include "mymodule.h"&lt;br /&gt;&lt;/stdio.h&gt;&lt;/span&gt;&lt;span style="font-family:courier new;"&gt;&lt;/code&gt;&lt;br /&gt;&lt;/span&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/20512314-113645286365318433?l=fastcode.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://fastcode.blogspot.com/feeds/113645286365318433/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=20512314&amp;postID=113645286365318433' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/20512314/posts/default/113645286365318433'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/20512314/posts/default/113645286365318433'/><link rel='alternate' type='text/html' href='http://fastcode.blogspot.com/2006/01/ccthe-correct-way-to-include-header.html' title='C|C++|The correct way to include header files'/><author><name>Atul Nene</name><uri>http://www.blogger.com/profile/02422430814424388606</uri><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-20512314.post-113635900340278064</id><published>2006-01-04T12:40:00.000+05:30</published><updated>2006-01-05T14:51:46.886+05:30</updated><title type='text'>Python| get a string of all the lowercase letters ['a'..'z']</title><content type='html'>&lt;span style=";font-family:courier new;font-size:100%;"  &gt;1. string.lowercase&lt;br /&gt;&lt;br /&gt;2. &lt;/span&gt;&lt;span style=";font-family:courier new;font-size:100%;"  &gt;chr(n) for n in range(ord('a'), ord('z')+1)&lt;/span&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/20512314-113635900340278064?l=fastcode.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://fastcode.blogspot.com/feeds/113635900340278064/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=20512314&amp;postID=113635900340278064' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/20512314/posts/default/113635900340278064'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/20512314/posts/default/113635900340278064'/><link rel='alternate' type='text/html' href='http://fastcode.blogspot.com/2006/01/python-get-string-of-all-lowercase.html' title='Python| get a string of all the lowercase letters [&apos;a&apos;..&apos;z&apos;]'/><author><name>Atul Nene</name><uri>http://www.blogger.com/profile/02422430814424388606</uri><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></feed>
