To see the hidden Dock, move the pointer to the edge of the screen where the Dock is located. Show indicators for open applications. Show a small black dot below an app’s icon in the Dock when the app is open. Show recent applications in Dock. Show recently opened apps (if they aren’t already included in the Dock) toward one end of the Dock.
macOS Mojave added a new feature to the Dock: it now shows your three most recent apps. This section sits between your collections of app icons on the left and the section of the right that shows your open apps.
I find it convenient; however, you may not. If so, you can disable this feature. Go to System Preferences > Dock and uncheck the box at the bottom for Show recent applications in Dock.
These instructions apply, for the most part, to other versions of macOS besides Catalina. However, I’m using Catalina on a 16-inch MacBook Pro for this tutorial.