1answer.
Ask question
Login Signup
Ask question
All categories
  • English
  • Mathematics
  • Social Studies
  • Business
  • History
  • Health
  • Geography
  • Biology
  • Physics
  • Chemistry
  • Computers and Technology
  • Arts
  • World Languages
  • Spanish
  • French
  • German
  • Advanced Placement (AP)
  • SAT
  • Medicine
  • Law
  • Engineering
Stolb23 [73]
3 years ago
11

Write two statements to read in values for my_city followed by my_state. Do not provide a prompt. Assign log_entry with current_

time, my_city, and my_state. Values should be separated by a space. Sample output for given program if my_city is Houston and my_state is Texas: 2014-07-26 02:12:18: Houston Texas Note: Do not write a prompt for the input values. 1 current_time = '2014-07-26 02:12:18:' 2 my_city = "' 3 my_state = "" 4 log_entry - "' 1 test passed 6 print(log_entry) All tests passed Run Run

Computers and Technology
1 answer:
Ainat [17]3 years ago
7 0

Answer:

Here is the program:

current_time = '2014-07-26 02:12:18:'  

my_city = ''

my_state = ''

log_entry = ''

 

my_city = input("")   #reads in value for my_city

my_state = input("")  #reads in value for my_state

log_entry = current_time + ' ' + my_city + ' ' + my_state   #concatenates current_time, my_city and my_state values with ' ' empty space between them

 

print(log_entry)

Explanation:

You can also replace

log_entry = current_time + ' ' + my_city + ' ' + my_state  

with

log_entry = f'{current_time} {my_city} {my_state}'

it uses f-strings to format the strings

If you want to hard code the values for my_city and my_state then you can replace the above

my_city = input("")

my_state = input("")

with

my_city = "Houston"

my_state = "Texas"

but if you want to read these values at the console from user then use the input() method.

The screenshot of the program along with the output is attached.

You might be interested in
The Rainbow Trout Company maintains a database of clients. To search through this database, they use ____, a 4GL.
mario62 [17]

In the case above, To search through this database, they use SQL, a 4GL.

<h3>What is SQL?</h3>

SQL is known to be Structured Query Language (SQL) that is said to be a form of standardized programming language that is employed to manage relational databases and carry out various operations on the data in them.

Note that In the case above, To search through this database, they use SQL, a 4GL network that can help.

Learn more about SQL from

brainly.com/question/25694408

#SPJ1

7 0
2 years ago
My HTC Desire 510's mobile data stopped working, how to I make it work again?
denis-greek [22]
Ask your mobile operator
2.go to hrs service
3. Turn on and turn off
4 0
3 years ago
Imagine cashing or taking money using the Automated Teller Machine (ATM) and the banking hall, which of these two ways would you
Brut [27]

Imagine cashing or taking money using the Automated Teller Machine (ATM) and the banking hall, the two ways are When it involves convenience, not anything can beat ATMs.

<h3>What are the benefits and drawbacks of the usage of an ATM card?</h3>

No credit score allowed: A debit card is related for your financial institution account. There isn't anyt any opportunity of creating any transaction on credit score. All transactions and withdrawals are restricted to the stability to be had for your account. Difficult to dispute fraudulent use: It is less difficult to fraudulently use your debit card.

Automated Teller Machine (ATM) – It is a digital system that is operated with the aid of using clients and lets in acting for monetary transactions consisting of switch funds, coins withdrawals, and deposits. It extensively utilized for acquiring account facts at any time and with out the assist of financial institution staff.

Read more about the Automated Teller Machine:

brainly.com/question/19185661

#SPJ1

3 0
2 years ago
Could someone help! I need to write a Python program based on Graphical User Interface.
Kamila [148]

Answer:

ik its not an answer but it kinda is.. uh GOOGLE

Explanation:

6 0
3 years ago
Read 2 more answers
You can reduce the size or minimize the Ribbon. *
Vinvika [58]

Answer:

minimize

Explanation:

5 0
3 years ago
Other questions:
  • Using the flowchart below, what value when entered for Y will generate a mathematical error and prevent our flowchart from being
    14·1 answer
  • Which of the following is a collection of honeypots used to present an attacker aneven more realistic attack environment?a. Padd
    6·1 answer
  • What are the advantages and disadvantages of the simulated link strategy?
    11·1 answer
  • Write code statements to create a DecimalFormat object that will round a formatted value to four decimal places. Then write a st
    15·1 answer
  • TCP will guarantee that your packets will arrive at the destination, as long as the connection is still established. True False
    11·1 answer
  • Which note-taking method quickly captures and organizes information?
    9·2 answers
  • Which best describes color blindness?
    8·1 answer
  • witch option in a presentation program contains the formatting and placeholders for all the items that appear on a slide?
    11·2 answers
  • You have the templates of 2 classes, Person and Program. The Person class has 4 attributes, name, age, major and gpa. There is a
    7·1 answer
  • Compare and contrast two fundamental security design principles in network security. Analyze how these principles and how they i
    15·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!