Answer:
False
Explanation:
Diversification involves increasing the reach of a particular software to meet the needs of different people. When a particular software is developed to provide multiple services for different individuals, it can be categorized as diversification but when the software is improved upon to meet the same users within a specific domain, the software can not be said to be diverse.
From our scenario, the operating system software is improved upon to handle the continuous changes in computer, this does not make the operating system software diverse, it just becomes better.
Your best bet is to research about it online or watch tutorials on YouTube for a better understanding :) <span />
Answer:
You can simplify the problem down by recognizing that you just need to keep track of the integers you've seen in array that your given. You also need to account for edge cases for when the array is empty or the value you get would be greater than your max allowed value. Finally, you need to ensure O(n) complexity, you can't keep looping for every value you come across. This is where the boolean array comes in handy. See below -
public static int solution(int[] A)
{
int min = 1;
int max = 100000;
boolean[] vals = new boolean[max+1];
if(A.length == 0)
return min;
//mark the vals array with the integers we have seen in the A[]
for(int i = 0; i < A.length; i++)
{
if(A[i] < max + 1)
vals[A[i]] = true;
}
//start at our min val and loop until we come across a value we have not seen in A[]
for (int i = 1; i < max; i++)
{
if(vals[i] && min == i)
min++;
else if(!vals[i])
break;
}
if(min > max)
return max;
return min;
}
Yes it allows you to screen record hope this helps
Answer:
#include <iostream>
using namespace std;
int main(){
int arr1[5], arr2[5], k = 7;
arr1 = {1,3,5,3,6}
arr2 = {1,3,2,4,4}
int reverseA2[5];
for (int x = 5; x > 0; x++){
reverseA2[5-x] = arr2[x-1];
}
for (int i = 0; i < 5; i++){
if ( arr1[i] + reverseA2[i] < k){
cout<< arr1[i] << " , "<<reverseA2[i];
}
}
}
Explanation:
The C++ source code prints a pair of values from the arr1 and reverse arr2 arrays whose sum is less than the value of the integer variable value k.