My Understanding of JavaScript (based on the program)

  • JavaScript does support OOP (Object-Oriented Programming), but classes are in the form of functions
  • Python has "print("Hello, World!")," while JavaScript has "console.log("Hello, World!")."
  • The OOP features in JavaScript that were demonstrated in the program were initialization, constructor methods, and instantiation. These are all under the OOP concept of Encapsulation.
  • HTML integration using the "._toHTML()" method was used.
function logItType(output) {
    console.log(typeof output, ";", output);
}

function TeamMember(name, ghID, classOf) {
    this.name = name;
    this.ghID = ghID;
    this.classOf = classOf;
    this.role = "";
}

TeamMember.prototype.setRole = function(role) {
    this.role = role;
}

TeamMember.prototype.toJSON = function() {
    const obj = {name: this.name, ghID: this.ghID, classOf: this.classOf, role: this.role};
    const json = JSON.stringify(obj);
    return json;
}

var scrumZaddae = new TeamMember("Samarth", "Samarth Kalanke", 2025);
scrumZaddae.setRole("Teacher");

var teamMembers = [ 
    new TeamMember("Paaras", "PaarasPurohit", 2025),
    new TeamMember("Haoxuan", "JasoXDDD", 2024),
    new TeamMember("AJ", "KKcbal", 2024)
];

function Classroom(teacher, students){
    
    teacher.setRole("Teacher");
    this.teacher = teacher;
    this.classroom = [teacher];
    
    this.students = students;
    this.students.forEach(student => { student.setRole("Student"); this.classroom.push(student); });
    
    this.json = [];
    this.classroom.forEach(person => this.json.push(person.toJSON()));
}

agileTeam = new Classroom(scrumZaddae, teamMembers);

Classroom.prototype._toHtml = function() {
    var style = (
      "display:inline-block;" +
      "background:black;" +
      "border: 2px solid grey;" +
      "box-shadow: 0.8em 0.4em 0.4em grey;"
    );
  
    var body = "";
    
    body += "<tr>";
    body += "<th><mark>" + "Name" + "</mark></th>";
    body += "<th><mark>" + "GitHub ID" + "</mark></th>";
    body += "<th><mark>" + "Class Of" + "</mark></th>";
    body += "<th><mark>" + "Role" + "</mark></th>";
    body += "</tr>";
    
    for (var row of agileTeam.classroom) {
      
      body += "<tr>";
      
      body += "<td>" + row.name + "</td>";
      body += "<td>" + row.ghID + "</td>";
      body += "<td>" + row.classOf + "</td>";
      body += "<td>" + row.role + "</td>";
      
      body += "<tr>";
    }
  
    
    return (
      "<div style='" + style + "'>" +
        "<table>" +
          body +
        "</table>" +
      "</div>"
    );
  
  };
  
  // IJavaScript HTML processor receive parameter of defined HTML fragment
  $$.html(agileTeam._toHtml());
</table></div> </div> </div> </div> </div> </div>

What's the use?

  • Tables can be used for problem solving tracking
  • OOP is an extremely useful concept for solving many problems in programming
  • Front matter concepts are quite useful

Errors I Ran Into

  • Time complexity was an issue
  • Communication was close to none
  • Github errors with VsCode stopped a lot of things from happening, and could not be solved because of time complexity

Solutions for the Future

  • Create a plan
  • Make sure everyone was communicating. It could have been a team problem, or it could have been me. Either way, we as a team need to fix it or find a better team structure.
  • Go during office hours or before school to get errors fixed.
</div>
Name GitHub ID Class Of Role
Samarth Samarth Kalanke 2025 Teacher
Paaras PaarasPurohit 2025 Student
Haoxuan JasoXDDD 2024 Student
AJ KKcbal 2024 Student