package mp;

import java.util.Iterator;
import java.util.NoSuchElementException;

/* loaded from: classes3.dex */
public final class o extends c {

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

    /* renamed from: q, reason: collision with root package name */
    private final int f29598q;

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

        /* renamed from: p, reason: collision with root package name */
        private boolean f29599p = true;

        a() {
        }

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

        @Override // java.util.Iterator
        public Object next() {
            if (!this.f29599p) {
                throw new NoSuchElementException();
            }
            this.f29599p = false;
            return o.this.m();
        }

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

    /* JADX WARN: 'super' call moved to the top of the method (can break code semantics) */
    public o(Object value, int i10) {
        super(null);
        kotlin.jvm.internal.t.g(value, "value");
        this.f29597p = value;
        this.f29598q = i10;
    }

    @Override // mp.c
    public int e() {
        return 1;
    }

    @Override // mp.c
    public void g(int i10, Object value) {
        kotlin.jvm.internal.t.g(value, "value");
        throw new IllegalStateException();
    }

    @Override // mp.c
    public Object get(int i10) {
        if (i10 == this.f29598q) {
            return this.f29597p;
        }
        return null;
    }

    public final int i() {
        return this.f29598q;
    }

    @Override // mp.c, java.lang.Iterable
    public Iterator iterator() {
        return new a();
    }

    public final Object m() {
        return this.f29597p;
    }
}
