Futures</h2>
<p>To avoid unintentional blocking of the program,
several methods use a <a href="dart-async/Future-class.html">Future</a> to return a value. For example,
the <a href="dart-io/File/length.html">length</a> method, which gets the length of a file, returns a Future.
Use <code>then</code> to register a callback function, which is called when
the value is ready.</p>
<pre class="language-dart"><code>import 'dart:io';

main() {
  final file = new File('file.txt');

  file.length().then((len) {
    pri