Sunday, December 30, 2012

Books I read (2012)

January
- Estructura de la informació. UOC. (2nd time)
- Estructura i tecnologia de computadors. UOC. (2nd time)

February
- Working Effectively with Legacy Code, Michael Feathers
- La acabadora, (Accabadora) Michela Murgia

March
- Thinking in C++, Volume 1, 2nd edition, Bruce Eckel
- Refactoring: Improving the Design of Existing Code, Martin Fowler, Kent Beck, John Brant, William Opdyke, Don Roberts

April
- Midnight's Children, Salman Rushdie

May
- En el último azul, (Dins el darrer blau) Carme Riera
- El etrusco, (Turms kuolematon) Mika Waltari
- La soledad de los números primos, (La solitudine dei numeri primi) Paolo Giordano
- Teoria d'autòmats i llenguatges formals I. UOC.
- Estructura de computadors. UOC.

June
- White teeth, Zadie Smith
- Estructura de computadors. UOC. (2nd time)
- Teoria d'autòmats i llenguatges formals I. UOC. (2nd time)

July
- Design Patterns: Elements of Reusable Object-Oriented Software, Gamma, Helm, Johnson and Vlissides

August
- The Mythical Man-Month: Essays on Software Engineering, Frederick P. Brooks
- Firmin, Sam Savage

September
- Growing Object-Oriented Software, Guided by Tests. Steve Freeman and Nat Pryce

October
- Domain-Driven Design Quick, InfoQ

November
- Object Design. Roles, Responsibilities and Collaborations. Rebecca Wirfs-Brock and Alan Mckean

December
- Think Python. How to Think Like a Computer Scientist. Allen B. Downey, Jeffrey Elkner and Chris Meyers
- Matemàtica discreta. UOC.

Saturday, December 29, 2012

Articles and Posts read

Inspiring
La solidaridad baja a los barrios
Get back to normal life with DIY prosthetic fingers

Learning and software craftsmanship
“TDD ignores the design” “No it doesn’t” “Yes it does” – Part 1
“TDD ignores the design” “No it doesn’t” “Yes it does” – Part 2
A good name is about an idea, not an implementation
OOP Isn't a Fundamental Particle of Computing
Small Design Up Front & XP
Is Design Dead?
Programming Languages Have Social Mores Not Idioms
Rough Cut
My comments about “20 controversial programming opinions”
Favor query objects over repositories
Testing with queries and repositories (a simple example)
Starting a new game project? Ask the hard questions first
Return of the Horizontal Slice
Impact of Continuous Integration on Team Culture
Fixing Legacy: What Should I Blow Up First?
Naming From the Outside In
When "What" questions presuppose "How"
STRANGELOOP 2: The future of DataBases is in memory
A rare retrospective on a decade-long research project
Aprende ya mismo a auto-formarte o te convertirás en una momia tecnológica en pocos años, o meses
The Experience Gap
OMG, Test Driven Development Actually Works!
The Ultimate Code Kata

Agile and Lean
I Want Answers Now!
Ojo, que agilidad y lean no son exactamente lo mismo, aunque se parezcan mucho (dejo 5 diferencias)

C++
A Real Renaissance
The C++ Product Roadmap

JavaScript
Intermediate JavaScript
JavaScript Unit Tests: Jasmine vs Mocha
Creación de objetos eficiente en JavaScript

Entrepreneurship and Management
Working Long? Rethink Why
Trabajar desde casa es trabajar más
So Professional That It’s Unprofessional
What Programmers Want Is Less Stupid And More Programming
Radical leadership advice
Nobody’s going to steal your idea

Software Development in Spain
Los problemas del desarrollo web en España resumidos en senado.es
La web del Senado ha costado medio millón de euros ¿están justificados?

Rebooting Spain
Racionalizar horarios y volver a Greenwich es urgente
Invertir en ciencia... por nuestros hijos

Science
Scientists Identify Gene Required for Nerve Regeneration

Spain and Europe
Viñeta de El Roto del 14 de noviembre de 2012
El aumento de la pobreza severa coloca a España como el tercer país de la UE en desigualdad social
"Éste es un país de chorizos"; de muestra los 68 asesores sin graduado escolar de Rajoy
La privatización de hospitales en Madrid abre un negocio de 400 millones de euros
La privatización de la sanidad en Reino Unido ha demostrado ser más costosa
Investigadores del CSIC denuncian en la UE la situación de la ciencia en España

Wednesday, December 19, 2012

Last Pet Project: Zambombator

Lately I've been developing an Android application with some friends.
Besides learning a bit about Android programming, we wanted to know the whole process of shipping an application to the Android market.
Zambombator is a very simple application that makes zambomba noises when you shake it. A zambomba is a typical Spanish Christmas instrument.
It was great fun developing it and I hope it'll be great fun playing zambomba this Christmas as well. You can get it for free in Google Play.

Sunday, December 16, 2012

Articles and Posts read

Inspiring
My advice to young people - Donald Knuth
Handshake with a clown
"Nadie debe cobrar más de 20 veces el salario mínimo"

Learning and software craftsmanship
A Long View of the 'Short' Technology Career
Being useful
Competence and prestige
There Are Only Two Roles of Code
Coaching and review
Paying Down Code Debt
A fundamental duality of software engineering
The way forward
Does Functional Programming Replace GoF Design Patterns?
Cargo cult programming
Under Or Over?
Starting off with unit testing and TDD? Here's my advice...
Why you would want to program at fifty (or any other age)
Unit Tests Don't Find Bugs: the Death of QA
Revisiting Unified Principles of Dependency Management (In Lieu Of 100 Tweets)
Reading about unit tests
I Do Not Think It Means What You Think It Means

Python
Python for data analysis

Agile and Lean
De dónde viene el Lean, el Lean Software Development y por qué se asocia con la agilidad

Entrepreneurship and Management
The Org Is The Product
Preposterously Unacceptable
A Stone Cold Money Loser

Software Development in Spain
¿Y cómo les fue a las consultoras de TI españolas en 2011?
Las empresas software Argentinas mejoran cada año y exportan más software (un 14% ya lo hace a España)
CMMI en España (Septiembre 2012). Un 14% de crecimiento
Por qué hay países en que los informáticos cobran mucho y en otros tan poco

Science
El Gobierno no hará contratos de científicos Ramón y Cajal este año
Secure the EU research budget for a future oriented Europe
Economía estudia un “plan de viabilidad y ajuste” para el CNIO
Cinco centros de alto nivel científico reciben la subvención Severo Ochoa
Mare Nostrum 3, un nuevo superordenador para Barcelona
Set science free from publishers' paywalls
Academic spring: how an angry maths blog sparked a scientific revolution
The Cost of Knowledge
Academic Spring
La ciencia española retrocede al siglo pasado

Science and Software
¿Con qué tecnología se descubrió el Boson de Higgs? Integración continua, open source, Grid, etc.

Spain and Europe
El software libre ahorra a la economía europea 450 mil millones de euros al año
I+D+E+i+e
Las trampas de la teoría de la clase política de César Molinas
Alemania en la “Gran Desigualdad”
España sufre la mayor caída de poder adquisitivo en 27 años
Los servicios sociales ya atienden a más de ocho millones de personas
Los ricos, aún más ricos
La salida acelerada de españoles al extranjero hace caer la población
Ocho países dan la voz de alarma por las jubilaciones doradas de los eurofuncionarios
Cada año de crisis genera un millón de pobres en España
La clase media enfila la cuesta abajo
Alemania es próspera, pero crece la brecha entre ricos y pobres
Así consigue Finlandia ser el número 1 en Educación en Europa
Interior pondrá coto a la difusión en internet de imágenes que dañen a policías
Policías sin imágenes, fuente de abusos
Los emigrantes españoles del siglo XXI
Uno de cada cinco españoles vive por debajo del umbral de la pobreza
El paro en España supera el 25% por primera vez en la historia
El Gran Wyoming: “España se ha derechizado tanto que llamamos ‘centro’ a la extrema derecha”
Buscar empleo con más de 50
Desigualdad como antesala de ruina
Economía de guerra
Diarrea china en la UE
Some Are More Unequal Than Others
El riesgo de pobreza crece en España y afecta con fuerza a Andalucía y Canarias

Saturday, December 1, 2012

Tuesday, November 27, 2012

Sorting a vector of pointers to objects using STL and C++11 lambdas

One year ago I posted about how to sort a vector of pointers to objects using STL and functors
As I said then, in C++11 we don't need to use functors, we can use lambdas instead. To show how, we'll use the example from that post again.

We have a stl::vector container that contains pointers to objects of some class, and we'd like to sort them based on the value of some member variable using a STL algorithm.
Let's use the Chocolate class again:
#ifndef __CHOCOLATE_H__
#define __CHOCOLATE_H__

#include <string>

class Chocolate {
  public:
    Chocolate(std::string name, double cocoaPercentage, double price)
    {
      this->cocoaPercentage = cocoaPercentage;
      this->price = price;
      this->name = name;
    };
    ~Chocolate();

    double getCocoaPercentage() { return this->cocoaPercentage; };
    double getPrice() { return this->price; };
    std::string getName() { return this->name; };

  private:
    double cocoaPercentage; 
    double price;
    std::string name;
};
#endif /* __CHOCOLATE_H__ */

We'd like to sort the following vector:
vector<Chocolate*> chocolates;
using the STL sort algorithm and two different sorting criteria: by price and by cocoa percentage.

We'll use the version of the sort algorithm that accepts, besides first and last, a third parameter, comp, which according to sort's C++ reference is a:
"Comparison function object that, taking two values of the same type than those contained in the range, returns true if the first argument goes before the second argument in the specific strict weak ordering it defines, and false otherwise."
The only difference is that, this time, instead of sorting our chocolates vector using functors, we'll use C++11 lambdas or anonymous functions (one for each sorting criterion).
According to wikipedia:
"...an anonymous function (also function constant, function literal, or lambda function) is a function (or a subroutine) defined, and possibly called, without being bound to an identifier."
So now we just need to pass a lambda function (the sorting criterion) to the sort function as its third parameter.

Let's see the sorting in action:
#include "Chocolate.h"
#include <vector>
#include <algorithm>
#include <iostream>

using namespace std;

void showChocolates(vector<Chocolate*> & chocolates);

int main(int argc, char **argv)
{
  vector<Chocolate*> chocolates;
  chocolates.push_back(new Chocolate("ChocoKoko", 80., 20.));
  chocolates.push_back(new Chocolate("ChocoLolo", 70., 30.));
  chocolates.push_back(new Chocolate("ChocoBebo", 25., 10.));
  chocolates.push_back(new Chocolate("ChocoBrian", 24., 15.));
  chocolates.push_back(new Chocolate("ChocoMiko", 30., 45.));
  
  cout<<"Sorted by price:"<<endl;
  sort(chocolates.begin(), chocolates.end(), 
    [] (Chocolate *a, Chocolate *b) {
        return a->getPrice() < b->getPrice();
  });
  showChocolates(chocolates);
  
  cout<<endl<<"Sorted by cocoa percentage:"<<endl;
  sort(chocolates.begin(), chocolates.end(), 
    [] (Chocolate *a, Chocolate *b) {
        return a->getCocoaPercentage() < b->getCocoaPercentage();
  });
  showChocolates(chocolates);
  
  for(unsigned int i=0; i<chocolates.size(); ++i) {
   delete chocolates[i];
  }
  return 0;
}

void showChocolates(vector<Chocolate*> & chocolates) {
  for(unsigned int i=0; i<chocolates.size(); ++i) {
    cout<<chocolates[i]->getName()<< " " 
      <<chocolates[i]->getPrice()<<" "
      <<chocolates[i]->getCocoaPercentage()<<"%"<<endl;
  } 
}
We compile it by doing:
$ g++ -std=c++11 Chocolate.h main.cpp -o sorters
And this is the output we get:
$ ./sorters
Sorted by price:
ChocoBebo 10 25%
ChocoBrian 15 24%
ChocoKoko 20 80%
ChocoLolo 30 70%
ChocoMiko 45 30%

Sorted by cocoa percentage:
ChocoBrian 15 24%
ChocoBebo 10 25%
ChocoMiko 45 30%
ChocoLolo 30 70%
ChocoKoko 20 80%
That's how we can sort a vector of pointers to objects using STL and C++11 lambdas.

My first C++11 program

After several attempts I've just managed to compile the last gcc version from source and to install it in my old Ubuntu.

Now I can start playing with C++11.

This is a Hello world program (that I got from here) to check that g++ is working fine:
#include <iostream>

using namespace std;

int main()
{
  auto func = [] () { 
    cout << "Hello world\n"; 
  };
  
  func();
}
To compile it:
 
$ g++ -std=c++11 -o lambdaHello lambdaHello.cpp
And then I get my "Hello world":
 
$ ./lambdaHello 
Hello world

Saturday, November 24, 2012

How to install an alternative version of Pyhton and use it in a virtual environment

I've decided to learn a bit more of Python. My friend @remosu recommended me to use virtual environments so that I can practice with different versions of Python.

First I installed an alternative version of Python on my Ubuntu following the first two steps in this great post by Eli Bendersky:
I installed first some required packages:
$ sudo apt-get install libreadline-dev
$ sudo apt-get install libsqlite3-dev
$ sudo apt-get install libbz2-dev
$ sudo apt-get install libssl-dev
Then I downloaded Python from http://www.python.org/, configured and built it:
$ ./configure
$ make -j
Then I stopped following Eli's post because I wanted to keep the version that was already installed on my computer instead of replacing it with a new version.

I started googling how to it and after a while I found this discussion in Stack Exchange Unix & Linux:
In there I found out that the "trick to easier installation of multiple interpreters from source" was using (thaks to vperic's answer):
$ sudo make altinstall
After doing that I had two Python versions living together in the same Ubuntu. Then I only had to use virtualenvwrapper to create my virtual environment.
First I installed virtualenv and virtualenvwrapper using pip:
$ pip install virtualenv
$ pip install virtualenvwrapper
And executed virtualenvwrapper.sh:
$ export WORKON_HOME=~/Envs
$ mkdir -p $WORKON_HOME
$ source /usr/local/bin/virtualenvwrapper.sh
virtualenvwrapper.user_scripts creating /home/myuser/Envs/initialize
virtualenvwrapper.user_scripts creating /home/myuser/Envs/premkvirtualenv
virtualenvwrapper.user_scripts creating /home/myuser/Envs/postmkvirtualenv
virtualenvwrapper.user_scripts creating /home/myuser/Envs/prermvirtualenv
virtualenvwrapper.user_scripts creating /home/myuser/Envs/postrmvirtualenv
virtualenvwrapper.user_scripts creating /home/myuser/Envs/predeactivate
virtualenvwrapper.user_scripts creating /home/myuser/Envs/postdeactivate
virtualenvwrapper.user_scripts creating /home/myuser/Envs/preactivate
virtualenvwrapper.user_scripts creating /home/myuser/Envs/postactivate
virtualenvwrapper.user_scripts creating /home/myuser/Envs/get_env_details
virtualenvwrapper.user_scripts creating /home/myuser/Envs/premkproject
virtualenvwrapper.user_scripts creating /home/myuser/Envs/postmkproject
virtualenvwrapper.user_scripts creating /home/myuser/Envs/prermproject
virtualenvwrapper.user_scripts creating /home/myuser/Envs/postrmproject
Finally, I created a virtual environment with python 2.7 called learning_env:
$ mkvirtualenv --python python2.7 learning_env
Running virtualenv with interpreter /usr/local/bin/python2.7
New python executable in learning_env/bin/python2.7
Also creating executable in learning_env/bin/python
Installing setuptools............................done.
Installing pip...............done.
virtualenvwrapper.user_scripts creating /home/myuser/Envs/learning_env/bin/predeactivate
virtualenvwrapper.user_scripts creating /home/myuser/Envs/learning_env/bin/postdeactivate
virtualenvwrapper.user_scripts creating /home/myuser/Envs/learning_env/bin/preactivate
virtualenvwrapper.user_scripts creating /home/myuser/Envs/learning_env/bin/postactivate
virtualenvwrapper.user_scripts creating /home/myuser/Envs/learning_env/bin/get_env_details
(learning_env)~$
To check that the virtual environment really had the right version of Python I did:
$ workon learning_env
(learning_env)bscuser@trikitrok:~$ python
Python 2.7.3 (default, Nov 21 2012, 01:38:50) 
[GCC 4.4.5] on linux2
Type "help", "copyright", "credits" or "license" for more information.
Then I got out of the virtual environment and checked that I still had the same version of Python on my Ubuntu:
$ workon learning_env
(learning_env)~$ deactivate
$ python
Python 2.6.6 (r266:84292, Sep 15 2010, 16:22:56) 
[GCC 4.4.5] on linux2
Type "help", "copyright", "credits" or "license" for more information.
Now I have my own learning environment to play with Python 2.7.

Saturday, November 17, 2012

Interesting Talk: "Seventeen Secrets of the Great Legacy Makeover Masters"

I've just watched a very interesting talk by Brian Foote:
Deep reflections on the nature of legacy code and the tools, strategies and techniques to improve its quality.

Wednesday, November 14, 2012

Refactoring Kata Tennis to State Pattern

Last month I posted about the Tennis Kata and the last Katayuno organized by Softonic.
In each of the four iterations, we used TDD and pair programming to develop the exercise from scratch.
We came to understand the tennis game as a state machine, (see the diagram showed below), and created tests for all the transitions.
We didn't have time to finish the exercise, but, once at home, I redid and finished it.
I commited the result to a public Bitbucket repository stating in the initial commit message that I'd like to refactor the code to the State Pattern to see how far the state machine idea could go.
Before refactoring to the pattern, I had to remove some duplication, rename some method and variables and introduce a Player class. Finally this morning, I was able to do it. It was very nice to observe how all the pieces started to fit together and how the code got simpler.
Thinking about the process retrospectively, I'm under the impression that the transition from the TDD resulting code to the version with the state pattern was not very difficult because the idea of the game as a state machine was there all the time. I wonder how much more difficult would have been to refactor to the state pattern, if the code of the initial solution hadn't followed the machine state idea.
This makes me reflect on how TDD is done and how your view about the problem and your knowledge and experience in refactoring and design can make completely different solutions emerge. I think that some of these solutions, even though they pass all the tests, can paint yourself in a corner from where you will need epic refactoring sessions to get out.
I think that the refactoring step is crucial for TDD success. We should not forget that in TDD we're designing not making tests pass, so we need to make a bit of "small design upfront" in each TDD cycle when creating new tests and when refactoring.
Design does not emerge on its own, we make it emerge. To do that we need to have some intuition or idea about where we'd like to go with the next TDD cycle.
I heard Jason Gorman say once that "Refactoring is the fairy dust that makes TDD magic work". The more I practice, the more I think he is right.

Wednesday, October 31, 2012

Interesting Talk: "Stop Mocking, Start Testing"

I've just watched this interesting talk by two Google engineers Augie Fackler and Nathaniel Manista:
The speakers explain their experiences in testing a big project written in Python and how their testing style has evolved with time.

Monday, October 29, 2012

How to change the code templates date format in Eclipse Indigo CDT

As I commented in a previous post, last week I spent some time configuring my recently installed version of Eclipse CDT.

After importing my preferences and settings, using Tomáš Kramár's script, I realize that the date format that appeared when using the code template for class comments didn't have the right format. I was getting Oct 26, 2012 instead of 26/10/2012. I needed to change the locale date format.

After googling a bit, I found that what I had to do was just adding the following two lines to the eclipse.ini file:
-Duser.language=es 
-Duser.region=ES

Script to create a new Eclipse workspace with all your old settings

Last week I had to configure my new installation of Eclipse.
I'd like to thank Tomáš Kramár for his script to create a new Eclipse workspace with all my old settings:
It saved me a lot of time.

Sunday, October 28, 2012

Interesting Talk: "Don't call us, we'll call you: callback patterns and idioms"

I've just watched this interesting talk by Alex Martelli:
Youl find the talk slides here.

Katayuno: "Kata Tennis"

Yesterday I went to a katayuno celebrated in Softonic Barcelona offices.
Katayuno comes from the words "kata" and "desayuno" (breakfast in Spanish) and as you can imagine it's an event where people meet to have breakfast together and practice by programming a kata. This time it was the Kata Tennis.

We had breakfast and then made two iterations of one hour each (45' pair programming with TDD + 15' retrospective). Afterwards we had a second breakfast and made two iterations more.

It was fun. I pair-programed in Php, Java (two times) and C++ with Oscar, Alex, Juanjo and Emmet, respectively. I knew interesting people and learned new things.

Once at home, yesterday afternoon, I redid the tennis kata in C++. Here you can find what I've done so far.

I'd like to thank the Softonic team for organizing this great event.

Related posts:

Sunday, October 14, 2012

Articles and Posts read

Inspiring
The Self-Destruction of the 1 Percent
Javier Gallego: “El periodismo no tiene que ser el cuarto poder, sino el contrapoder”
Versión española - El tren de la memoria
Todon't
How Small Money Can Matter Again In Politics

Learning and software craftsmanship
Why I still program
LEARN programming by visualizing code execution
Lecturas recomendadas
Review : Growing Object Oriented Software - Guided by Tests
How I remembered Object Thinking
Wirfs-Brock's book
It's official: developers get better with age. And scarcer.
Yes I Still Want To Be Doing This at 56
The Blue Collar Coder
Building For The Enterprise — The Zero Overhead Principle
Casting is a Polymorphism Fail
It’s not about the unit tests
Festering Code Bases and Budding Code Bases
Bad Things Happen to Good Code
Defensible software

C++
CppDepend is Now Available for Linux

JavaScript
Cleanliness in clientside JS

Python
Things you didn't know about Python

Online Courses
Computer Science Full Lecture Courses

Entrepreneurship and Management
Los emprendedores (también) emigran
The unspoken truth about managing geeks
Not Arbiters, Nor Catalysts

Science
$99 Raspberry Pi-sized “supercomputer” touted in Kickstarter project
Avances en tecnología de generación eléctrica

Rebooting Spain
Pacto contra la decadencia política
El 77% comparte los motivos del 25-S
El Gobierno aboga por acabar con los «horarios tropicales» de España

Spain and Europe
Behind Spain's turmoil lies a cronyism that stifles the young and ambitious
¿Quién pagará la factura? Los de siempre
Ayer emigró mi hija
Una Alemania mucho más desigual
España es el país con mayor desigualdad social de la eurozona
Alemania comienza a comprar de saldo en España.
La verdadera crisis empieza ahora
Un dato espeluznante y no es la prima de riesgo
Una crisis sin precedentes
Los millonarios españoles aumentan sus fortunas pese a la crisis

Saturday, October 13, 2012

Interesting Talk: "Technical Debt, Process and Culture"

I've just watched this interesting talk by Michael Feathers:
in which he continues developing the ideas about software growth and evolution that he presented in other talk I mentioned in a previous post: "Software Naturalism - Embracing the Real Behind the Ideal".

Friday, October 12, 2012

Articles and Posts read

Inspiring
El alcalde ‘coraje’ de Alburquerque
Working to change the world
The kind of teacher we all want to have
“Yo soy una ciudadana de bien y me manifiesto porque me preocupa mi país”

Learning and software craftsmanship
"Se aprende haciendo"
Am I A Product Of The Institutions I Attended?
Aprendiz de mucho, ¿maestro de nada?
Behavior-Driven Development in Python
Complex for whom?
Avoiding Procrastination Through Pairing
Los diez mejores algoritmos de computación del siglo XX
Domain Modeling: Naive OO Hurts
What Geeks Could Learn From Working In Restaurants
Fixing Bugs – There’s No Substitute for Experience
Shitty legacy maintenance
Growing Object-Oriented Software Guided By Tests Book Review
Are Woolly Definitions Of "Success" At The Heart Of Software Development's Thrall To Untested Ideas?
Precognitive Build Servers
Devnology Podcast 021 - Nat Pryce on Growing software with Tests
How long will there be computer science departments?
Resign Patterns: Eliminate them with Agile practices and Quality Metrics
Make Technical Debt Explicit
Coplien and Martin Debate TDD, CDD and Professionalism
Why SOLID Matters
Open, Closed, Inquiring
My lack of common sense

C++
I don’t want to see another “using namespace xxx;” in a header file

Agile and Lean
Shut up and ship
Hurry! Hurry!
Why I’m done with Scrum
CodeMotion 2012 Talk: "Agile at enterprise Scale"
The levels of agility
Las metodologías Crystal. Otras metodologías ágiles que, quizás, te puedan encajar más que Scrum
Una metodología no es ni un equipo de futbol, ni un partido político, ni una religión
Metodologías ágiles y entregas frecuentes

Entrepreneurship and Management
Evaluate people by input or output?
Empanadology: postmortem de una campaña de venta en Internet
Empanadology 2: las cifras offline detrás de un negocio online
Dress-down Friday

Developing Software in Spain
¿Por qué en España los informáticos tienen sueldos tan bajos? Aquí están las razones

Science
Science Code Manifesto
Un estudio a largo plazo en primates sobre las dietas bajas en calorías afirma que no tienen efecto sobre la longevidad
The Results Are in: Scientists Are Workaholics
Nota dominical: Qué hubiera pasado si Einstein no estudia geometría diferencial durante su carrera
Recorte de un 17,4% en la financiación de proyectos científicos en 2012
España dejó sin gastar casi la mitad del presupuesto total para I+D+i en el año 2011
Atención, pregunta: ¿Se debe especificar la contribución de cada autor de un artículo científico?

Rebooting Spain
La planta de Mutriku, la primera comercial europea que genera energía con las olas, ha producido en un año 200.000 kWh
Explicación de la política económica keynesiana para combatir el desempleo y la inflación
Reiniciando España
El estado debería ponerse en serio a controlar la calidad del software que subcontrata
Empleo verde, la profesión del futuro

Spain and Europe
Una teoría de la clase política española
Las reformas de España no se parecen en nada a las que hizo Alemania hace 10 años
Empieza a ser complicado estudiar
Pagar impuestos de plusvalías a tu nivel del IRPF, una ocurrencia que traerá más déficit y paro
Finland is about to start using crowdsourcing to create new laws
Spain Recoils as Its Hungry Forage Trash Bins for a Next Meal
Eurozone crisis explained
Nos miran mal
España empieza a estar desahuciada
Todos los recortes que no nos habían contado
El Estado recorta funcionarios pero mantiene altos cargos
'Portugal se hunde pero los políticos no dejan de robar a los trabajadores'

Thursday, September 20, 2012

Articles and Posts read

Inspiring
Hacking Sushi
Smile or Die, Barbara Ehrenreich
Here's why consistency is terribly overrated in corporate education

Learning and software craftsmanship
The secret to understanding recursion
Understanding recursion II
I'm a phony. Are you?
This code is a mess. Let’s start from scratch again…
TDD for legacy code, graphics code, and legacy graphics code?
Cleaning bad code
Just Shut Up
Dogfooding: how to build a great API
If you treat your unit tests like garbage, they'll eventually become just that.
Back To Basics #2 - Close Customer Involvement Is Key
Fabrice Bellard: Portrait of a Superproductive Programmer
Architectural Drivers
When Is It Safe to Introduce Test Doubles?
Back To Basics #3 - Software Development Is A Learning Process
Back To Basics #4 - Do The Important Stuff First
Introverts in the Office: How to Work Well in an Extrovert's World
Abuse Cases
Re-Pair Programming
Productivity porn
On Vagueness

Agile and LEan
The best approach to software development
El cliente NO siempre lleva la razón
The Irony of Waterfall
Your Path through Agile Fluency
Agile Fluency

Entrepreneurship and Management
Healthy Debates
Emprendedor, para bien o para mal, eres español
Qué pasará si trabajamos más años...
The Cubicle Dilemma
Los negocios que mejor resisten las crisis tienen el local en propiedad
From Outsourced, to Offshore … and Back Again.
Por qué me empeño en cambiar el meme sobre los empresarios
Today is Goof Off at Work Day

C++
A comparison of C++11 language support in VS2012, g++ 4.7 and Clang 3.1
Is C/C++ worth it?

Science
Two Solitudes (talk)
Si te vas a poner en serio a investigar algo… antes tienes que leer esto (y si eres un POLÍTICO también)
IEEE Computing in Science and Engineering
What is life like for PhDs in computer science who go into industry?

Spain and Europe
Iceland Was Right, We Were Wrong: The IMF
Corporate Profits Just Hit An All-Time High, Wages Just Hit An All-Time Low
México, un país de oportunidades para jóvenes españoles cualificados
Soberanismo e Inversión Extranjera
Las luces se apagan en Atenas

Tuesday, September 4, 2012

Resources for Growing Object-Oriented Software Guided by Tests (GOOS)

I've been reading Growing Object-Oriented Software Guided by Tests during August. It's a great book.

I've also started to read some of the articles mentioned in the book and to watch talks in which the authors talked about some of the topics treated in the book. These links are included in several posts in this blog.

When I found out that there was a reading club with people interested in the book, the path11 book club, I thought that I could help by collecting in a single post all the posts containing related resources that I've posted so far.

So here they go:

I hope they will be useful.

Friday, August 31, 2012

Books I read (January - August 2012)

January
- Estructura de la informació. UOC. (2nd time)
- Estructura i tecnologia de computadors. UOC. (2nd time)

February
- Working Effectively with Legacy Code, Michael Feathers
- La acabadora, (Accabadora) Michela Murgia

March
- Thinking in C++, Volume 1, 2nd edition, Bruce Eckel
- Refactoring: Improving the Design of Existing Code, Martin Fowler, Kent Beck, John Brant, William Opdyke, Don Roberts

April
- Midnight's Children, Salman Rushdie

May
- En el último azul, (Dins el darrer blau) Carme Riera
- El etrusco, (Turms kuolematon) Mika Waltari
- La soledad de los números primos, (La solitudine dei numeri primi) Paolo Giordano
- Teoria d'autòmats i llenguatges formals I. UOC.
- Estructura de computadors. UOC.

June
- White teeth, Zadie Smith
- Estructura de computadors. UOC. (2nd time)
- Teoria d'autòmats i llenguatges formals I. UOC. (2nd time)

July
- Design Patterns: Elements of Reusable Object-Oriented Software, Gamma, Helm, Johnson and Vlissides

August
- The Mythical Man-Month: Essays on Software Engineering, Frederick P. Brooks
- Firmin, Sam Savage

Sunday, August 26, 2012

Interesting Talk: "Who Ever Said Programs Were Supposed to be Pretty?"

I've just watched a talk by Brian Foote in which he wonders if clean or beautiful code makes sense in a bottom-line obsessed business world:
I think that it's full of common sense and it also describes a very real problem.

Wednesday, August 22, 2012

About Education and Learning

I found this post:
Here's why consistency is terribly overrated in corporate education
in The learning generalist blog very interesting and inspiring.

It also contains links to two great talks:

Articles and Posts read

Inspiring
Changing Pace
3D-Printed Magic Arms
Why Explore Space?
It’s Not Always “All Or Nothing”

Learning and software craftsmanship
Trivial
Craftsmanship and When Not To Refactor
Quiet: The Power Of Introverts In A World That Can't Stop Talking
A Critique of the Pomodoro Technique
Letting go of old strengths
A few comments on the Alan Kay interview, and especially patterns
Bicycle skills
La importancia de la práctica deliberada
Back To Basics #1 - Software Should Have Testable Goals
Software Apprentices Will Need Insights, Not Buzzwords
Computer Algorithms: Heap and Heapsort
Make Technical Debt Explicit
Functional Programming in 2012 … time to learn something more?
Test driving an event driven design
Software idioms
Sentences to ponder

Agile and Lean
Looking For Leaders In All The Wrong Places
Omitted activities
El fin del principio de autoridad

Entrepreneurship and Management
Programmer Moneyball
España no es país para autónomos
Si quieres saber cómo trabajo, pregunta a mis proveedores
Accountability
Developers held Accountable without Authority

Online books and courses
C/C++ Software Development with Eclipse
Functional Programming Principles in Scala
97 Things Every Software Architect Should Know

Developing Software in Spain
Memorias de un expatriado: sobre el futuro del sector informatico, la crisis continúa
Get that job at Google
Get That Job at Facebook

Spain and Europe
¿Hora de hacer las maletas? Un repaso a las oportunidades que hay fuera
Reformas y recortes educativos: una evaluación muy preliminar
El paro sigue al alza en Andalucía y Canarias pese al turismo
La solución de Alemania para acabar con el paro: salarios de 400 euros
No todas las familias españolas se endeudaron; ni lo hicieron al mismo nivel, ni para los mismos propósitos.
El éxodo de médicos y enfermeras se duplica por los recortes sanitarios
En la mente del corrupto
Esclavos
España debe salvarse a sí misma

Tuesday, August 14, 2012

Ports and Adapters

In Growing Object-Oriented Software, Guided By Tests its authors explain how they grow systems a slice of functionality at a time. As the code scales up, they need to structure the functionality so they can continue to understand and maintain it. They use two principal heuristics to guide this structuring:
  1. Separation of concerns.
  2. Higher level of abstraction.
They state that, when applied consistently, these two forces push the structure to something similar to Cockburn's "ports and adapters" architecture.

These are the links I'm reading to find out what this "ports and adapters" (or hexagonal) architecture is about:

Interesting Talk: "Fractal TDD: Using tests to drive system design"

@remosu and I are currently reading the book:
Growing Object-Oriented Software, Guided By Tests
by Steve Freeman and Nat Pryce.

So far, I've found that their approach to TDD and end-to-end tests and their ideas about object-oriented design are really interesting.

I've just watched this great talk:
in which one of the authors of the book, Steve Freeman, comments several of the ideas in the book and his experiences applying them in big projects.

PS: I posted about another Steve Freeman's talk some time ago.

Wednesday, August 8, 2012

Articles and Posts read

Learning and software craftsmanship
Software Development and Security
SOLID by example
Let's Not Call It "Computer Science" If We Really Mean "Computer Programming"
Success Criteria
Your Coding Philosophies are Irrelevant
Another argument in favour of TDD
Ten Commandments of Object Oriented Design
Beyond Test Driven Development
Testing with Mocha
Visualizing recursion
«No intentes hacer lo que no dominas»
Game Developers: Remember Priority #1
The less the code, the better
Books hold most of the secrets of the world.."
La cultura de la distracción
Software albatross
Your job is trivial. (But I couldn’t do it.)
How not to go insane while working from home
Old school developers - achieving a lot with little
How GOF Brought my Understanding of Object Orientation to Another Level

C++
C preprocessor tricks

PostgreSQL
PostgreSQL Rising

Agile and Lean
The Art of Agile Development: Pair Programming
Definition of Done and Acceptance Criteria
The art of misdirection
Late Night Thoughts On "It Works For Me"
Retrospective Principles
Goals of a Retrospective
The Wrong Impression about Retrospectives

Entrepreneurship and Management
¿Cómo está el panorama de desarrollo de aplicaciones móviles actual? el informe Developer Economics 2012 nos da algunas pistas
Your Operational Configuration

Science
Cheetah, el robot guepardo de Boston Dynamics capaz de correr casi a 30 km/h
¿Qué importa más en la carrera académica, los conocimientos o los conocidos? (segunda parte)
Proponen un detector de materia oscura direccional basado en ADN
Mixed Signals: Smart Phone Sensors Recruited to Deliver Indoor GPS
En 2014 toda la investigación financiada con dinero de la UE deberá ser de acceso abierto
La Comisión Europea apoya el acceso libre a los resultados de investigación científica

Education
Teaching is a Form of Compression

Developing Software in Spain
#debate10: Una oportunidad para una nueva cultura
Maldito el pais que necesita heroes

Spain and Europe
Sobre el retraso económico de España y el libro de Acemoglu y Robinson (Una respuesta de Regina Grafe)
Why are Germans So Stubborn? de Uwe Reinhardt, Princeton
Primero, los deberes nacionales
Pobre puede ser cualquiera, o casi
Ya somos griegos

ETIS en la UOC: Asignaturas del pasado semestre

Hace ya unos meses hablaba del nuevo semestre que comenzaba en ETIS en la UOC. Ahora que terminó el semestre y tengo un poco más de tiempo, llegó el momento de hacer una retrospectiva y de analizar las asignaturas.

De nuevo, tuve que dejar una de las asignaturas, Matemàtica Discreta, porque entre el trabajo y los pet projects que estoy haciendo con @remosu no me dió tiempo de seguirla. Aunque ya en mi anterior retrospectiva había llegado a la conclusión de que mi límite estaba en 15 créditos por semestre, en el último momento me dejé llevar por un impulso y cogí tres asignaturas pensando que podría con todo. Fue un error.

En el lado positivo, este semestre saqué de nuevo matrícula de honor en dos asignaturas. Estas son mis impresiones sobre estas dos asignaturas:
  • Teoria d'autòmats i llenguatges formals I
  • Esta asignatura me la habían recomendado varios compañeros de trabajo, y tenían razón, es muy bonita. Me costó entender algunas partes del temario, y tuve que dedicarle mucho tiempo. Aún habiendo obtenido buenos resultados, creo que todavía no acabo de entender del todo bien algunos conceptos de la asignatura.
    El temario de TALF I es bastante corto pero no se la debe subestimar por ello, ya que en ella se ven conceptos que lleva su tiempo entender. Creo que el camino se allana bastante si se consigue aprobar la evaluación contínua porque, en ese caso, el temario que entra en la Prueba de Validación se limita a los temas que entraron en las PACs: aproximadamente un 80% del temario de la asignatura. Ir al examen final es más complicado porque entra el 100% del temario y algunas partes son bastante duras.
    Para hacer las PACs usé sólo el material de la asignatura, que es un poco escaso, y un montón de horas. Supongo que si hubiera mirado PACs y/o exámenes de años anteriores me hubiera ayudado. En cada PAC ponía que el tiempo estimado de realización eran tres horas, pero para algún apartado de la segunda PAC (el de gramáticas) me pasé más de 5 horas... No hay que agobiarse porque la cosa mejora con la práctica. Antes de hacer la PV, ya era capaz de resolver rápidamente ejercicios similares a los de las PACs.
    Para preparar la PV me lei de nuevo toda la teoria. Este repaso general me sirvió para acabar de entender cosas que no había comprendido bien cuando hice las PACs. Después hice todos los ejercicios de autoevaluación relacionados con los temas que habían salido en las PACs e hice unos cuantos exámenes (sólo los problemas relacionadas con las PACs). Esto me llevó unos tres días y medio (no tenía más).
  • Ampliació d'estructura i tecnologia de computadors
    Esta asignatura es la continuación de Estructura i tecnologia de computadors. Tiene dos PACs y dos prácticas, una obligatoria con la que puedes conseguir hasta un 70% de la nota práctica, y otra opcional con la que puedes conseguir lo que falta para el 100%.
    El tema que me fue más útil para el trabajo fue el estudio de la jerarquía de memoria, y en especial de la memoria cache. Los materiales de la asignatura están disponibles en el OCW de la UOC
    Las prácticas consistieron en escribir programas con partes escritas en ensamblador y partes escritas en C. A partir de cosas que aprendí resolviéndolas salieron varios posts de este blog (este, este y este). Si quieres ver el código de las prácticas, está publicado aquí y aquí.
    Los profesores colgaban cada semana ejercicios teóricos y prácticos que había que resolver en unos 5 días. Si uno tiene tiempo, está muy bien hacerlos porque vas desarrollando poco a poco los conocimientos que necesitas para hacer las PACs y las prácticas. Yo no hice ninguno de los ejercicios porque no tuve tiempo, con lo que, luego tuve que hacer las PACs y prácticas a contrarreloj.
    Para preparar el examen, rehice todos los ejercicios de las PACs, hice los ejercicios teóricos semanales y miré algunos exámenes de años anteriores. También repasé la solución oficial de las prácticas.
    La asignatura no es muy difícil, quizás, lo más complicado es cogerle el truco al ensamblador.
Me costó mucho esfuerzo simultanear estas asignaturas con el trabajo, las lecturas técnicas y mis pet projects con @remosu, pero, mirando hacia atrás, creo que valió la pena.

Friday, July 27, 2012

Articles and Posts read


Inspiring
El Gran Dictador - Discurso Final
Meet the tireless entrepreneur who squatted at AOL
Salvados: Reiniciando España
"No me da la gana rendirme"

Learning and software craftsmanship
From Alchemy to Science in Programming
So You Want to be a Programmer
How to Stop Sucking and Be Awesome Instead
Obsession
Do You Suffer From the Dunning-Kruger Effect?
What do developers do all day?
The Silent Majority of Experts
Best Actor Award

C++
Test Driven Development with CppUTest, now in Debian

Go
Parsing huge XML files with Go

Agile and Lean
Reducing Cycle Time

Entrepreneurship and Management
The care and feeding of software engineers (or, why engineers are grumpy)
In praise of misfits
A Dearth of Spanish Innovation
Ande yo caliente, ríase la gente
Misapplication Of Partially Mastered Ideas
Lo que tienen en común las mejores organizaciones de desarrollo software
A Blank Stare In Return
A flowchart for hiring programmers
The Hidden Cost of Outsourcing Software: Software Intelligence

Open Source
El Software Libre permitirá un ahorro anual de 700.000 euros al Gobierno de Canarias
La liberación informática de Munich

Science
Artificial Pancreas Passes Human Trial
22 premios Nobel expresan “preocupación” por la ciencia en España

Education
What You Know Matters More Than What You Do
Advice to (prospective) grad students
Una educación para la incertidumbre
Hindsight-Based
La universidad como el huevo de oro de nuestra sociedad

Developing Software in Spain
Si no es por no hacerlo, pero hacerlo "pa na" es tontería
España vive una fuga de ingenieros informáticos debido a sus malas condiciones
Los informáticos no entienden de paro
Informática, la profesión sin paro... pero, ¿a qué precio?
La Columna B: La falacia del Programador Perdido

Spain and Europe
…y démonos cuenta que esto sólo es el principio
La Virgen del Rocío y el exceso de científicos
Rescate: se consuma el engaño
Otro rescate bancario
Bienvenidos a los años treinta
La Ley Weidmann
La paradoja del ahorro: España vs. Alemania
Alemania capta ahorro y cerebros españoles a coste cero
Salvados: Parados en espera
Can UK Journalists Just Feck Off Please?

Thursday, July 26, 2012

Interesting Talk: "The Limited Red Society"

I've just watched this interesting talk by Joshua Kerievsky.
He talks about refactoring techniques, such as Parallel Change or Narrowed Change, which help to reduce the amount of time spent in red, i. e. with the tests not passing, during a refactoring session.

Wednesday, July 25, 2012

Interesting Talk: "Stop Refactoring!"

I've just watched this talk by Nat Pryce:
I think he's not right. I completely agree with Bjorn Hansen's comment about the talk where he views refactoring more as:
"changing the structure of the code without changing functionality so that it's easy to add the next thing after you learn what that thing is."
More about this last view of refactoring in Craftsmanship and When Not To Refactor

Monday, July 23, 2012

Articles and Posts read


Learning and software craftsmanship
Eres lo que trabajas
Five things software developers can learn from Draw Something
GNU Parallel
Design for Testability
5 Things to Un-Learn From School
Why read and write tech books?
Software exoskeletons
Everything New is Old Again

Agile and Lean
Agilismo sin software
Escuchando a la comunidad, a la gente, a los alumnos
El rol del ingeniero en el desarrollo ágil de software
El crece pelo universal, la dieta milagro, inglés con 10 palabras y el Ágil método repara todo

C++
Hacrobatics
Performance Per Watt

Go
5 Weeks of Go

Entrepreneurship and Management
Your Fork, Sir
La tecnología es más importante que las competencias profesionales
El perfil del empleado perfecto
Knocking the exuberance out of employees
Los emprendedores españoles montan bares, no fábricas de tornillos
Mary Meeker Explains the Mobile Monetization Challenge

Science
Las investigaciones financiadas con fondos públicos serán de libre acceso en Gran Bretaña
Aprender de mecánica y autovectores rompiendo tizas
Autovectores: ¡otro inútil capricho de los matemáticos!
'España ha invertido dinero en mi formación y es Francia la que se aprovecha'
Libre acceso a la información científica del país
No dormir lo suficiente está relacionado con la obesidad

Education
LOVA
Cómo crear tu propia Khan Academy
¿No gusta estudiar informática? Vuelve a bajar el número de matriculas universitarias, el menor en 13 años

JotDown
Todo lo que necesito aprender lo aprendí leyendo el péndulo de Foucault
Aquel de cuyo nombre no quisieron acordarse

Spain and Europe
Pero ¡cómo va a estar todo hecho!
Salvados: Más allá del ladrillo
El balance neto alivia el déficit de tarifa

Africa
La cara y la cruz del 'milagro' africano