package xd;

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

/* JADX INFO: loaded from: classes.dex */
public final class b implements Iterator, td.a {

    /* JADX INFO: renamed from: a, reason: collision with root package name */
    public final int f34810a;

    /* JADX INFO: renamed from: b, reason: collision with root package name */
    public final int f34811b;

    /* JADX INFO: renamed from: c, reason: collision with root package name */
    public boolean f34812c;

    /* JADX INFO: renamed from: d, reason: collision with root package name */
    public int f34813d;

    public b(int i10, int i11, int i12) {
        this.f34810a = i12;
        this.f34811b = i11;
        boolean z10 = true;
        if (i12 <= 0 ? i10 < i11 : i10 > i11) {
            z10 = false;
        }
        this.f34812c = z10;
        this.f34813d = z10 ? i10 : i11;
    }

    @Override // java.util.Iterator
    /* JADX INFO: renamed from: a, reason: merged with bridge method [inline-methods] */
    public final /* bridge */ /* synthetic */ Object next() {
        return Integer.valueOf(b());
    }

    public final int b() {
        int i10 = this.f34813d;
        if (i10 != this.f34811b) {
            this.f34813d = this.f34810a + i10;
        } else {
            if (!this.f34812c) {
                throw new NoSuchElementException();
            }
            this.f34812c = false;
        }
        return i10;
    }

    public final void d() {
        throw new UnsupportedOperationException("Operation is not supported for read-only collection");
    }

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

    @Override // java.util.Iterator
    public final /* bridge */ /* synthetic */ void remove() {
        d();
        throw null;
    }
}
