SESION 07 - laboratorio
12
GUÍA DE LABORATORIO SEMANA 07 EJERCICIOS JAVASCRIPT
-
Upload
farid-gamarra-floreano -
Category
Documents
-
view
18 -
download
5
Transcript of SESION 07 - laboratorio
function Persona(nombre) {
this.nombre = nombre;
this.color_pelo = 'negro';
this.peso = 75;
this.altura = 165;
this.sexo = 'varón';
this.edad= 26;
}
Para definir un objeto de esta clase, sólo
tendríamos que hacer esto:
var hombre = new Persona('Pepe');