¿Qué es este extraño código? [cerrado]

I have stumbled across this code:


It should obviously return 0, but for some reason returns 1337. Is this some kind of trick i dont know?

preguntado el 28 de mayo de 14 a las 13:05

¿Acaso te has sordeado intencionalmente put 1337 invisible characters in there? (specifically, U+206d) -

i would say the expected result is weird -

@MatteoTassinari this is the JS violín with the OP's string copy/pasted into it. It shows the 1337 length. -

The effect is kind of ruined when your browser fails to perform font substitution and instead renders 1337 little "unknown character" boxes XD -

1 Respuestas

El código es:

Since the string is made of 1337 "invisible" characters, the length is 1337.

contestado el 28 de mayo de 14 a las 14:05

Thank you for not being mean! - Wazzaps

@Dvidunis Downvoting != being mean. It just means your question kinda sucks :p - Niet el oscuro Absol

I meant the comments.. - Wazzaps

No es la respuesta que estás buscando? Examinar otras preguntas etiquetadas or haz tu propia pregunta.