Funciones Parámetros Opcionales StringBuffer (Dart)


void main() {
  //llamamos a la Funcion y le pasamos los parametros en este caso esta vacio
textocache('Pedro','Montes');
}
//funcion con retorno cargada con dos String o Parametros Opcionales
void textocache([ String Nombre='Michael',String Apellido='Sayman']){
  //Varieble StringBuffer var textocache = StringBuffer('Es un Placer ');
   textocache.write(' $Nombre');
   textocache.write(' $Apellido');

print(textocache.toString());
}

Comments