age = 10
statement = 'You are %d years old' % age
Ugh
Here is a Robot Framework way:
${age}= 10
${statement}= Catenate You are ${age} years old
-Tatu
--
You received this message because you are subscribed to the Google Groups "robotframework-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to robotframework-u...@googlegroups.com.
To post to this group, send email to robotframe...@googlegroups.com.
Visit this group at http://groups.google.com/group/robotframework-users.
For more options, visit https://groups.google.com/groups/opt_out.
Ugh
Here is a Robot Framework way:
${age}= 10
${statement}= Catenate You are ${age} years old-Tatu
On 14 Jan 2014 06:36, "Winston Ma" <winsto...@gmail.com> wrote:
I know how to combine string using Catenate. However I have no idea how to join these into one statement--
Here is the python way:age = 10statement = 'You are %d years old' % ageHow could I do string substitution?Thanks in advance
You received this message because you are subscribed to the Google Groups "robotframework-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to robotframework-users+unsub...@googlegroups.com.
age = 10
sex='female'
statement = 'You are %s, %d years old' % (sex, age)