Question: Python Question If I have a string and want to encode it by using the values in a dict() function, how would I do it?
Python Question
If I have a string and want to encode it by using the values in a dict() function, how would I do it? The encoded message should be a string.
message= "Hello"
dict( H = "110", e = "145", l = "154", o = "157")
###something something code###
return encoded_message
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
