class Creature {
constructor(age, brain, eyes) {
this.age = age;
this.brain = brain;
this.eyes = eyes;
}
}
class People extends Creature {
constructor(age, brain, eyes, intelect) {
super(age, brain, eyes);
this.intelect = intelect;
}
}
class DomesticAnimals extends Creature {
constructor(age, brain, eyes, InHome) {
super(age, brain, eyes);
this.InHome = InHome;
}
}
class WildAnimals extends Creature {
constructor(age, brain, eyes, InForest) {
super(age, brain, eyes);
this.InForest = InForest;
}
}
class OrdinaryBirds extends Creature {
constructor(age, brain, eyes, gentle) {
super(age, brain, eyes);
this.gentle = gentle;
}
}
class ProdetoryBirds extends Creature {
constructor(age, brain, eyes, wild) {
super(age, brain, eyes);
this.wild = wild;
}
}
class OrdinaryFish extends Creature {
constructor(age, brain, eyes, toothless) {
super(age, brain, eyes);
this.toothless = toothless;
}
}
class ProdetoryFish extends Creature {
constructor(age, brain, eyes, WithTooth) {
super(age, brain, eyes);
this.sharpTooth = WithTooth;
}
}
class IncectWithLeg extends Creature {
constructor(age, brain, eyes, WithLag) {
super(age, brain, eyes);
this.WithLag = WithLag;
}
}
class IncectWithoutLeg extends Creature {
constructor(age, brain, eyes, WithoutLeg) {
super(age, brain, eyes);
this.Withouteg = WithoutLeg;
}
}
const person = new People(18, 1, 2, "bor");
const cow = new DomesticAnimals(4, 1, 2, "true");
const lion = new WildAnimals(5, 1, 2, "true");
const parrot = new OrdinaryBirds(1, 1, 2, "true");
const eagle = new ProdetoryBirds(10, 1, 2, "carnivore");
const fish = new OrdinaryFish(1, 1, 2, "true");
const shark = new ProdetoryFish(2, 1, 2, "sharpTooth");
const ant = new IncectWithLeg(1, 1, 2, "six legs");
const worm = new IncectWithoutLeg(2, 1, 2, "true");
console.log(person);
console.log(cow);
console.log(lion);
console.log(parrot);
console.log(eagle);
console.log(fish);
console.log(shark);
console.log(ant);
console.log(worm);π3π₯1
I'M_DEVELOPERπ¨βπ»
class Creature { constructor(age, brain, eyes) { this.age = age; this.brain = brain; this.eyes = eyes; } } class People extends Creature { constructor(age, brain, eyes, intelect) { super(age, brain, eyes); this.intelect = intelect;β¦
Bugungi vazifa kerak bo'lib qolar kimgadirπ
π₯1π¨βπ»1
Kanaldan uzoqlashmang qiziqarli narsalar hali oldinda π
π₯1π1
