Computers and Technology

Exercise 3.6.9: 24 vs. "24"5 points Using the correct data type is important when math operators are involved.

Strings can also be “added” together. This is called concatenation.

A substring is part of an existing string. When strings are concatenated, each separate substring is combined to create a new string. Let’s check this out!

In this exercise, change the variables in the second code segment to strings and run the code. What do you notice?

# Code Segment One - Data Type - numbers
num_result = 24 + 24
print(num_result)

# Code Segment Two - Data Type - Strings
# Change both numbers to strings and run code
# Change only one number to a string and run code. What happens?
string_result = 24 + 24
print(string_result)
python

answer
Answers: 3

Other questions on the subject: Computers and Technology

image
Computers and Technology, 22.06.2019 08:00, Leggett8152
What best describes a career pathway in a lodging career? a worker starts out as an amusement attendant, then becomes a recreation worker, and then becomes a gaming worker within five years. a worker starts out as a bell hop, then becomes a night clerk, and then becomes a hotel manager within five years. a worker starting out as a tour guide, then becomes a travel clerk, and then becomes a travel agent within five years. a worker starts out as a server, then becomes a food preparer, and then becomes a head chef within five years.
Answers: 1
image
Computers and Technology, 23.06.2019 18:20, Blossom824
What is wi-fi infrastructure? a metropolitan area network that uses radio signals to transmit and receive data a communications technology aimed at providing high-speed wireless data over metropolitan area networks a means by which portable devices can connect wirelessly to a local area network, using access points that send and receive data via radio waves includes the inner workings of a wi-fi service or utility, including the signal transmitters, towers, or poles and additional equipment required to send out a wi-fi signal
Answers: 2
image
Computers and Technology, 24.06.2019 05:30, lexie2751
How do i get rid of my member ship for
Answers: 2
image
Computers and Technology, 24.06.2019 06:30, hannahgracew12
Some peer-to-peer networks have a server and some don't. true false
Answers: 2
Do you know the correct answer?
Exercise 3.6.9: 24 vs. "24"5 points Using the correct data type is important when math operators ar...

Questions in other subjects:

Konu
Advanced Placement (AP), 13.05.2020 20:57
Konu
Mathematics, 13.05.2020 20:57