package o;

/* compiled from: r8-map-id-3b7cc9102578c509342fa2f0fabed2bfc72239cd258d579fc679bfcbc198b048 */
/* renamed from: o.a9, reason: case insensitive filesystem */
/* loaded from: classes.dex */
public final class C0694a9 implements Z8, InterfaceC0885c9 {
    public final float l;
    public final X8 m;
    public final float n;

    public C0694a9(float f, X8 x8) {
        this.l = f;
        this.m = x8;
        this.n = f;
    }

    @Override // o.Z8, o.InterfaceC0885c9
    public final float a() {
        return this.n;
    }

    @Override // o.InterfaceC0885c9
    public final void b(int i, InterfaceC2424sO interfaceC2424sO, int[] iArr, int[] iArr2) {
        g(interfaceC2424sO, i, iArr, EnumC1280gK.l, iArr2);
    }

    public final boolean equals(Object obj) {
        if (this == obj) {
            return true;
        }
        if (!(obj instanceof C0694a9)) {
            return false;
        }
        C0694a9 c0694a9 = (C0694a9) obj;
        return C0148Fs.a(this.l, c0694a9.l) && this.m.equals(c0694a9.m);
    }

    @Override // o.Z8
    public final void g(InterfaceC2281qr interfaceC2281qr, int i, int[] iArr, EnumC1280gK enumC1280gK, int[] iArr2) {
        int i2;
        int iMin;
        if (iArr.length == 0) {
            return;
        }
        int iN = interfaceC2281qr.N(this.l);
        boolean z = enumC1280gK == EnumC1280gK.m;
        J7 j7 = AbstractC0981d9.a;
        if (z) {
            i2 = 0;
            iMin = 0;
            for (int length = iArr.length - 1; -1 < length; length--) {
                int i3 = iArr[length];
                int iMin2 = Math.min(i2, i - i3);
                iArr2[length] = iMin2;
                iMin = Math.min(iN, (i - iMin2) - i3);
                i2 = iArr2[length] + i3 + iMin;
            }
        } else {
            int length2 = iArr.length;
            int i4 = 0;
            i2 = 0;
            iMin = 0;
            int i5 = 0;
            while (i4 < length2) {
                int i6 = iArr[i4];
                int iMin3 = Math.min(i2, i - i6);
                iArr2[i5] = iMin3;
                int iMin4 = Math.min(iN, (i - iMin3) - i6);
                int i7 = iArr2[i5] + i6 + iMin4;
                i4++;
                iMin = iMin4;
                i2 = i7;
                i5++;
            }
        }
        int i8 = i2 - iMin;
        if (i8 < i) {
            int iIntValue = ((Number) this.m.f(Integer.valueOf(i - i8), enumC1280gK)).intValue();
            int length3 = iArr2.length;
            for (int i9 = 0; i9 < length3; i9++) {
                iArr2[i9] = iArr2[i9] + iIntValue;
            }
        }
    }

    public final int hashCode() {
        return this.m.hashCode() + Ag0.d(Float.hashCode(this.l) * 31, true, 31);
    }

    public final String toString() {
        return "Arrangement#spacedAligned(" + ((Object) C0148Fs.b(this.l)) + ", " + this.m + ')';
    }
}
