CodePen

HTML

            
              
            
          
!

CSS

            
              
            
          
!
? ?
? ?
Must be a valid URL.
+ add another resource
via CSS Lint

JS

            
              var p = function () {
    this.x= 0
    this.y= 0
    this.z= 0

    return {
        moveBy: function (i, j, k) {this.x+=i; this.y+=j; this.z+=k;},
        moveTo: function (i, j, k) {this.x=i; this.y=j; this.z=k;},
        show: function () {console.log("Current position is",this.x,",",this.y,",",this.z)}
    }
}()
            
          
!
Must be a valid URL.
+ add another resource
via JS Hint
Loading ..................