You are working on a repository that contains three branches: main, feature, and hotfix. Your task is to use the Git checkout command to navigate between these branches and verify the branch transitions. Additionally, you must use Git shorthand commands as part of your solution. Note that the current branch is main.
Please perform the following steps:
Switch to the
featurebranch from themainbranch;Switch to the
hotfixbranch from thefeaturebranch;Use a shorthand command to switch back to the previous branch twice in a row;
Use a shorthand command to switch back to the previous branch again;
Use a shorthand command to switch directly to the main branch;
Ensure to navigate through all the branches in the correct sequence.
Write all the commands below one command per line.