Course Object

by Michael Prosser

JavaScript

var Course = function(name,pages,questions){

	this.name = name;
  this.pages = pages;
  this.questions = questions;
  
  var Question = function(html,answers,correctAnswerIndex){

    this.html = html;
    this.answers = answers;
    this.correctAnswerIndex = correctAnswerIndex;
    
    return 5;

  }
  
  this.QUESTION = Question('',Array(),0);

}

var course = new Course("MY COURSE",Array(),Array());

alert(course.QUESTION);