JavaScript Tutorial in Hindi for Beginners [Part 27] - Object Methods in JavaScript

preview_player
Показать описание
#Javascript #Tutorial #Hindi

In this video i will talk about Object Methods in JavaScript.

Defining methods

A method is a function associated with an object, or, put differently, a method is a property of an object that is a function. Methods are defined the way normal functions are defined, except that they have to be assigned as the property of an object.

Join this channel to support Tech Gun:
Рекомендации по теме
Комментарии
Автор

Thank you for your efforts bro love from Nepal

ganeshkhadka
Автор

Kindly complete the course as soon as possible

riniroy
Автор

Can we use the same name of a property in a different function?

ak.__
Автор

Sir, please upload a video of html and css website project turorial

maimonaabid
Автор

Bro how to change object key and value

manurajput
Автор

let saikat = {
fname: "SAIKAT",
lname : "PATRA",
Age : 25

}

saikat.height = 6;

function fun (num1, num2){
console.log(`${num1} x ${num2} = ${num1*num2}`)
}

saikat.sayhello = fun(2, 3);

for (let key in saikat){
document.write(`${key} : ${saikat[key]}`);
document.write("<br>")
}
here output is
fname : SAIKAT
lname : PATRA
Age : 25
height : 6
sayhello : undefined => how to solve this ??

saikatpatra