Skip to main content
We’ve updated our Terms of Service. A new AI Addendum clarifies how Stack Overflow utilizes AI interactions.
Code Golf

Return to Answer

deleted 379 characters in body
Source Link
Veskah
  • 4.1k
  • 14
  • 31

PowerShell, (削除) 29 (削除ここまで) 23(削除) 23 (削除ここまで) 21 bytes

-6 bytes thanks to Andrei Odegov

$args-replace'.','$&$&'

Try it online!

#21 byte solution by mazzy splatting the input
-2 bytes thanks to mazzy

-join($args|%{$_+$_})

Try it online!

Not sure if this way meshes with theTakes input specsvia splatting, essentially making it an array of being considered just a "string"chars

PowerShell, (削除) 29 (削除ここまで) 23 bytes

-6 bytes thanks to Andrei Odegov

$args-replace'.','$&$&'

Try it online!

#21 byte solution by mazzy splatting the input

-join($args|%{$_+$_})

Try it online!

Not sure if this way meshes with the input specs of being considered just a "string"

PowerShell, (削除) 29 (削除ここまで) (削除) 23 (削除ここまで) 21 bytes

-6 bytes thanks to Andrei Odegov
-2 bytes thanks to mazzy

-join($args|%{$_+$_})

Try it online!

Takes input via splatting, essentially making it an array of chars

Other people are smarter
Source Link
Veskah
  • 4.1k
  • 14
  • 31

PowerShell, 29(削除) 29 (削除ここまで) 23 bytes

-6 bytes thanks to Andrei Odegov

$args-replace'.','$&$&'

Try it online!

#21 byte solution by mazzy splatting the input

-join("$args"|% t*y|%$args|%{$_+$_})

Try it online! Try it online!

Not sure if this way meshes with the input specs of being considered just a "string"

PowerShell, 29 bytes

-join("$args"|% t*y|%{$_+$_})

Try it online!

PowerShell, (削除) 29 (削除ここまで) 23 bytes

-6 bytes thanks to Andrei Odegov

$args-replace'.','$&$&'

Try it online!

#21 byte solution by mazzy splatting the input

-join($args|%{$_+$_})

Try it online!

Not sure if this way meshes with the input specs of being considered just a "string"

Source Link
Veskah
  • 4.1k
  • 14
  • 31

PowerShell, 29 bytes

-join("$args"|% t*y|%{$_+$_})

Try it online!

AltStyle によって変換されたページ (->オリジナル) /