Dim totalCorrect as integer
Dim questionName as string = ""
console.WriteLine("Please select A, B, C, or D for each question")
console.WriteLine("1. When did the revolutionary war start? A.1775 B.1785 C.1783 D.1800")
answer1 = console.ReadLine()
If answer1 = "A" then total1 = 1 else total1 = 0
If answer1 = "B" then questionName = "Question 1"
If answer1 = "C" then questionName = "Question 1"
If answer1 = "D" then questionName = "Question 1"
Dim questionName2 as string = ""
console.WriteLine(" 2.What year was the constitution signed? A .1777 B .1687 C .1787 D .1887 ")
answer2 = console.ReadLine()
If answer2 = "C" then total2 = 1 else total2 = 0
If answer2 = "A" then questionName2 = "Question 2"
If answer2 = "B" then questionName2 = "Question 2"
If answer2 = "D" then questionName2 = "Question 2"
Dim questionName3 as string = ""
console.WriteLine(" 3.Who was the first president? A.abraham lincoln B.john adams C.george washington D.donald trump ")
answer3 = console.ReadLine()
If answer3 = "C" then total3 = 1 else total3 = 0
If answer3 = "A" then questionName3 = "Question 3"
If answer3 = "B" then questionName3 = "Question 3"
If answer3 = "D" then questionName3 = "Question 3"
Dim questionName4 as string = ""
console.WriteLine(" 4.When did America sign the Declaration of Independence? A .1886 B .1776 C .1996 D .1774 ")
answer4 = console.ReadLine()
If answer4 = "B" then total4 = 1 else total4 = 0
If answer4 = "A" then questionName4 = "Question 4"
If answer4 = "C" then questionName4 = "Question 4"
If answer4 = "D" then questionName4 = "Question4"
Dim questionName5 as string = ""
console.WriteLine(" 5.When was the gold rush in California? A .1848 B .1948 C .1748 D .1884 ")
answer5 = console.ReadLine()
If answer5 = "A" then total5 = 1 else total5 = 0
If answer5 = "B" then questionName5 = "Question 5"
If answer5 = "C" then questionName5 = "Question 5"
If answer5 = "D" then questionName5 = "Question 5"
Dim questionName6 as string = ""
console.WriteLine(" 6.What was the 48 th state of the United States? A.California B.Utah C.New Mexico D.Arizona ")
answer6 = console.ReadLine()
If answer6 = "D" then total6 = 1 else total6 = 0
If answer6 = "A" then questionName6 = "Question 6"
If answer6 = "B" then questionName6 = "Question 6"
If answer6 = "C" then questionName6 = "Question 6"
Dim questionName7 as string = ""
console.WriteLine(" 7.When did the 48 th state become a state? A .1912 B .1812 C .2012 D .1927 ")
answer7 = console.ReadLine()
If answer7 = "A" then total7 = 1 else total7 = 0
If answer7 = "B" then questionName7 = "Question 7"
If answer7 = "C" then questionName7 = "Question 7"
If answer7 = "D" then questionName7 = "Question 7"
DIm questionName8 as string = ""
console.WriteLine(" 8.When did the US and Mexico war begin? A .1846 B .1746 C .1946 D .1646 ")
answer8 = console.ReadLine()
If answer8 = "A" then total8 = 1 else total8 = 0
If answer8 = "B" then questionName8 = "Question 8"
If answer8 = "C" then questionName8 = "Question 8"
If answer8 = "D" then questionName8 = "Question 8"
Dim questionName9 as string = ""
console.WriteLine(" 9.When did the US and Mexico war end? A .1748 B .1848 C .1858 D, 1838 ")
answer9 = console.ReadLine()
If answer9 = "B" then total9 = 1 else total9 = 0
If answer9 = "A" then questionName9 = "Question 9"
If answer9 = "C" then questionName9 = "Question 9"
If answer9 = "D" then questionName9 = "Question 9"
Dim questionName10 as string = ""
console.WriteLine(" 10.We gained 525, 000 square miles after the US and Mexico war? A.True B.False ")
answer10 = console.ReadLine()
If answer10 = "A" then total10 = 1 else total10 = 0
If answer10 = "B" then questionName10 = "Question 10"
If answer10 = "C" then questionName10 = "Question 10"
If answer10 = "D" then questionName10 = "Question 10"
totalCorrect = total1 + total2 + total3 + total4 + total5 + total6 + total7 + total8 + total9 + total10
console.WriteLine("You scored {0} out of 10", totalCorrect)
Console.WriteLine("You missed questions {0}, {1}, {2}, {3} {4}, {5}, {6}, {7}, {8}, {9}.", questionName, questionName2, questionName3, questionName4, questionName5, questionName6, questionName7, questionName8, questionName9, questionName10)