JSFiddle - React, Tailwind, and code Playground

by Kirubel Girma

JavaScript

class Moura {
  constructor(name) {
    this.name = name;
  }

  introduce() {
    console.log(`Introducing the one and only, ${this.name}!`)
  }

  #addThis(name) {
    return name
  }

  add(firstNumber, secondNumber) {
  	const con = this.#addThis("Added this");
    console.log(firstNumber + secondNumber + con)
  }
}

const IntroMoura = new Moura("Kirubel");

IntroMoura.introduce()