package rp;

import java.util.Iterator;
import kotlin.jvm.internal.t;

/* loaded from: classes3.dex */
public final class r implements h {

    /* renamed from: a, reason: collision with root package name */
    private final h f35082a;

    /* renamed from: b, reason: collision with root package name */
    private final dn.l f35083b;

    /* loaded from: classes3.dex */
    public static final class a implements Iterator, en.a {

        /* renamed from: p, reason: collision with root package name */
        private final Iterator f35084p;

        a() {
            this.f35084p = r.this.f35082a.iterator();
        }

        @Override // java.util.Iterator
        public boolean hasNext() {
            return this.f35084p.hasNext();
        }

        @Override // java.util.Iterator
        public Object next() {
            return r.this.f35083b.invoke(this.f35084p.next());
        }

        @Override // java.util.Iterator
        public void remove() {
            throw new UnsupportedOperationException("Operation is not supported for read-only collection");
        }
    }

    public r(h sequence, dn.l transformer) {
        t.g(sequence, "sequence");
        t.g(transformer, "transformer");
        this.f35082a = sequence;
        this.f35083b = transformer;
    }

    public final h d(dn.l iterator) {
        t.g(iterator, "iterator");
        return new f(this.f35082a, this.f35083b, iterator);
    }

    @Override // rp.h
    public Iterator iterator() {
        return new a();
    }
}
