Results 1 to 5 of 5

Thread: please help !!!

  1. #1
    fadiRU is offline Member
    Join Date
    Jan 2009
    Posts
    4
    Rep Power
    0

    Default please help !!!

    hello .. please anyone help me .
    i need to write this code :

    Create a program to simulate timer, using threads .
    the timer takes number of seconds to count and keep incrementing until it reaches the alarm time.
    Your program must display the current value of the timer each second.
    Your program should create 2 timers.

  2. #2
    Steve11235's Avatar
    Steve11235 is offline Senior Member
    Join Date
    Dec 2008
    Posts
    1,046
    Rep Power
    8

    Default

    Yes, you do need to write the code.

    Look at Thread.sleep(). That's how you make a thread wait for a certain time.

    Look at System.currentTimeMillis(). That tells you the current time in milliseconds. You can also look at Date.

    Look at Thread. That is the class that allows you to create and control threads.

  3. #3
    fadiRU is offline Member
    Join Date
    Jan 2009
    Posts
    4
    Rep Power
    0

    Default

    Steve :( thank u , i will try , the problem is im really bad at java !!
    but anyways thank u very much :)

  4. #4
    Steve11235's Avatar
    Steve11235 is offline Senior Member
    Join Date
    Dec 2008
    Posts
    1,046
    Rep Power
    8

    Default

    There's only one way to get better!

  5. #5
    fadiRU is offline Member
    Join Date
    Jan 2009
    Posts
    4
    Rep Power
    0

    Default

    true !
    but will u help me with the errors please ?
    i'll write the code , and i'll post it tomorrow . if there is anything wrong would u please help me :) ?

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •