Skip to content

Commit 1168525

Browse files
authored
Create 1108-defanging-an-ip-address.js
1 parent c60bb26 commit 1168525

File tree

1 file changed

+7
-0
lines changed

1 file changed

+7
-0
lines changed

1108-defanging-an-ip-address.js

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
/**
2+
* @param {string} address
3+
* @return {string}
4+
*/
5+
const defangIPaddr = function(address) {
6+
return address.split('.').join('[.]')
7+
};

0 commit comments

Comments
 (0)