package c.r;

import c.l.w;
import java.util.NoSuchElementException;

/* JADX INFO: compiled from: ProgressionIterators.kt */
/* JADX INFO: loaded from: classes.dex */
public final class b extends w {

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

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

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

    /* JADX INFO: renamed from: e, reason: collision with root package name */
    private final int f1459e;

    public b(int i, int i2, int i3) {
        this.f1459e = i3;
        this.f1456b = i2;
        boolean z = true;
        if (i3 <= 0 ? i < i2 : i > i2) {
            z = false;
        }
        this.f1457c = z;
        this.f1458d = z ? i : this.f1456b;
    }

    @Override // c.l.w
    public int b() {
        int i = this.f1458d;
        if (i != this.f1456b) {
            this.f1458d = this.f1459e + i;
        } else {
            if (!this.f1457c) {
                throw new NoSuchElementException();
            }
            this.f1457c = false;
        }
        return i;
    }

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