Popular recipes by ilon asolot http://code.activestate.com/recipes/users/4177080/2011-03-06T12:49:30-08:00ActiveState Code RecipesAttribute - easy way to define interface (Python)
2011-03-06T12:49:30-08:00ilon asolothttp://code.activestate.com/recipes/users/4177080/http://code.activestate.com/recipes/577598-attribute-easy-way-to-define-interface/
<p style="color: grey">
Python
recipe 577598
by <a href="/recipes/users/4177080/">ilon asolot</a>
(<a href="/recipes/tags/attribute/">attribute</a>, <a href="/recipes/tags/interface/">interface</a>, <a href="/recipes/tags/property/">property</a>, <a href="/recipes/tags/python/">python</a>).
</p>
<p>it is an enhanced property</p>
<pre class="prettyprint"><code> * initialize attribute in class definition scope
* easily keep the attribute behaviors in sub classes.
* easy to define interface.
* not afraid to forget the super(klass, self).__init__(...) :P
</code></pre>
Perl Script to obtain data file in a desired format (Perl)
2011-02-19T23:18:01-08:00ilon asolothttp://code.activestate.com/recipes/users/4177080/http://code.activestate.com/recipes/577582-perl-script-to-obtain-data-file-in-a-desired-forma/
<p style="color: grey">
Perl
recipe 577582
by <a href="/recipes/users/4177080/">ilon asolot</a>
.
</p>
<p>This discusses about using Perl, how we can obtain a data file in a particular desired format, given a data file in a random format. By format, we refer to the order of columns in the input data file. Using this Perl script, we obtain output data file in a particular format and we get another file having discarded data lines, based on some filtering condition.</p>