package d0.t; import d0.z.d.m; import java.util.ArrayList; import java.util.Iterator; import java.util.List; import java.util.Map; import kotlin.Pair; import kotlin.sequences.Sequence; /* compiled from: _Maps.kt */ public class i0 extends h0 { public static final Sequence> asSequence(Map map) { m.checkNotNullParameter(map, "$this$asSequence"); return u.asSequence(map.entrySet()); } public static final List> toList(Map map) { m.checkNotNullParameter(map, "$this$toList"); if (map.size() == 0) { return n.emptyList(); } Iterator> it = map.entrySet().iterator(); if (!it.hasNext()) { return n.emptyList(); } Map.Entry next = it.next(); if (!it.hasNext()) { return m.listOf(new Pair(next.getKey(), next.getValue())); } ArrayList arrayList = new ArrayList(map.size()); arrayList.add(new Pair(next.getKey(), next.getValue())); do { Map.Entry next2 = it.next(); arrayList.add(new Pair(next2.getKey(), next2.getValue())); } while (it.hasNext()); return arrayList; } }