Answer:
A and B have different output:
A output will be 1
B output will be 123
Explanation:
A
X = 0
do x < 3
x = x+1
print x
while
B
X = 0
do x = x+ 1
print x
while x < 3
For statement A the condition statement which suppose to be after "while" is not set therefore the value of x will be printed.
For statement B the condition statement is set "x < 3" in front of "while" thereby result in iteration until the condition is false.
Statement A output will be 1
Statement B output will be 123
Answer:
d. involves analyzing end-user business requirements in order to refine project goals
Explanation:
In the software development life cycle, the implementation stage is the stage where the computer programmers begin the actual coding of the application required by the end-user. At this stage, the developer takes into account the needs and specifications of the customer.
For example, if the end-user wants a software application that can track payment records, the researcher at this stage begins using the right software to code programs that can effect this function.
Answer: b) R1 will connect to a physical Ethernet link, with the other end of the cable connected to a device at the WAN service provider point of presence.
.d) R1 will forward data link frames to R2 using an Ethernet header/trailer.
Explanation:
Here we have to understand what is MLPS. MLPS is a protocol which identifies the shortest route for the transfer of messages between routers instead of the longest route.
Here we are given a WAN which is a wide area network. Using layer 2 Ethernet service the frames are transmitted across the routers within the WAN.
Option A is incorrect as as connecting the other end of the cable to the R2 would reduce the functionality of the WAN. Option C is incorrect as HDLC header trailer has no effect.
Option B and D are correct as Ethernet header/ trailer has the same size every frame and to maintain the functionality of the WAN one end must be connected to point of presence(PoP).
Answer:
Java code is given below
Explanation:
import java.util.Random;
class Die{
private int sides;
public Die(){
sides = 6;
}
public Die(int s){
sides = s;
}
public int Roll(){
Random r = new Random();
return r.nextInt(6)+1;
}
}
class DieRoll{
public static void main(String[] args) {
Die die = new Die();
int arr[] = new int[6];
for(int i=0; i<6; i++)
arr[i] = 0;
for(int i=0; i<100; i++){
int r = die.Roll();
arr[r-1]++;
}
for(int i=0; i<6; i++)
System.out.println((i+1)+" was rolled "+arr[i]+" times.");
}
}
Answer: the term is known as Align Justified
Explanation:
In typesetting and page layout, alignment or range is the setting of text flow or image placement relative to a page, column, table cell, or tab. The type alignment setting is sometimes referred to as text alignment, text justification, or type justification.