Code I wrote by reading book Learning Dart