Skip to content

Instantly share code, notes, and snippets.

@jebright jebright/map
Created Sep 23, 2018

What would you like to do?
Dart Fundamentals - Lists - Map
class Person
String firstName;
String lastName;
Person(this.firstName, this.lastName);
void main() {
List<Person> people = new List<Person>();
people.add(new Person("Joe", "Smithers"));
people.add(new Person("Patrick", "Thomas"));
var mappedNames = => 'Mr. ${n.firstName} ${n.lastName}');
void log(var lst) {
lst.forEach((n) => print(n));
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.