Answer:
The program in Python is as follows:
num1 = int(input())
num2 = int(input())
if num1 >=0 and num2 >= 0:
print(num1+num2)
elif num1 <0 and num2 < 0:
print(num1*num2)
else:
if num1>=0:
print(num1**2)
else:
print(num2**2)
Explanation:
This gets input for both numbers
num1 = int(input())
num2 = int(input())
If both are positive, the sum is calculated and printed
<em>if num1 >=0 and num2 >= 0:</em>
<em> print(num1+num2)</em>
If both are negative, the products is calculated and printed
<em>elif num1 <0 and num2 < 0:</em>
<em> print(num1*num2)</em>
If only one of them is positive
else:
Calculate and print the square of num1 if positive
<em> if num1>=0:</em>
<em> print(num1**2)</em>
Calculate and print the square of num2 if positive
<em> else:</em>
<em> print(num2**2)</em>
Answer: C) copy the merged array back to the original array
Explanation:
After performing merging of two array then, copy the merge array back to its original array. Merging of two array is done by the process of merge sort. Merging of two array is the similar process of concatenate the two array into the single object.
It basically works on the principle of divide and conquer algorithm. It divide the input value into the two half and then, sorted the accordingly. Then after completion of merging the two array it copy into the original array.
Answer:
The External Data Bus is used to transport binary data and Address bus is used to transport memory addresses.
Explanation:
- External Data Bus is a combination of data bus and external bus. Data bus is used to carry data and instructions between two or more components in the system e.g. CPU and all other computer components.
- External bus is also called expansion bus. It is used to connect external components to the computer. Its a communication medium between CPU and other components. These components can be peripheral device like USB or flash memory.
- So External Data Bus is used to transport data between CPU and external components. It is a primary communication pathway for data in a computer. The external data components are connected to this bus and the instruction or data on this bus is available to all external components. But the data communication is slower as compared to that of internal bus.
- Address Bus carries physical location or address of data and transports memory addresses. Processor uses address bus when it wants to read data from memory or write data to the memory by sending a read/write signal by placing the read/write address of the specific memory location on the address bus.
1 Select the file to be deleted
2 select delete from the file menu
3 click on the recyclebin
4 click on the delete icon