Created
March 25, 2019 23:45
-
-
Save roblogic/c856c9607b5d29ff856d1c45c8807a75 to your computer and use it in GitHub Desktop.
Golf solution to "The third string", https://codegolf.stackexchange.com/a/182195/15940
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
[ ${#1} = 0 ]&&{ x="$2";}||{ x="$1";} | |
for((;i++<4;)){ | |
o=$i${x:1} | |
[[ $o != $1 ]]&&[[ $o != $2 ]]&&{ echo $o;exit;} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment