jaytea commented on a Page, Simple Notice Join/Part  -  Aug 11, 2011

Dean's version:

$read(file.txt,$rand(1,$lines(file.txt)))

Jethro's version:

$read(file.txt)

these are not the same, just as those 2 on TEXT events are not the same. aside from the obvious extra '$' in Dean's code, remember that '\s' also matches a tab, and '/join#chan' is obviously an incorrect command. but this is such a minor detail that i almost feel silly pointing it out ;P

if i see someone post a code that is simple and serves as a decent example given the overall circumstances, and i notice that it is not perfectly accurate and liable to fail on approximately 0.00001% of all realistic use cases, am i really doing them a service by mentioning it? might the result of me mentioning it lead to confusion and detract from the actual purpose of the code? or, worse yet, will it lead to beginner scripters worrying more about how to make their scripts 0.00001% better rather than focusing on improving their knowledge in leaps and bounds? these are things we all need to think about. it's a tricky business!

and what's the deal with the gratuitous bumping of old posts?

 Respond  
Are you sure you want to unfollow this person?
Are you sure you want to delete this?
Click "Unsubscribe" to stop receiving notices pertaining to this post.
Click "Subscribe" to resume notices pertaining to this post.