I want to know if user would return to the home screen if he exit the current activity.
I'm going to post the comment of @H9kDroid as the best answer here for people that have a similar question.
You can use isTaskRoot() to know whether the activity is the root of a task.
I hope this helps