3 edited body
source | link

Perl, 24 23 bytes

Includes +1 for -p

Give string on STDIN without newline (or add a -pl option to the program)

echo -n Hello | nest.pl

nest.pl:

#!/usr/bin/perl -p
$\=")"x s/.(?=.)/$&(/g

Perl, 24 23 bytes

Includes +1 for -p

Give string on STDIN without newline (or add a -p option to the program)

echo -n Hello | nest.pl

nest.pl:

#!/usr/bin/perl -p
$\=")"x s/.(?=.)/$&(/g

Perl, 24 23 bytes

Includes +1 for -p

Give string on STDIN without newline (or add a -l option to the program)

echo -n Hello | nest.pl

nest.pl:

#!/usr/bin/perl -p
$\=")"x s/.(?=.)/$&(/g
2 added 73 characters in body
source | link

Perl, 2424 23 bytes

Includes +2+1 for -lpp

Give string on STDIN: without newline (or add a -p option to the program)

nest.plecho <<<-n Hello | nest.pl

nest.pl:

#!/usr/bin/perl -lpp
$\=")"x s/.(?=.)/$&(/g

Perl, 24 bytes

Includes +2 for -lp

Give string on STDIN:

nest.pl <<< Hello

nest.pl:

#!/usr/bin/perl -lp
$\=")"x s/.(?=.)/$&(/g

Perl, 24 23 bytes

Includes +1 for -p

Give string on STDIN without newline (or add a -p option to the program)

echo -n Hello | nest.pl

nest.pl:

#!/usr/bin/perl -p
$\=")"x s/.(?=.)/$&(/g
1
source | link

Perl, 24 bytes

Includes +2 for -lp

Give string on STDIN:

nest.pl <<< Hello

nest.pl:

#!/usr/bin/perl -lp
$\=")"x s/.(?=.)/$&(/g