counter = 1
sum = 0
while counter <= 6:
sum = sum + counter
counter = counter + 2
print(sum)
A. 12
B. 9
C. 7
D. 8
✔️ Correct! This loop executes 3 times. After the first loop sum = 1 and counter = 3, after the second loop sum = 4 and counter = 5, and after the third loop sum = 9 and counter = 7.
The mother board it holds all of the storage
Answer:
C code
Explanation:
#include <stdio.h>
void histrogram(int counters[])
{
int i,j;
int count;
for(i=0;i<26;i++)
{
count=counters[i];
printf("%c ",i+97);
for(j=0;j<count;j++)
{
printf("="); //= is used
}
printf("\n");
}
}
int main()
{
FILE* fp;
int i;
int arr[26];
char c;
int val;
// Open the file
fp = fopen("story.txt", "r");
if (fp == NULL) {
printf("Could not open file ");
return 0;
}
else
{
for(i=0;i<26;i++)
arr[i]=0;
for (c = getc(fp); c != EOF; c = getc(fp))
{
if(c>='a' && c<='z')
{
val = c-97;
//printf("%d ",val);
arr[val]++;
}
}
histrogram(arr);
}
}
Answer:
DiffServ (Differentiated Service)
Explanation:
DiffServ (Differentiated Service) field is used to prioritize traffic in IPv4 packet.
DiffServ is used as QoS (quality of service) on networks at Layer 3, replacing former IPv4 TOS field to effectively deal with the web traffic and prioritization issues starting from 1998.