Answer:
def filter_strings(data_list):
string_list = []
for s in data_list:
if type(s) == str and len(s) > 5:
string_list.append(s)
return string_list
Explanation:
Create a function called filter_strings that takes data_list as a parameter
Initialize a new list to hold the strings that are longer than 5 characters
Initialize a for loop that iterates through the data_list
Check the elements if they are string - use type function, and if their length is greater than 5 - use len function. If an element satisfies the both conditions, put it to the string_list
When the loop is done, return the string_list
The answer is C because he'll be able to search up the employees name then it will tell him all the information he needs along with their job profile
Answer:
nslookup is the correct answer to the following question.
Explanation:
The following answer is correct because It is the tool or the utility of the command line by which an administrator to query a DNS(Domain Name System) for finding the domain name or the Internet Protocol address or many other records.
<u>Steps to use nslookup:</u>
- Firstly, you have to press the window key + R to open run.
- Then, you have to type cmd in it and press enter.
- Then, cmd will appear after that, you have to type the command 'nslookup' and then press enter.
- Then, it shows the default server name and ip address after that, you have to type an ip address of DNS server.
- Then, you have to type 'set' then type q=M X and then press enter
- Then, you have to type the name of your domain then, press enter key.
Answer:
C. Byte pair encoding is an example of a lossless transformation because an encoded string can be restored to its original version.
Explanation:
Byte pair encoding is a form of encoding in which the most common pairs of consecutive bytes of data are replaced by a single byte which does not occur within the set of data.
For example, if we has a string ZZaaAb, it can be encoded if the pairs of string ZZ are replaced by X and the second pair by Y. So, our data now becomes XYAb.
To get our original data, that is decode it, we just replace the data with the keys X = ZZ and Y = aa thus allowing our original data to be restored.
Since our original string is restored without loss of data, it implies that <u>byte pair encoding is an example of a lossless transformation because an encoded string can be restored to its original version.</u>