Answer:
A) Parentheses
Explanation:
Conditional statements control behavior in JavaScript and determine whether or not pieces of code can run.
There are multiple different types of conditionals in JavaScript including:
If” statements: where if a condition is true it is used to specify execution for a block of code.
“Else” statements: where if the same condition is false it specifies the execution for a block of code.
“Else if” statements: this specifies a new test if the first condition is false.
Now that you have the basic JavaScript conditional statement definitions, let’s show you examples of each.
If Statement Example
As the most common type of conditional, the if statement only runs if the condition enclosed in parentheses () is truthy.
EXAMPLE
if (10 > 5) {
var outcome = "if block";
}
outcome;
OUTPUT
"if block"
Here’s what’s happening in the example above:
The keyword if tells JavaScript to start the conditional statement.
(10 > 5) is the condition to test, which in this case is true — 10 is greater than 5.
The part contained inside curly braces {} is the block of code to run.
Because the condition passes, the variable outcome is assigned the value "if block".
Answer:
for ( initialization; condition;increment)
{
code goes here;
}
in python:
for i in list/range:
code with proper indentation
By initialization above we mean, like int i=0; etc.
By condition like i<10;
and by increment it means like i++, ++i or i+=1; etc
And in python, i can be an integer value if the range is mentioned, and it can be an item of a list if the list is used. We can also use an array, string and various other data structures in python. like we can have characters in a string and so on.
Explanation:
Please check the answer section.
Answer:
save as a word document (.docx) to keep editing offline then copy and paste into the google doc
Answer:
From the two IP addresses, 192.168.2.1 can be listed as the default gateway in local network devices.
The reason is that we are allocated with the ranges that are reserved for the local networks by RFC 1918.
These ranges are given as follows:
10.0.0.0 - 10.255.255.255
172.16.0.0 - 172.31.255.255
192.168.0.0 - 192.168.255.255
Moreover the default gateway for a device can also be known by the commands ipconfig or ipconfig/all on the command prompt.
<h3>I hope it will help you!</h3>