Will you get the time slice as soon as the java timer timer time arrives?

in other words, will the timer be executed as soon as the cpu time is up, or do you need to wait for other threads to give up the cpu?
is this the same as Thread.sleep ()?

Mar.03,2021

what happens if your computer has only one core and two timers at the same time are turned on at the same time?

it's good to think for yourself before asking questions


that is to say, when the time comes for timer and thread.sleeep (), will the situation be the same? Except for one that excludes the time during the execution of the task, and one that does not rule out, everything else is the same, right?

MySQL Query : SELECT * FROM `codeshelper`.`v9_news` WHERE status=99 AND catid='6' ORDER BY rand() LIMIT 5
MySQL Error : Disk full (/tmp/#sql-temptable-64f5-1e90456-68a33.MAI); waiting for someone to free some space... (errno: 28 "No space left on device")
MySQL Errno : 1021
Message : Disk full (/tmp/#sql-temptable-64f5-1e90456-68a33.MAI); waiting for someone to free some space... (errno: 28 "No space left on device")
Need Help?