subject

7.3.4: Find the Error In this exercise, you will try to identify which of two lines will cause an error. The two lines look like this:

my_string[0] = "H"
my_string = "H" + my_string[1:]
Each line is an attempt to change the string from "hello!" to "Hello!". One of them does this in an acceptable way, and the other one causes an error.

Before you run the program, see if you can predict which of the two lines is incorrect. Test your guess by commenting out what you think is the incorrect line and running the program!

ansver
Answers: 2

Another question on Computers and Technology

question
Computers and Technology, 21.06.2019 23:00
Give an example of a case where a two-way handshake to establish a connection could leave one side of the connection live while the other side does not believe there is a connection.
Answers: 1
question
Computers and Technology, 23.06.2019 19:30
What are loans to a company or government for a set amount of time
Answers: 1
question
Computers and Technology, 24.06.2019 19:00
Luis is cloud-based( microsoft bot framework). true false
Answers: 1
question
Computers and Technology, 25.06.2019 01:40
The instantiation of an endpoint in a potential tcp connection is know as
Answers: 1
You know the right answer?
7.3.4: Find the Error In this exercise, you will try to identify which of two lines will cause an e...
Questions
question
Mathematics, 02.11.2021 14:00
question
Mathematics, 02.11.2021 14:00
question
Mathematics, 02.11.2021 14:00
question
Mathematics, 02.11.2021 14:00
question
Computers and Technology, 02.11.2021 14:00
Questions on the website: 13722361