Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- class Game {
- String awayTeam;
- String hostTeam;
- String result;
- Game({this.hostTeam,
- this.awayTeam,
- this.result});
- }
- var data = ["Real Madrid","Barcelona","0-0","FCPorto","A.C. Milan","3-3"]; // this could be any size, but the data offset is the same
- var games = <Game>[];
- // how do I create a List of Game objects this games with this data?
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement