Skip to content

Instantly share code, notes, and snippets.

@jacobaraujo7
Created April 4, 2019 23:35
Show Gist options
  • Save jacobaraujo7/3990a6c521e7037f0359a8718315b97d to your computer and use it in GitHub Desktop.
Save jacobaraujo7/3990a6c521e7037f0359a8718315b97d to your computer and use it in GitHub Desktop.
arrays.dart
import 'dart:io';
main(){
var nome = [];
bool condicao = true;
while (condicao) {
print("Digite o nome");
String text = stdin.readLineSync();
if(text == "sair"){
print("===== PROGRAMA FINALIZADO ====");
condicao = false;
} else {
nome.add(text);
}
print(nome);
print("\n");
}
// List<String> nomes = ["Jacob Moura", "Luiza Moura", "Sara Moura", "Jordana Moura"];
// nomes.add("Eurides Moura");
// nomes.add("André Moura");
// print(nomes);
// nomes.removeAt(1);
// print(nomes);
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment