Asynchronous VS Synchronous Function

To understand both concepts let’s make it simple for you.

The synchronous function let’s asume that you are in video game , each level requires certain score to move for the next .In this case we are moving level by level , this is how the synchronous function works.

For the asychronous function, let’s asume that each level devided into mini-levels and in order to finish the level you are asked to score all the mini-levels.

So the Asynchronous function is that if you’re doing multiple things at the same time, you don’t have to wait until the end of the current one before moving on to the next one. Unlike the synchronous function where only one operation can be in progress at a time.

--

--

--

Love podcasts or audiobooks? Learn on the go with our new app.

Recommended from Medium

Some Useful Things Should Know About JavaScript

An Introduction To Svelte

Web Components + React Hooks = Haunted 🦇 🎃

Top 30 Angular Interview Questions and Answers

JavaScript Common Interview Questions

JavaScript: Template Literals (ES6)

Property-Based Testing with JSVerify

Dungeons & Dragons & the DOM: An Introduction to JavaScript DOM Manipulation

Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store
LOkmen Abid

LOkmen Abid

More from Medium

CS373 Spring 2022: Jack Si

3D printer custom Internal Camera for < $20 dollar

Fighting Clean: Predicting UFC Battle Outcomes

SAP Net Weaver Gateway O DATA & RFC Performance Testing