Answer:
- #include <stdio.h>
- int main()
- {
- const double piVal = 3.14159;
- double sphereVolume = 0.0;
- double sphereRadius = 0.0;
-
- sphereRadius = 1.0;
- sphereVolume = 4.0/ 3.0 * piVal * sphereRadius * sphereRadius * sphereRadius;
-
-
- printf("Sphere volume: %lf\n", sphereVolume);
- return 0;
- }
Explanation:
Firstly we can identify the formula to calculate volume of sphere which is
Volume = 4/3
With this formula in mind, we can apply this formula to calculate the volume of sphere in Line 10. This is important to perform floating-point division 4.0/3.0 to ensure the resulting value is a floating value as well. Since we have been given piVal and sphereRadius, we can just multiply the result of floating-point division with piVal and sphereRadius and get the sphereVolume value.
At last, display the sphere volume using printf method (Line 13).
Answer:
TCP/IP
Explanation:
TCP/IP which stands for Transmission Control Protocol and Internet Protocol are network protocols which divide your message into smaller chunks or fragments known as network packets and sends them out onto the Internet. When the chunks arrive at the intended destination, TCP/IP on the receiving end reassembles the network packets into the original message.
TCP/IP are the main protocols used for sending data over the internet.
Answer: see description
Explanation:
first we accommodate the bit pattern in a matrix of 4x4 which is the minimum length checksum field, now with even parity two-dimensional scheme we need to complete this matrix by adding one row and one column by adding at the end of each row a 1 or a 0 to complete pairs of 1's:
we have
![\left[\begin{array}{cccc}1&1&1&0\\0&1&1&0\\1&0&0&1\\1&1&0&1\end{array}\right]](https://tex.z-dn.net/?f=%5Cleft%5B%5Cbegin%7Barray%7D%7Bcccc%7D1%261%261%260%5C%5C0%261%261%260%5C%5C1%260%260%261%5C%5C1%261%260%261%5Cend%7Barray%7D%5Cright%5D)
so we complete with this, adding a row at the end which matches a pair number of 1's
![\left[\begin{array}{ccccc}1&1&1&0&1\\0&1&1&0&0\\1&0&0&1&0\\1&1&0&1&1\\1&1&0&0&0\end{array}\right]](https://tex.z-dn.net/?f=%5Cleft%5B%5Cbegin%7Barray%7D%7Bccccc%7D1%261%261%260%261%5C%5C0%261%261%260%260%5C%5C1%260%260%261%260%5C%5C1%261%260%261%261%5C%5C1%261%260%260%260%5Cend%7Barray%7D%5Cright%5D)
Answer:
12/22
Explanation:
As there are 22 apples in total and 12 green it is 12/22.