Hello Everybody,
This is my first script, and I am looking for advice...
I am trying to get the variable "response" to populate in another variable called body.
You can see here what I'm trying to do. I tried the following
...and...
And I tried other variations but I can't seem to find the right way to do this.
Any help would be appreciated.
This is my first script, and I am looking for advice...
I am trying to get the variable "response" to populate in another variable called body.
You can see here what I'm trying to do. I tried the following
1 2 3 |
def get_hostname(): response = raw_input ( "Please enter your name: " ) body = '[{"hostname": "response"}]' |
1 2 3 |
def get_hostname(): response = raw_input ( "Please enter your name: " ) body = '[{"hostname": "print(response)"}]' |
Any help would be appreciated.