Skip to main content

Ralsina.Me — Roberto Alsina's website

Tus Amigos

Sor­ry, span­ish on­ly.


http://www.pescadopodrido.com/imagenes/politica/principal/DICTADOR%20costa%20pobre.jpg

Miren la ban­da.

No ten­go mu­chos ami­gos. Ten­go tres o cu­a­tro, ponéle. Se­guro no más de 10. Ten­go mu­chos cono­ci­dos, ten­go mucha gente que me cae bi­en, habrá al­guno que le cai­go bi­en, habrá otros que me cono­cen. He tenido ami­gos que nun­ca ví, ten­go ami­gos que nun­ca veo, ten­go ami­gos que nun­ca voy a ver porque tu­vieron la mala idea de morirse antes que los vea.

Ten­go ami­gos que quiero mu­cho, ten­go ami­gos que me ca­gan de risa, ten­go ami­gos y ten­go ami­gas, ten­go al­gu­na her­mana pos­ti­za que la quiero co­mo si fuera mi hí­gado, ten­go mi es­posa que es más ami­ga, ten­go ami­gos que quisiera ver más.

Hay ami­gos que no me cono­cen, pero si al­guien te re­gala un li­bro que te cam­bia la vi­da, o una can­ción que te lev­an­ta a la mañana, o un pro­gra­ma de ra­dio que te hace olvi­dar to­das las noches la bosta que fué el día, es­os son ami­gos míos, aunque yo no sea ami­go suy­o.

Hay gente que no conoz­co que me ha agrade­ci­do al­gu­na cosa que hice y supon­go que yo seré ami­go suyo aunque no sean ami­gos míos. A el­los les di­go que son ami­gos míos tam­bién.

No ten­go ami­gos de la in­fan­ci­a, no ten­go ami­gos de la ado­les­cen­ci­a, ten­go al­gún ami­go de mis vein­tipi­co, ten­go más de mis trein­tas, to­davía no ten­go uno de los cuarentayp­i­co. Ten­go ami­gos en otros país­es, ten­go ami­gos acá al la­do. Ten­go pocos pero son vari­a­dos. Ten­go pocos pero son los mejores.

Y cuan­do me muer­a, si me ha­cen la gaucha­da de no morirse antes el­los, ojalá ten­ga una coro­na que di­ga: Tus Ami­gos. Y se la destapen y se la tomen, los putos.

Y U So Serious?

http://farm8.staticflickr.com/7047/6823423920_94a9682eea.jpg

Hel­lo? I am the guy that posts about twin ba­nanas!

Since I de­cid­ed to stop be­ing a troll (I am try­ing!) I no­ticed that peo­ple take what I write waaaaay too se­ri­ous­ly. This post is a gen­tle re­minder that I have post­ed more about sil­ly stuff than about se­ri­ous stuff. MUCH more.

So, if you ev­er find your­self think­ing "Hey, Rober­to seems to be mak­ing an in­ter­est­ing point", first think about the twin ba­nanas. If what I wrote still looks in­ter­est­ing, pro­ceed.

Your Editor is Not the Bottleneck

This may cause some pal­pi­ta­tions in some friends of mine who laugh at me for us­ing kwrite, but it re­al­ly is not. Any time you spend con­fig­ur­ing, choos­ing, ad­just­ing, tweak­ing, chang­ing, im­prov­ing, patch­ing or get­ting used to your ed­i­tor is time in­vest­ed, for which you need to show a ben­e­fit, or else it's time wast­ed.

Let's look at SLOC, which while dis­cred­it­ed as a mea­sure of pro­gram­mer's pro­duc­tiv­i­ty, sure­ly does work as a mea­sure of how much a pro­gram­mer types, right?

Well, es­ti­mates of to­tal code pro­duc­tion across the life­time of a prod­uct vary (just take the SLOC of the pro­duc­t, di­vide by men/­days spen­t), but they are usu­al­ly some­thing be­tween 10 and 100 SLOC per pro­gram­mer per day. Let's be gen­er­ous and say 200.

So, 200 lines in eight hours. That's rough­ly one line ev­ery two min­utes, and the av­er­age line of code is about 45 char­ac­ter­s. Since I as­sume you are a com­pe­tent typ­ist (if you are not, shame on you!), it takes less than 20 sec­onds to type that.

So, typ­ing, which is what you of­ten tweak in your ed­i­tor, takes less than 15% of your time. And how much faster can it get? Can you get a line writ­ten in 10 sec­ond­s? Then you just saved 8% of your day. And re­al­ly, does your ed­i­tor isave you half the typ­ing time?

How much time do you lose hav­ing your eyes won­der over the side­bars, but­ton­s, tool­bars, etc?

So while yes, typ­ing faster and more ef­fi­cient­ly is an op­ti­miza­tion, it may al­so be pre­ma­ture, in that, what the hell are we do­ing the oth­er 80% of the time? Is­n't there some­thing we can do to make that huge chunck of time more ef­fi­cient in­stead of the small­er chunk?

Well, I think we spent most of that time do­ing three things:

  1. Read­­ing code

  2. Think­ing about what code to write

  3. Fix­ing what we wrote in that oth­­er 20%

The first is easy: we need bet­ter code read­ers not ed­i­tors. It's a pity that the main in­ter­face we get for look­ing at code is an ed­i­tor, with its con­stant lure to­wards just chang­ing stuff. I think there is a lost op­por­tu­ni­ty there some­where, for an app where you can look at the code in orig­i­nal or in­ter­est­ing ways, so that you un­der­stand the code bet­ter.

The sec­ond is hard­er, be­cause it's per­son­al. I walk. If you see me walk­ing while my ed­i­tor is open, I am think­ing. Af­ter I think, I write. Your mileage may vary.

The third is by far the hard­est of the three. For ex­am­ple, au­to­com­plete helps there, be­cause you won't mistype things, which is in­ter­est­ing, but more pow­er­ful ap­proach­es ex­ist, like con­stant run­ning of tests suites while you ed­it. Ev­ery time you leave a line, trig­ger the af­fect­ed parts of the suit­e.

That's much hard­er than it sound­s, since it means your tools need to cor­re­late your test suite to your code very tight­ly, so that you will see you are break­ing stuff the sec­ond you break it, not min­utes lat­er.

Al­so, it should en­able you to jump to the test with a keystroke, so that you can fix those tests if you are chang­ing be­hav­iour in your code. And of course it will mean you need tests ;-)

Which brings me to a pet peeve of mine, that ed­i­tors still treat the file as the unit of work, which makes no sense at al­l. You nev­er want to ed­it a file, you want to ed­it a func­tion, or a class, or a method, or a con­stant but nev­er a file. Know­ing this was the sheer ge­nius of an­cient Vis­ual Ba­sic, which was com­plete­ly ig­nored by all the snobs look­ing down at it.

So, in­stead of tweak­ing your ed­i­tor, get me a tool that does what I need please. I have been wait­ing for it since VB 1.0. And a sand­wich.

warn­ing

This post is 99% lies, but I want to hear the ar­gu­ments against it. If I tell you now it does­n't count as a re­al lie, I have learned from fi­nan­cial press ;-)

UP­DATE: In­ter­est­ing dis­cus­sions in red­dit and hack­er news


Contents © 2000-2020 Roberto Alsina