Skip to main content
Commonmark migration
Source Link

#PHP → JavaScript (ES6), 20 24 bytes#

PHP → JavaScript (ES6), 20 24 bytes

Reading from STDIN is always expensive in PHP. It looks a bit strange:

x=>x+<?fgets(STDIN);

It prints x=>x+ and waits for user input to complete the string, terminates with the complete anonymous JavaScript function, e.g. x=>x+2.

First version (24 bytes)

<?='x=>x+'.fgets(STDIN);

#PHP → JavaScript (ES6), 20 24 bytes#

Reading from STDIN is always expensive in PHP. It looks a bit strange:

x=>x+<?fgets(STDIN);

It prints x=>x+ and waits for user input to complete the string, terminates with the complete anonymous JavaScript function, e.g. x=>x+2.

First version (24 bytes)

<?='x=>x+'.fgets(STDIN);

PHP → JavaScript (ES6), 20 24 bytes

Reading from STDIN is always expensive in PHP. It looks a bit strange:

x=>x+<?fgets(STDIN);

It prints x=>x+ and waits for user input to complete the string, terminates with the complete anonymous JavaScript function, e.g. x=>x+2.

First version (24 bytes)

<?='x=>x+'.fgets(STDIN);
added 10 characters in body
Source Link

#PHP → JavaScript (ES6), 20 24 bytes#

Reading from STDIN is always expensive in PHP. It looks a bit strange:

x=>x+<?fgets(STDIN);

It prints x=>x+ and waits for user input to complete the string, terminates with the complete anonymous JavaScript function, e.g. x=>x+2.

First version (24 bytes)

<?='x=>x+'.fgets(STDIN);

#PHP → JavaScript (ES6), 20 24 bytes#

Reading from STDIN is always expensive in PHP. It looks a bit strange:

x=>x+<?fgets(STDIN);

It prints x=>x+ and waits for user input to complete the string, terminates with the complete JavaScript function, e.g. x=>x+2.

First version (24 bytes)

<?='x=>x+'.fgets(STDIN);

#PHP → JavaScript (ES6), 20 24 bytes#

Reading from STDIN is always expensive in PHP. It looks a bit strange:

x=>x+<?fgets(STDIN);

It prints x=>x+ and waits for user input to complete the string, terminates with the complete anonymous JavaScript function, e.g. x=>x+2.

First version (24 bytes)

<?='x=>x+'.fgets(STDIN);
edited body
Source Link

#PHP → JavaScript (ES6), 20 24 bytes#

Reading from STDIN is always expensive in PHP. This one isIt looks a bit strange but the result is the same as in my first version:

x=>x+<?fgets(STDIN);

IfIt prints x=>x+ and waits for user input to complete the string, terminates with the complete JavaScript function, e.g. x=>x+2.

First version:First version (24 bytes)

<?='x=>x+'.fgets(STDIN);

#PHP → JavaScript (ES6), 20 24 bytes#

Reading from STDIN is always expensive in PHP. This one is a bit strange but the result is the same as in my first version:

x=>x+<?fgets(STDIN);

If prints x=>x+ and waits for user input to complete the string, terminates with the complete JavaScript function.

First version:

<?='x=>x+'.fgets(STDIN);

#PHP → JavaScript (ES6), 20 24 bytes#

Reading from STDIN is always expensive in PHP. It looks a bit strange:

x=>x+<?fgets(STDIN);

It prints x=>x+ and waits for user input to complete the string, terminates with the complete JavaScript function, e.g. x=>x+2.

First version (24 bytes)

<?='x=>x+'.fgets(STDIN);
Source Link
Loading