package d.p0;

import d.j0.g0;
import java.util.NoSuchElementException;

/* JADX INFO: compiled from: ProgressionIterators.kt */
/* JADX INFO: loaded from: classes.dex */
@d.n
public final class j extends g0 {

    /* JADX INFO: renamed from: c, reason: collision with root package name */
    private final long f2682c;

    /* JADX INFO: renamed from: d, reason: collision with root package name */
    private final long f2683d;

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

    /* JADX INFO: renamed from: f, reason: collision with root package name */
    private long f2685f;

    public j(long j, long j2, long j3) {
        this.f2682c = j3;
        this.f2683d = j2;
        boolean z = true;
        if (j3 <= 0 ? j < j2 : j > j2) {
            z = false;
        }
        this.f2684e = z;
        this.f2685f = z ? j : j2;
    }

    @Override // d.j0.g0
    public long a() {
        long j = this.f2685f;
        if (j != this.f2683d) {
            this.f2685f = this.f2682c + j;
        } else {
            if (!this.f2684e) {
                throw new NoSuchElementException();
            }
            this.f2684e = false;
        }
        return j;
    }

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