Hi eveybody
I am trying to do find your hat project in javascript.
according to the first 2 assignments i need to initial a 2 dimantional array and print it to the console.
this is my code:
class Field {
constructor(){
this.field = [[]];
}
print(){
console.log(this.field.join(''));
}
}
const myField = new Field([[pathCharacter,fieldCharacter,hole],[fieldCharacter,hole,hole],[fieldCharacter,hat,fieldCharacter]]);
myField.print();
the code isn’t right.
what is the right why of doing it?
thanks
Dorit