Answer:
Question was incomplete and continued the question
For each of the following scenarios, which of these choices would be best? Explain your answer.
BST
Sorted Array
Un-sorted Array
a) The records are guaranteed to arrive already sorted from lowest to highest (i.e., whenever a record is inserted, its key value will always be greater than that of the last record inserted). A total of 1000 inserts will be interspersed with 1000 searches.
b) The records arrive with values having a uniform random distribution (so the BST is likely to be well balanced). 1,000,000 insertions are performed, followed by 10 searches.
Explanation:
Answer for a: Un-sorted array or Un-sorted linked list : as mentioned in the question itself that the records are arriving in the sorted order and search will not be O(log n) and insert will be not be O(n).
Answer for b : Un-sorted array or Un-sorted linkedlist : Number of the items to be inserted is already known which is 1,000,000 but it is very high and at the same time search is low. Unsorted array or Unsorted linked list will be best option here.
Explanation:
This is easily solvable with a for loop. Something like:
(I assume c++)
#include <iostream>
#include <string>
int main() {
take_input: //tag
std::string input;
cin >> input; //take the input
int spaceCount = 0;
char checking;
for(unsigned int i = 0; i == input.length(); ++i) {
checking = spaceCount[i];
if(checking == ' ')
spaceCount++;
}
if(spaceCount >= 1 && input.length >= 5)
std::cout << "Your name is " + input;
else
goto take_input; // reasks for input if the conditions are not met
return 0;
};
**remove all spaces before using the code, the if statements are messed up
Answer:
He should disable UPnP technology to disallow devices to dynamically add themselves to the network without configuration.
Explanation:
- UPnP stands for Universal Plug n Play.
- It is an easiest way that allows gadgets to find all other devices connecting to your network.
- This can also modify router settings to allow devices from outside the network to access the router.
- External IP address can also be obtained by the gadget and a new port forwarding map can be set
- So from all perspectives, UPnP is an open invitation for hackers to scan for the ports and hack into the device.
- UPnP is a vulnerability to the secure system
Answer:
huh
Explanation:
sfdghjklhgfdsghjkhgfdsfghjk