Skip to content

Instantly share code, notes, and snippets.

@jasonmitchell
Created March 13, 2020 16:08
Show Gist options
  • Save jasonmitchell/3d1b143d66807bcf564678251566ae42 to your computer and use it in GitHub Desktop.
Save jasonmitchell/3d1b143d66807bcf564678251566ae42 to your computer and use it in GitHub Desktop.
// source https://jsbin.com
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width">
<title>JS Bin</title>
</head>
<body>
<script id="jsbin-javascript">
function reverse(s) {
for (var i = s.length - 1, o = ''; i >= 0; o += s[i--]) { }
return o;
}
console.log(reverse('hello world'));
</script>
<script id="jsbin-source-javascript" type="text/javascript">function reverse(s) {
for (var i = s.length - 1, o = ''; i >= 0; o += s[i--]) { }
return o;
}
console.log(reverse('hello world'));</script></body>
</html>
function reverse(s) {
for (var i = s.length - 1, o = ''; i >= 0; o += s[i--]) { }
return o;
}
console.log(reverse('hello world'));
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment