0

could you guys find some problems in my codding?? ㅠㅠ

hey guys i need your help. i don't know why i can't operate this codding what i made. could you give me a method? function animal(kind,age) { this.kind = kind; this.age = age; this.changeAge = fuction(age){ this.age = age; } } var a = new animal("cat",4); a.age(6); document.alert(a.age)

24th Apr 2018, 8:04 AM
지승희
지승희 - avatar
2 odpowiedzi
+ 3
i see some errors, a.age(6) is not a function it should rather be: a.changeAge(6) also document.alert is wrong: its either document.write() or window.alert()
24th Apr 2018, 8:24 AM
᠌᠌Code X
᠌᠌Code X - avatar
+ 3
Can you put tag #Korean and post a korean version of it? I could help you there:)
24th Apr 2018, 10:19 AM
syul
syul - avatar