Answer:
Following are the solution to this question:
Please find the attachment of this code.
Explanation:
In this code, an email_list method is declared, that accepts a domains parameter, and in the next step, an empty list and two for loop are defined, in which the first for loop is used for a count parameter value and in the second loop is use the append method to add the given value, and use the return method to print its value, and use the print method to call the "email_list" method.
Answer:
The switch sends broadcast traffic to all ports like a hub to get the number of ports used and build its MAC address table.
Explanation:
A network switch is a device used in a LAN to connect all available workstations. Unlike a network hub, it is able to send frames from a host or workstation to another using its MAC address table.
An example of a switch is the Cisco 2950 switch. When it is first turned on, it acts as a hub, broadcasting traffic to all its ports. This process is used to create a MAC address table to get the IP address of workstations and the ports they relate to, enabling it to send unicast traffic to a specific port.
Answer:
The answer to this question is given below in the explanation section.
Explanation:
This program is written in C++.
#include <iostream>
using namespace std;
int main()
{
string word;// variable for taking user input
int cond;// to set condition true if user preses the stop and exit from loop
cout<<"Enter word: \n";
cin>>word;
do// start while loop
{
if(word=="stop" || word =="STOP" || word == "Stop")// if user enter word stop, then program exit
{
cond=0;
}
else//otherwise loop continue
{
cout<<" You Entered "+ word +"\n";
cout<<"Enter word: \n";
cin>>word;
cond=1;
}
}
while(cond == 1);// if user don't enter word "stop" loop run continuesly.
cout<<"Program exit";
return 0;
}