Analyze the following code.

```
#include
using namespace std;

int main()
{
char *p;
cout << "Enter a string: ";
cin >> p;

cout << p << endl;

return 0;
}
```

a. If you run the program and enter abc, unpredictable characters will be displayed.
b. If you run the program and enter abc, abc will be displayed.
c. If you run the program and enter abc, nothing will be displayed. The program runs without errors.
d. If you run the program and enter abc, a runtime error will occur, because p is used without being initialized.


d. If you run the program and enter abc, a runtime error will occur, because p is used without being initialized.

Computer Science & Information Technology

You might also like to view...

____________________ are graphic or text elements on a web page that users click to display another location on the page, another web page on the same website, or a web page on a different site.

Fill in the blank(s) with the appropriate word(s).

Computer Science & Information Technology

What does the following command accomplish? nc –v –z –w 1 10.10.23.4 1-1024

a. Starts a listener on the hacker's machine b. Port scans the following IP address 10.10.23.4 c. Blocks traffic to the following IP address 10.10.23.4 d. Allows all traffic to the following IP address 10.10.23.4

Computer Science & Information Technology

Suppose a web client and web server for a popular shopping web site have performed a key exchange so that they are now sharing a secret session key. Describe a secure method for the web client to then navigate around various pages of the shopping site, optionally placing things into a shopping cart. Your solution is allowed to use one-way hash functions and pseudo-random number generators, but it

cannot use HTTPS, so it does not need to achieve confidentiality. In any case, your solution should be resistant to HTTP session hijacking even from someone who can sniff all the packets. What will be an ideal response?

Computer Science & Information Technology

What command should you use on a Linux computer to access a Windows share named mydocs from a server name WinServ?

A. open //WinServ/mydocs B. smbclient //WinServ/mydocs C. ftp WinServ:mydocs D. use WinServ\mydocs

Computer Science & Information Technology