Question: I'm trying following example :

`python -c "import sys; print sys.argv[1]" "test\ntest"`

Output :

```
test\ntest

```

But I want following 

```
test 
test

```

Update 1#
As @devnull suggested can solve the problem if user itself pass the with `$` but how about python should take care of this ?

I've tried :

```
python -c "import sys; print '$' + sys.argv[1]" 'test\ntest'

```

but output :

```
$test\ntest

```

Answer: 
Tell the shell to pass what you want to see:

```
python -c "import sys; print sys.argv[1]" $'test\ntest'

```

This would produce:

```
test
test

```

The `$'string'` syntax is referred to as [ANSI-C Quoting](http://www.gnu.org/software/bash/manual/bashref.html#ANSI_002dC-Quoting).

---

Another way would be to tell the shell to interpret your *original* output:

```
python -c "import sys; print sys.argv[1]" 'test\ntest' | xargs -0 echo -en

```

This would also produce:

```
test
test

```
Your shell is sending the python script the two literal characters `\` and `n`.

Since you're on bash, I believe if you just press the actual return key after `"test` it will detect you're still entering an argument and let you continue with another `test"` and then pass this to python.