The score on a trivia game is obtained by subtracting the number of incorrect answer from twice the number of correct answer. If a player answered 50 total question and obtained a score of 40 , how many questions did the player answer correctly?