Jump to content
Larry Ullman's Book Forums
dorich

Creating Variables Within Conditionals

Recommended Posts

My beginners mind is just puzzled by the building of the variable 'birthdate' in the examples on page 126.

 

"birthdate" is created from the concatenation of three pieces of data.

 

However, there appears to be no explicit statement doing the concatenation.

 

Instead "birthdate" is equated to a different variable in each of the three conditional statements. Given that a variable can be changed on the fly I expected that the value of "birthdate" would change each time it was restated.

 

Obviously I'm missing something or there is something implicit in the conditionals that does the concatenation.

 

Why does the concatenation take place?

 

Any pointers to references or online explanations would be appreciated.

Share this post


Link to post
Share on other sites

Sorry I didn't get to your question before, but I'm glad you figured it out. Let us know if you have any more questions.

Share this post


Link to post
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...

×
×
  • Create New...