Answer:
See explaination
Explanation:
Keep two iterators, i (for nuts array) and j (for bolts array).
while(i < n and j < n) {
if nuts[i] == bolts[j] {
We have a case where sizes match, output/return
}
else if nuts[i] < bolts[j] {
this means that size of nut is smaller than that of bolt and we should go to the next bigger nut, i.e., i+=1
}
else {
this means that size of bolt is smaller than that of nut and we should go to the next bigger bolt, i.e., j+=1
}
}
Since we go to each index in both the array only once, the algorithm take O(n) time.
The numbers of items that the user can include in the rule is the top or bottom 100 items only.
<h3>What is Top/Bottom Rules?</h3>
Top/Bottom Rules is known to be a rule where there is a premade form of conditional formatting which is often used in Excel to alter the set up of cells in a range.
Note that the Top/Bottom Rules will allow a user to make changes to the top or bottom 100 items only as it only pertains to things that are up and those that are at the bottom.
Learn more about Top/Bottom Rules from
brainly.com/question/1862654
Is there a question or something
Answer:
I agree in this song because being a farmer is not easy you need to be hardwork
<span>public static int methodName(int a, int b){
a = a * 2;
b = b * 2;
}
</span><span>int result = doubling(5, 10<span>);
System.out.println(result);
//result would be 10, 20</span></span>