a='Search on Code Golf\xe2\x80\xa6 a'"'_'"' 7,591 , 7,591 reputation \xe2\x97\x8f22 gold badges\xe2\x97\x8f1717 silver badges\xe2\x97\x8f5050 bronze badges Code Golf Home Questions Tags Users Unanswered Return to Question \x09 \x09Became Hot Network Question\x09 occurred 5 hours ago 4\x09added 137 characters in body source edit link edited 12 hours ago Taako 25155 bronze badges inlineside-by-sideside-by-side markdown Requirements: Take a single word input on stdin with only lowercase alphabetical characters (a-z) Output a string where every other character is repeated, with the first repeated character being the second character in the string Example: Input: abcde Output: abbcdde Winning Criteria: Standard code golf. Shortest number of bytes in program wins. Requirements: Take a single word input on stdin with only lowercase alphabetical characters (a-z) Output a string where every other character is repeated, with the first repeated character being the second character in the string Example: Input: abcde Output: abbcdde Winning Criteria: Standard code golf. Shortest number of bytes in program wins. Clarification: For languages with 1-based indexing the output must still match the above, aabccdee is not an acceptable solution. 3\x09added 32 characters in body; edited title source edit rollback link edited 12 hours ago Taako 25155 bronze badges inlineside-by-sideside-by-side markdown Repeat odd index characters Requirements: Take a single word input on stdin with only lowercase alphabetical characters (a-z) Output a string where every odd index character (starting from 0 as first character) is repeated once Example: Input: abcde Output: abbcdde Winning Criteria: Standard code golf. Shortest number of bytes in program wins. Repeat every other character in string starting with second character Requirements: Take a single word input on stdin with only lowercase alphabetical characters (a-z) Output a string where every other character is repeated, with the first repeated character being the second character in the string Example: Input: abcde Output: abbcdde Winning Criteria: Standard code golf. Shortest number of bytes in program wins. \x09 \x09Tweeted twitter.com/StackCodeGolf/status/1223395609018847235\x09 occurred 12 hours ago 2\x09edited tags edit rollback link edited 13 hours ago FryAmTheEggman 15.8k33 gold badges2626 silver badges8686 bronze badges code-golf string 1\x09 source edit rollback link asked 13 hours ago Taako 25155 bronze badges CODE GOLF Tour Help Chat Contact Feedback Mobile Disable Responsiveness COMPANY Stack Overflow Stack Overflow Business Developer Jobs About Press Legal Privacy Policy STACK EXCHANGE NETWORK Technology Life / Arts Culture / Recreation Science Other Blog Facebook Twitter' echo for((;i++<11;)){ echo "$a$b" b=' LinkedIn site design / logo \xc2\xa9 2020 Stack Exchange Inc; user contributions licensed under cc by-sa 4.0 with attribution required. rev 2020.1.30.35927' } echo "${b:1}"
Note that non-ascii characters in the above source code will be escaped (such as \x9f).