Interpolation with curly braces

Author Topic: Interpolation with curly braces  (Read 1676 times)

Offline chinmay.sahooTopic starter

  • Trade Count: (0)
  • Full Member
  • ***
  • Thank You 2
  • Posts: 158
  • Karma: 0
    • We Helpline
Interpolation with curly braces
« on: 01-09-2017, 06:01:05 »
In most situations, you can simply include a variable in a doubly quoted string, and the variable’s value will be spliced into the string when it is interpreted. There are two situations where the string parser might very reasonably get confused and need more guidance from you. The first situation is when your notion of where the variable name should stop is not the same as the parser’s, and the other occurs when the expression you want to have interpolated is not a simple variable. In these cases, you can clear things up by enclosing the valueyou want interpolated in curly braces: {}.


Related Topics

  Subject / Started by Replies Last post
0 Replies
Last post 05-21-2016, 06:05:20
by chinmay.sahoo