shuffle function
dynamic
shuffle(
- dynamic source$1
Implementation
dc.dynamic shuffle(dc.dynamic source$1, ){
final dc.dynamic coll7657$1=source$1;
final lcoc_core.IFn$iface f7658$1=lcoc_core.conj$BANG_;
final dc.dynamic start7659$1=lcoc_core.transient(lcoc_core.$_EMPTY_VECTOR, );
late final dc.dynamic source$BANG_$1;
if((coll7657$1 is lcoc_core.IReduce$iface)){
source$BANG_$1=((coll7657$1 as lcoc_core.IReduce$iface).$_reduce$2(f7658$1, start7659$1, ));
}else{
source$BANG_$1=((lcoc_core.IReduce.extensions(coll7657$1, ) as lcoc_core.IReduce$ext).$_reduce$2(coll7657$1, f7658$1, start7659$1, ));
}
final dc.dynamic coll7677$1=source$BANG_$1;
late final dc.int length$1;
if((coll7677$1 is lcoc_core.ICounted$iface)){
length$1=(((coll7677$1 as lcoc_core.ICounted$iface).$_count$0()) as dc.int);
}else{
length$1=(((lcoc_core.ICounted.extensions(coll7677$1, ) as lcoc_core.ICounted$ext).$_count$0(coll7677$1, )) as dc.int);
}
dc.dynamic tv$1=source$BANG_$1;
dc.int i$1=length$1;
do {
final dc.int i_1$1=(i$1-1);
if((0<i_1$1)){
final dc.int j$1=lcoc_core.rand_int(i$1, );
final dc.dynamic tmp$1=(lcoc_core.nth.$_invoke$2(tv$1, i_1$1, ));
tv$1=(lcoc_core.assoc$BANG_.$_invoke$3((lcoc_core.assoc$BANG_.$_invoke$3(tv$1, i_1$1, (lcoc_core.nth.$_invoke$2(tv$1, j$1, )), )), j$1, tmp$1, ));
i$1=i_1$1;
continue;
}
return lcoc_core.persistent$BANG_(tv$1, );
} while(true);
}