I am learning about Abstraction, and as I have understood so far, Abstraction is basically providing an interface of how to use an object while hiding the implementation details. But does the concept of Abstraction only applies to OOP, I mean if we think of a standalone function (without being a part of a class), using a function is indeed only using its interface without actually caring of how the function is implemented.
Of course a function provides abstraction. Why would a bunch of functions and a this pointer provide abstractions while a single function without a this pointer would not?
If, for example you have a function sort() which sorts some data, it abstracts from the concrete sorting algorithm. If you have a function which is the entry point to a huge piece of code consisting of thousands of sub-functions called in the context of that function, it can even be very abstract. Example: GetRouteFromCurrentLocationTo(...). A router, a position sensor, some geographical database... all that abstracted to a single function name.
Why would it be more of an abstraction if you wrote instead: NavigationSystem navSys; navSys.GetRouteFromCurrentLocationTo(...);
?