I guessed that. But, thanks for confirming it. Better to be in the know than the guess.
Anyway, spent 3hrs on the CodeAcademy.com tutorial. Completed 2 sections.
3rd section is: Control Flow Switch.
Leaving this for tomorrow. Was nearly rolling off my chair nodding. If you stay too long infront of your computer, all alone in a room then sleep overtakes you. I just started listening to music to keep me awake. Lol!
Right now, I will continue my projects, where I left-off last night.
PS - Took too long to complete 2 sections because I was asking questions in this forum and was making notes of member replies and experimenting too. Aswell as building a bot on the side (.exe) to help me remember important things when I forget them.
You can also echo each of the elements separately without concatenating them, simply listing them with a comma between each element. It’s actually more efficient to do this as the interpreter doesn’t have to perform a concatenation.
echo "Hello,", " ", "world", "!";
Of course the most efficient would be to output the string in one go.
echo "Hello, world!";
So, comma does the same job as the concatenating dot ?
I really think this is not the case and there is more to it but in my case it (comma) will do the job. Right ?
You are welcome to always show more examples of using the dot and the comma and how they would display things etc. differently and same. Anything you share is welcome!
No! dot is concatenate; comma indicates a list - in this case a list of things (strings) to be output. So, although in this case the end result is the same, it is not the same thing.
I had a feeling this was the case.
This topic was automatically closed 91 days after the last reply. New replies are no longer allowed.