Answer:
The program to this question can be given as:
Program:
#include <stdio.h> //include header files
#include<math.h>
int main() //main method
{
double treeHeight = 0.0; //declare variables
and assign value
double shadowLength = 0.0;
double angleElevation = 0.11693706;
// (0.11693706 radians = 6.7 degrees) convert number into angle.
shadowLength = 17.5;
treeHeight = shadowLength * tan(angleElevation); //convert number into angle
printf("Tree height: %lf\n", treeHeight); //print value.
return 0;
}
Output:
Tree height: 2.055778
Explanation:
In the above C language program firstly we include the headers. In this header file, we include a (math.h) header file this file helps to use the math function. Then we declare the main method in the main method we declare the variable that is given in the question that are treeHeight, shadowLength , angleElevation. All the variable datatype is double because it stores the floating-point value. Then we apply the formula that is treeHeight = shadowLength * tan(angleElevation). In this formula, the treeHeight variable holds the value. Then we print the variable value for print the double value we use the lf(that is long float).
Answer:
Option D. float is the correct answer.
Explanation:
Decimal number contains decimal point. Out of all the given data types, float data type store the number with decimal point.
As the number has to be further used for calculations float ahs to be used. Because the numbers can also be stored in string but cannot be used for further calculations.
Hence,
Option D. float is the correct answer.
Answer:
find()
Explanation:
When dealing with MongoDB the method that needs to be used in this scenario would be the find() method. This method basically returns all of the records that exist in the collection on which it is called, if no parameter is passed. If you pass a parameter/expression then only the records that match completely the expression will be returned to the user, otherwise nothing is returned. For example, on a database (db) we would call the following
db.find() ... This will return all records
db.find({specific}) ... This will return only the records that match specific.
Answer:
five types of pointing devices
Explanation:
Ponting devices
Pointing means point something and the pointing devices are the input /peripheral devices those are used to point the pointer on the screen. We do move cursor on the screen to open the files or any icon.
There are many types of pointing devices but these are quite common which are given below
- Computer mouse
- Finger on touch screen.
- Joystick.
- Leap Motion.
- Light pen (pen)
1.Mouse
Mouse is most common type of input device that is used for pointing the data on the screen. We press it with our hands and keep pointing the things.
There are three types of mouse
- optical mouse
- wireless mouse
- trackball mouse.
2. Finger on touch screen
In this type of movement the fingers are input devices those we use to see the movement of pointer on the screen and this is most common in this century.
3.Joystick.
Joystick is another input device to point the cursor but it is mostly used in games. Children can use it smartly so it is inculcated in games usually.
4. Leap Motion
The Leap Motion (LM) controller is a latest 3D sensing device for hand posture interaction with a computer. It is having the capability sense the location of the fingers of the hands, as well as the palm position.
5.Light Pen
this is another pointing device which is mostly used to highlight and select the data on the screen.
Note: All of these above pointing devices are most common used now a days. These devices are having new conventions day by day for the ease of user. This era is basically the era of IT ,so the use of computer must be so easy and conventional for the user so, the innovations and improvement in such devices is made side by side.
Answer: integer overflow
Explanation:
The type of attack has occurred in this scenario is a integer overflow. An integer overflow occurs when there's an attempt by an arithmetic operation to create a numeric value which is outside the range which the given numbers are able to represent.
In this, the integer overflow occurs when the result of the integer operation cannot be able to fit in the allocated memory space which then brings about an unexpected result.