<div dir="ltr">Inspired by this in Python - <a href="http://legacy.python.org/dev/peps/pep-0238">http://legacy.python.org/dev/peps/pep-0238</a><div><br></div><div>I wanted to see how easily an integer dividing operator could be added to Perl.</div>
<div><br></div><div>This implementation is a bit of a hack. I'm sure Tim'll appreciate the blessed scalar ref :P</div><div><br></div><div>What do people think? It would be nice to have first class support for custom operators in Perl, there has been some discussion on P5P but it never went anywhere - <a href="http://www.nntp.perl.org/group/perl.perl5.porters/2013/08/msg205547.html">http://www.nntp.perl.org/group/perl.perl5.porters/2013/08/msg205547.html</a></div>
<div><br></div><div><div>[jraspass@gibson ~]$ ./<a href="http://div.pl">div.pl</a></div><div>3.33333333333333</div><div>3</div><div>3.33333333333333</div><div>3</div><div>3.33333333333333</div><div>3</div><div>3.33333333333333</div>
<div>3</div></div><div><br></div><div>PS we should really get an IRC channel :)</div><div><br></div><div>James</div></div>