The following program segment is supposed to print the first n integers, but it doesn't work. Correct the statements so that they achieve the intended purpose.

```
i = 0;
while (i < n)
cout << x << endl;
i++;
```


```
i = 0;
while (i < n)
{
cout << i << endl;
i++;
}
```

Computer Science & Information Technology

You might also like to view...

The GridView control provides all the following features except __________.

a. it’s designed to display only one row at a time b. you can sort on any column c. you can select the order in which columns appear d. you can format data within the columns

Computer Science & Information Technology

After you click the Font arrow in the Property inspector, you can type the first letter of a font name to scroll the list to that name.

Answer the following statement true (T) or false (F)

Computer Science & Information Technology

IMAP users can't work with email while offline.

Answer the following statement true (T) or false (F)

Computer Science & Information Technology

The printer spool files will have extensions of ____.

A. .ips and .ipl B. .spl and .ips C. .spl and .shd D. .spl and .splx

Computer Science & Information Technology