Day 1
This commit is contained in:
@@ -6,7 +6,7 @@ class ReadData {
|
||||
var file = File(fileName);
|
||||
var contents = <String>[];
|
||||
|
||||
print('open file "$fileName"');
|
||||
// print('open file "$fileName"');
|
||||
if (await file.exists()) {
|
||||
contents = await File(fileName).readAsLines();
|
||||
} else {
|
||||
@@ -20,7 +20,7 @@ class ReadData {
|
||||
var file = File(fileName);
|
||||
var contents = <num>[];
|
||||
|
||||
print('open file "$fileName"');
|
||||
// print('open file "$fileName"');
|
||||
if (await file.exists()) {
|
||||
var contentStrings = await File(fileName).readAsLines();
|
||||
contents = contentStrings.map(num.parse).toList();
|
||||
|
||||
Reference in New Issue
Block a user