<div dir="ltr"><div class="gmail_default" style="font-family:arial,helvetica,sans-serif;font-size:small">Since Ruby seems to rank highly for you, Python might be worth a look - people who know both say they are similar, but seem to generate partisan feeling. <br></div></div><div class="gmail_extra"><br><div class="gmail_quote">On Sat, May 7, 2016 at 11:20 AM, Leam Hall <span dir="ltr"><<a href="mailto:leamhall@gmail.com" target="_blank">leamhall@gmail.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">I just read a chapter (1) on Bayes and decision making. Wanted to try it out on a conundrum I've been wrangling for some long period of time: "What's the best programming language for me?" Posting here for feedback and critique, many of you are smarter than I.<br>
<br>
Not evaluating any language on pure technical merit, but on personal measures. Starting with X measures, and assigning them percentages in blocks of 25. So a value can be 0, 25%, 50%, 75%, or 100%, and a maximum total of 100% * measures with an average of total/measures. Using large blocks helps prevent analysis paralysis.<br>
<br>
The current measures are:<br>
<br>
Is it suitable to the sort of things I want to do?<br>
For example, Assembler isn't as suited for interactive web pages.<br>
Possible, but not suited.<br>
Assumes I know what I want to do.<br>
<br>
How quickly can I produce something?<br>
Assumes I have put 20+ serious hours into learning it. (2)<br>
Produce output; web pages, computation, whatever.<br>
<br>
Do I enjoy that language?<br>
If you enjoy it you're more likely to do it, which is how<br>
you get better at it.<br>
Enjoyment also helps overall life outlook.<br>
<br>
Does it help me achieve my goals?<br>
Whatever your goals are, does this contribute to achieving them?<br>
Assumes I have concrete goals.<br>
<br>
<br>
So, let's play with some options. C, Ruby, Perl, Shell.<br>
<br>
Most of what I want to do involves text wrangling; straight text, some XML, and the occasional database query. Almost all of it is for human consumption either primarily or secondarily. Scores for this might be:<br>
<br>
C 25 (A lot more effort than scripting)<br>
Ruby 100<br>
Perl 100<br>
Shell 50 (Harder to do XML and SQL)<br>
<br>
Looking at what I want to do, how quickly can I produce something? In my case the base test is "run a program that produces a valid character for the Traveller RPG".<br>
<br>
C 25 (My C is weak, even after months)<br>
Ruby 100 (Already have base code)<br>
Perl 25 (I have forgotten most of my PERL)<br>
Shell 50 (There's a SQLite call I don't know)<br>
<br>
Now a very subjective test; how much do I really enjoy coding in that language? To me this might even have a heavier weight than many measures. However, since we're only using a few, and since they are all pretty significant, it stays equal.<br>
<br>
C 25<br>
Ruby 75<br>
Perl 0 (I actually got nauseous the last time I tried)<br>
Shell 50 Boring.<br>
<br>
Lastly, does it help me achieve my goal(s)? My real goal is to stay gainfully employed until I croak. Retirement is for people who forget they won't be able to do what they can do now, then. I enjoy my work and want to keep doing it.<br>
<br>
C 75<br>
Ruby 75<br>
Perl 75<br>
Shell 100<br>
<br>
<br>
Assuming my pen and paper calculations are correct (3), that gives a probably if "best" as:<br>
<br>
C 37.5<br>
Ruby 87.5<br>
Perl 50.0<br>
Shell 62.5<br>
<br>
Other languages have their merit; Python and Go quickly come to mind. PHP is big as well. You would likely choose different measures and different languages.<br>
<br>
Thoughts?<br>
<br>
Leam<br>
<br>
<br>
1. Duhigg, Charles "Smarter, Faster, Better" (2016). Chapter 6 "Decision Making"<br>
<br>
2. Kaufman, Josh "The First 20 Hours: How to Learn Anything...Fast" (2014)<br>
<br>
3. Added on paper and then irb to get the average. :)<br>
_______________________________________________<br>
Ale mailing list<br>
<a href="mailto:Ale@ale.org" target="_blank">Ale@ale.org</a><br>
<a href="http://mail.ale.org/mailman/listinfo/ale" rel="noreferrer" target="_blank">http://mail.ale.org/mailman/listinfo/ale</a><br>
See JOBS, ANNOUNCE and SCHOOLS lists at<br>
<a href="http://mail.ale.org/mailman/listinfo" rel="noreferrer" target="_blank">http://mail.ale.org/mailman/listinfo</a><br>
</blockquote></div><br><br clear="all"><br>-- <br><div class="gmail_signature">Pete Hardie<br>--------<br>Better Living Through Bitmaps</div>
</div>