Explanation:
The internet is a tool that has revolutionized the way communication is carried out. As it is a dynamic tool with easy access for any user, it is possible to use different platforms or social media to realize disruptive or non-traditional forms of earnings.
Some of them could be the dissemination of links that would generate advertising for other companies, or the free dissemination in social media of services, and several other innovations that use the internet as the main means to manufacture an extra income, such as online teaching, advertising for third parties etc.
In your "count spaces method" before the for loop, you want to declare an int variable (let's call it spc)
then, each time you find that charat, spc++.
also, the string must be declared in the main method, not the spaces count method.
The actual code:
public class CountSpaces{
public static void main(String[] args){
String instring = "(your quote here)";
int spaces = calculateSpaces(instring);
System.out.println("The number of spaces is " + spaces);
}
public static int calculateSpaces(String in){
int spc = 0;
for(int i= 0; i<in.length; i++){
if(in.charAt(i)== ' '){
spc++;
}
}
return spc;
}
}
that should be it. If you have any questions, feel free to reach out.
Answer:
Layer 2 destination address = 00-00-0c-94-36-ab
Layer 2 source address = 00-00-0c-94-36-bb
Layer 3 destination address = 172.16.20.200
Layer 3 source address = 172.16.10.200
Explanation:
To properly understand the given answer, let us define some terms used in the narrative of the question:
Subnet: The sub network or as popularly called subnet is a logical division of the internet protocol of a network into many different and smaller network. It is typically used to create partitions or subdivisions of large networks into bits.
PDU: The PDU can be said to be an abbreviation for the word power distribution unit or protocol data unit. It can also be refereed to as an IT device that possess many output ports or terminals. They are mostly used to distribute or transmit power or data to other operating devices with the telecommunication system.
Now referring back to the question asked and the image attached below, we can see that host a and b send their signal through subnet teachers while host c and d send their signal through subnet students thus,
Layer 2 destination address = 00-00-0c-94-36-ab
Layer 2 source address = 00-00-0c-94-36-bb
Layer 3 destination address = 172.16.20.200
Layer 3 source address = 172.16.10.200 are the correct destination.
In more technical terms, a computer virus is a type of malicious code or program written to alter the way a computer operates and is designed to spread from one computer to another. A virus operates by inserting or attaching itself to a legitimate program or document that supports macros in order to execute its code.