title: 1000 * 60 * 60 * 24 * 30 results in a negative number
body: <p>I'm attempting to calculate 30 days by multiplying milliseconds however the result continually ends up being a negative number for the value of days_30  and I'm not sure why. </p>
  
  <p>Any suggestions are greatly appreciated! </p>
  
  <p>CODE SNIPPET:</p>
  
  <pre><code>// check to ensure proper time has elapsed
                  SharedPreferences pref = getApplicationContext()
                          .getSharedPreferences("DataCountService", 0);
                   long days_30 = 1000 * 60 * 60 * 24 * 30;
                   long oldTime = pref.getLong("smstimestamp", 0);
                  long newTime = System.currentTimeMillis();
                   if(newTime - oldTime &gt;= days_30){
  </code></pre>
  
  <p>days_30 value results in: -1702967296</p>
  
  <p>P.S.</p>
  
  <pre><code> double days_30 = 1000 * 60 * 60 * 24 * 30;
                   double oldTime = pref.getLong("smstimestamp", 0);
                  double newTime = System.currentTimeMillis();
                   if(newTime - oldTime &gt;= days_30){
  </code></pre>
  
  <p>Results in a smaller - but still negative number. -1.702967296E9</p>