import java.math.BigInteger ;
import java.security.SecureRandom ;
import java.io.* ;
import java.util.* ;
public class PollardRho {
static Vector< BigInteger> v = new Vector< BigInteger> ( ) ;
if ( N.mod ( TWO) .compareTo ( ZERO) == 0 ) return TWO;
do {
x = x.multiply ( x) .mod ( N) .add ( c) .mod ( N) ;
xx = xx.multiply ( xx) .mod ( N) .add ( c) .mod ( N) ;
xx = xx.multiply ( xx) .mod ( N) .add ( c) .mod ( N) ;
divisor = x.subtract ( xx) .gcd ( N) ;
} while ( ( divisor.compareTo ( ONE) ) == 0 ) ;
return divisor;
}
if ( N.compareTo ( ONE) == 0 ) return ;
if ( N.isProbablePrime ( 20 ) ) {
v.add ( N) ;
return ;
}
factor( divisor) ;
factor( N.divide ( divisor) ) ;
}
long num
= Long .
parseLong ( br.
readLine ( ) ) ; factor( N) ;
int sz = v.size ( ) ;
long cnt = 0 ;
long tot = 1 ;
for ( int i= 0 ; i< sz; i++ ) {
cnt = 0 ;
while ( i+ 1 < sz&& v.get ( i) .equals ( v.get ( i+ 1 ) ) ) {
cnt++; i++;
}
cnt++;
tot *= ( cnt+ 1 ) ;
}
}
}
aW1wb3J0IGphdmEubWF0aC5CaWdJbnRlZ2VyOwppbXBvcnQgamF2YS5zZWN1cml0eS5TZWN1cmVSYW5kb207CmltcG9ydCBqYXZhLmlvLio7CmltcG9ydCBqYXZhLnV0aWwuKjsKCnB1YmxpYyBjbGFzcyBQb2xsYXJkUmhvIHsKCiAgICBwcml2YXRlIGZpbmFsIHN0YXRpYyBCaWdJbnRlZ2VyIFpFUk8gPSBuZXcgQmlnSW50ZWdlcigiMCIpOwogICAgcHJpdmF0ZSBmaW5hbCBzdGF0aWMgQmlnSW50ZWdlciBPTkUgID0gbmV3IEJpZ0ludGVnZXIoIjEiKTsKICAgIHByaXZhdGUgZmluYWwgc3RhdGljIEJpZ0ludGVnZXIgVFdPICA9IG5ldyBCaWdJbnRlZ2VyKCIyIik7CiAgICBwcml2YXRlIGZpbmFsIHN0YXRpYyB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mV0dXJuOwoKICAgICAgICBpZiAoTi5pc1Byb2JhYmxlUHJpbWUoMjApKSB7CiAgICAgICAgICAgIHYuYWRkKE4pOwogICAgICAgICAgICByZXR1cm47CiAgICAgICAgfQoKICAgICAgICBCaWdJbnRlZ2VyIGRpdmlzb3IgPSByaG8oTik7CiAgICAgICAgZmFjdG9yKGRpdmlzb3IpOwogICAgICAgIGZhY3RvcihOLmRpdmlkZShkaXZpc29yKSk7CiAgICB9CgogICAgcHVibGljIHN0YXRpYyB2b2lkIG1haW4oU3RyaW5nW10gYXJncykgdGhyb3dzIEV4Y2VwdGlvbiB7CgogICAgICAgQnVmZmVyZWRSZWFkZXIgYnIgPSBuZXcgQnVmZmVyZWRSZWFkZXIobmV3IElucHV0U3RyZWFtUmVhZGVyKFN5c3RlbS5pbikpOwpsb25nIG51bSA9IExvbmcucGFyc2VMb25nKGJyLnJlYWRMaW5lKCkpOwogICAgICAgIEJpZ0ludGVnZXIgTiA9IG5ldyBCaWdJbnRlZ2VyKG51bSsiIik7CiAgICAgICAgZmFjdG9yKE4pOwogICAgIAogICAgICAgaW50IHN6ID0gdi5zaXplKCk7CiAgICAgICBDb2xsZWN0aW9ucy5zb3J0KHYpOwogICAgICAgbG9uZyBjbnQgPSAwOwogICAgICAgbG9uZyB0b3QgPSAxOwogICAgICAgZm9yKGludCBpPTA7aTxzejtpKyspewogICAgCSAgIAogICAgCSAgIGNudCA9IDA7CiAgICAJICAgd2hpbGUoaSsxPHN6JiZ2LmdldChpKS5lcXVhbHModi5nZXQoaSsxKSkpewogICAgCQkgCiAgICAJCSAgIGNudCsrOyBpKys7CiAgICAJICAgfQogICAgCSAgIGNudCsrOwogICAgCSAgIHRvdCAqPSAoY250KzEpOwogICAgICAgfQogICAgICAgIFN5c3RlbS5vdXQucHJpbnRsbih0b3QpOwogICAgICAgIAogICAgICAgIAogICAgfQp9
compilation info
Main.java:6: error: class PollardRho is public, should be declared in a file named PollardRho.java
public class PollardRho {
^
Note: Main.java uses unchecked or unsafe operations.
Note: Recompile with -Xlint:unchecked for details.
1 error
stdout