73 lines
1.6 KiB
Java
73 lines
1.6 KiB
Java
|
package o;
|
||
|
|
||
|
/* loaded from: classes3.dex */
|
||
|
public class VDF implements Comparable<VDF> {
|
||
|
public final int b;
|
||
|
public final int c;
|
||
|
|
||
|
@Override // java.lang.Comparable
|
||
|
public /* bridge */ /* synthetic */ int compareTo(VDF vdf) {
|
||
|
VDF vdf2 = vdf;
|
||
|
int i = this.b * this.c;
|
||
|
int i2 = vdf2.b * vdf2.c;
|
||
|
if (i2 < i) {
|
||
|
return 1;
|
||
|
}
|
||
|
return i2 > i ? -1 : 0;
|
||
|
}
|
||
|
|
||
|
public VDF(int i, int i2) {
|
||
|
this.c = i;
|
||
|
this.b = i2;
|
||
|
}
|
||
|
|
||
|
public final VDF d(VDF vdf) {
|
||
|
int i = this.c;
|
||
|
int i2 = vdf.b;
|
||
|
int i3 = vdf.c;
|
||
|
int i4 = this.b;
|
||
|
int i5 = i * i2;
|
||
|
int i6 = i3 * i4;
|
||
|
if (i5 >= i6) {
|
||
|
return new VDF(i3, i6 / i);
|
||
|
}
|
||
|
return new VDF(i5 / i4, i2);
|
||
|
}
|
||
|
|
||
|
public final VDF c(VDF vdf) {
|
||
|
int i = this.c;
|
||
|
int i2 = vdf.b;
|
||
|
int i3 = vdf.c;
|
||
|
int i4 = this.b;
|
||
|
int i5 = i * i2;
|
||
|
int i6 = i3 * i4;
|
||
|
if (i5 <= i6) {
|
||
|
return new VDF(i3, i6 / i);
|
||
|
}
|
||
|
return new VDF(i5 / i4, i2);
|
||
|
}
|
||
|
|
||
|
public String toString() {
|
||
|
StringBuilder sb = new StringBuilder();
|
||
|
sb.append(this.c);
|
||
|
sb.append("x");
|
||
|
sb.append(this.b);
|
||
|
return sb.toString();
|
||
|
}
|
||
|
|
||
|
public boolean equals(Object obj) {
|
||
|
if (this == obj) {
|
||
|
return true;
|
||
|
}
|
||
|
if (obj == null || getClass() != obj.getClass()) {
|
||
|
return false;
|
||
|
}
|
||
|
VDF vdf = (VDF) obj;
|
||
|
return this.c == vdf.c && this.b == vdf.b;
|
||
|
}
|
||
|
|
||
|
public int hashCode() {
|
||
|
return (this.c * 31) + this.b;
|
||
|
}
|
||
|
}
|