Ruby

```
~ $ irb
1.9.3p362 (main):001:0> File.join("foo/bar", "../baz")
"foo/bar/../baz"
```

node.js
```
~ $ nodejs
> require('path').join("foo/bar", "../baz")
'foo/baz'
```