title: Java timer not working correctly
body: <pre><code>....
  
  public class mainClass {
      public mainClass(){
          Timer time = new Timer();
          mainClass.calculate calculate = new mainClass.calculate();
          time.schedule(calculate, 1 * 1000);
      }
  
      public static void main(String[] args){
          new mainClass();
      }
  
      class calculate extends TimerTask{
          @Override
          public void run() {
              System.out.println("working..");
  
          }
      }
  }
  </code></pre>
  
  <p>I saw only one times "working.." message in the console.I want to saw every second "working.." whats the problem on code? and my another problem i want to running every second my own method but how?</p>
  
  <p>Sory for my bad english..</p>