« first day (4380 days earlier)      last day (579 days later) » 

1:08 PM
When I run echo "abc" in my shell, the program echo really only "sees" abc as the parameter value, right? Because the double quotes are a shell feature (described in 2.2.3 Double-Quotes for the POSIX shell) and not literals. Is that correct?
 
@rattlesnake correct. If you want literal quotes you would do echo '"abc"' or echo \"abc\"
 
@jesse_b Alright thanks! :) I'm taking baby steps here, so I don't make a mistake. So, reading the last paragraph of 2.2.3 Double-Quotes, it says that the backslash can be used as an escape character when followed by a double quote for example. According to 2.2.1, the escape character preserves "the literal value of the following character". So I think in addition to your suggestions, I could also use echo "\"abc\""?
 
1:26 PM
@rattlesnake This is all correct.
The different between echo \"abc\" and echo "\"abc\"" is that the string "abc" is quoted in the latter example. With this particular string, it makes no difference whether the string is quoted or not.
 
Haha okay then my question is totally wrong. I think I'm just going to write down my findings in an answer myself?
Thanks for your reassurance, everyone :)
 
1:50 PM
Okay, so one final question to see if I understand everything now. echo \" will see " and print ", echo "\"" will see " and print ", however echo \\\" (and therefore also echo "\\\"") will see \" and is therefore undefined, yes?
 
@rattlesnake "Implementation defined", which is not "undefined".
 
Fair enough :) I meant "undefined by POSIX"
 
@rattlesnake No, implementation-defined, by POSIX.
It's another way of explicitly saying "hey, you better read the manual".
The terms "implementation-defined" and "undefined" (and "unspecified") are different and are defined here: pubs.opengroup.org/onlinepubs/9699919799/basedefs/…
 
Haha yes I was looking for that
I didn't mean "undefined" like that. I just meant it like "the specific behavior is not written in POSIX because they refer to the implementation manual"
 
Ok.
 
1:57 PM
But you're definitely right and I was technically wrong ;)
 
So, to recap, giving a slash to echo is a valid thing to do, and the implementation decides what this means.
 
Yes. So it's not something I'd want to do. But I wasn't doing it with echo "\"abc\"" anyway, so it doesn't matter.
 
@rattlesnake Correct.
 
Thank you so much :)
 
You are welcome
 
2:38 PM
@jesse_b "The swarms were placed at the entrances of the logic gates and encouraged to move by a shadow intended to convince the crabs that there was a predatory bird overhead."
This means it's a shadow-powered computer, not a crab-powered one.
 
Your finger pressed the power button on your computer, is it powered by humans or electricity?
 
@jesse_b I interact via the input device. I don't run the computer via my keyboard.
I mean, I don't use my fingers to tell the computer to light up individual pixels of the screen in patterns that make up letters that, in turn, make up the new email that just arrived. Making crabs run in certain directions and calling it a computer is like writing "100111001" on a piece of paper and calling it memory.
 
My understanding was just that the shadow convinces them to walk into the gate
not tells them which direction to travel
Plus you do have the manually program the first set of gates even though in modern computing there are several layers of separation
The idea is that you can chain several gates together to perform computations on the initial input
 

« first day (4380 days earlier)      last day (579 days later) »