Synchronous does not mean single-threaded,
asynchronous does not mean parallel
Async - not schedule (no specifed start time) - run whenever he can
Sync - schedule (specifed start time - sequence) -
after function not start if before not run
That means in any language...
Async can be one thread, concurrent or parallel
At the same time, the same program is playing on all TV sets, it has a fixed schedule, therefore it is synchronized. Asynchronously, he wouldn't have and wouldn't play at the same time(or played), that's why.
At the same time, everyone has lessons at school(have schedule).The schedule may be different, it could be in sequence, not all at once. Asynchronous can be all at once, sequence indifferently.
At the same time means a schedule and not that the functions are executed at the same time.
Therefore, the asynchronous function when it finds a free thread will execute without waiting for the previous one to finish and will not block the next one as long as there is a free thread(then it will be parallel
),
provided the programming language or specific function supports threads, otherwise it will just be async
async: (3) (1) (2)
sync: (1) (2) (3)
parallel:
(1)
(3)
(2)
concurrent::
--(1)
------ (2)
-------------(3)
Sorry for my english i use translator