コード例 #1
0
ファイル: Program.cs プロジェクト: AlanWisny/Quizzerino1
        public static void presentQuestion(ChoiceQuestion q)
        {
            q.display();
            Console.Write("Your answer: ");
            String response = Console.ReadLine();

            Console.WriteLine(q.checkAnswer(response));    // checkt of het overeenkomt
        }
コード例 #2
0
ファイル: Program.cs プロジェクト: AlanWisny/Quizzerino1
        static void Main(string[] args)
        {
            ChoiceQuestion first = new ChoiceQuestion();

            first.setText("What was the original name of the Java language?");
            first.addChoice("*7", false);
            first.addChoice("Duke", false);
            first.addChoice("Oak", true);
            first.addChoice("Gosling", false);


            presentQuestion(first);
        }