I'm writing a program for encryption, for fun. I ran across something odd, and I'd like some input!
Examine this code:
private static final String primeNumber = "32416190071";
private String stringKey = "";
private String hexKey = "";
private long longKey;
public void example(){
stringKey = primeNumber;
longKey = Long.parseLong(primeNumber);
}
now, if i put longKey = 32416190071;
, i get an error stating that i cant put that big of a number in a long. what am I doing wrong, or what is going on?
Thanks!
Food for thought -_-