<u>Answer:</u>
<em>int fNumber,scndNumber = -1, </em>
<em>dup = 0;
</em>
<em>do {
</em>
<em>cin >> fNumber;
</em>
<em>if ( scndNumber == -1) {
</em>
<em>scndNumber = fNumber;
</em>
<em>}
</em>
<em>else {
</em>
<em>if ( scndNumber == fNumber )
</em>
<em>duplicates++;
</em>
<em>else
</em>
<em>scndNumber = fNumber;
</em>
<em>}
</em>
<em>} while(fNumber > 0 ); </em>
<em>cout << dup;
</em>
<u>Explanation:</u>
Here three variables are declared to hold the first number which is used obtain all the inputs given by the user, second number to hold the value of <em>last encountered number and “dup” variable to count the number of duplicate values.</em>
<em>“Do-while”</em> loop help us to get the input check whether it is same as previous input if yes then it <em>adds to the duplicate</em> value otherwise the new previous value if stored.
Answer:
The loop will run 5 times.
Answer:
A
Explanation:
Option A is not true because a Boolean variable type can hold one of two values only that is (true/True or false/False).
All the other options given in the question are correct because
- A variable declaration refers to specifying its type and name
- If string variables are assigned a numeric values which is legal provided the values are enclosed in quaotes( " "), trying to carryout a mathematical operation like addition will result in string concatenation.
- The Variable name I_Love_to_eat_pizza is legal because it contains no special characters, doesn't start with a number and its not a reserved word in any language
Answer: Doxing
Explanation: Doxing which is also referred as doxxing is defined as the revealing or publishing of the private records or information to the public.It is considered as the illegal practice which is base on the the internet service.The publicizing of the private data or confidential information is punishable offence.
Other options are incorrect because filtering is the elimination of the not required content, spamming is the activity of sending undesired bulk messages and hacking is the attacking of the system using false means to corrupt and steal data.Thus the correct option is doxing.
Answer:
It's C
Explanation:
Adware displays or directs the users to an advertisement, while spyware performs espionage on the computer`s activity.