tion</span></h2>
      <pre class="language-dart"><code class="language-dart">static Rect lerp(Rect a, Rect b, double t) {
  assert(t != null);
  if (a == null &amp;&amp; b == null)
    return null;
  if (a == null)
    return new Rect.fromLTRB(b.left * t, b.top * t, b.right * t, b.bottom * t);
  if (b == null) {
    final double k = 1.0 - t;
    return new Rect.fromLTRB(a.left * k, a.top * k, a.right * k, a.bottom * k);
  }
  return new Rect.fromLTRB(
    lerpDouble(a.left, b.left, t),
    lerpDouble(a.top