Skip to content

Instantly share code, notes, and snippets.

@srawlins
Last active June 28, 2018 22:49
Show Gist options
  • Save srawlins/76a0bcb996dc5936ed489b28a579bcbf to your computer and use it in GitHub Desktop.
Save srawlins/76a0bcb996dc5936ed489b28a579bcbf to your computer and use it in GitHub Desktop.
import 'dart:math' as math;
// Poorly named wrapper for math.Random
class Random {
math.Random inner;
Random(this.inner);
}
void main() {
List<Random> list = new List<Random>()..add(new Random(new math.Random(7)));
addRandom(list.map((e) => e.inner));
}
addRandom(List<math.Random> list) => list..add(new math.Random());
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment