Question: For `(int -> int) -> int = <fun>` the corresponding expression can be `fun x -> (x 1) + 1`.  

Is it possible to have an expression with `int -> (int -> int) = <fun>` type? If not then why?

Answer: 
You can split your url by `/` and take needed element (first remove `http://` part):

```js
var str = 'http://test.com/en/country/city';

str = str.replace('http://', '');

var parts = str.split('/');
console.log(parts);

alert(parts[2]+', '+parts[3]);
```
Use split function to get second last value.

Try this 

```
var url='http://test.com/en/country/city';

var splitArray=url.split('/');

alert(splitArray[splitArray.length-2]);

```