API is a broadly term all types are API's comes under API(REST, SO
In JavaScript, a promise is an object that represents
The program should first take the input of array size and then the elements of the array.
Greek mathematician Pythagoras gave famous theorem to relate sides of right angel triangle: