Skip to content

Commit

Permalink
Issue HowProgrammingWorks#3: Task three.
Browse files Browse the repository at this point in the history
  • Loading branch information
Dmitry Porokhnya committed Sep 14, 2019
1 parent 48f48c7 commit cdc1347
Showing 1 changed file with 7 additions and 1 deletion.
8 changes: 7 additions & 1 deletion Exercises/3-by-reference.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,11 @@
'use strict';

const inc = null;
const inc = num => {
num.n += 1;
};

const obj = { n: 5 };
inc(obj);
console.dir(obj);

module.exports = { inc };

0 comments on commit cdc1347

Please sign in to comment.