Question 1
Which of the following is NOT a numeric data type in most programming languages?
1
Integer
2
Float
3
Boolean
4
Double
Question 2
What happens if you assign a floating-point number to an integer variable in most programming languages?
1
The number is rounded
2
The decimal part is truncated
3
Compilation error
4
It is automatically stored as a float
Question 3
The average of 10 numbers is 20. If one number is excluded, the average of the remaining numbers becomes 18. What is the excluded number?
1
38
2
200
3
25
4
42
Question 4
The average of four numbers is 40. If one number is replaced by 10, the new average becomes 36. What is the number that was replaced?
1
38
2
20
3
24
4
26
Question 5
In a class, the average age of 20 students is 18 years. The teacher’s age is added to the group, and the new average becomes 19 years. What is the age of the teacher?
1
38
2
30
3
25
4
39
Question 6
The average of 10 numbers is 35. If the first 9 numbers have an average of 30, what is the 10th number?
1
70
2
50
3
44
4
80
Question 7
The average of 10 numbers is 100. If one number is excluded, the average of the remaining numbers is 98. What is the excluded number?
1
100
2
118
3
120
4
110
Question 8
The average salary of employees in a company is 50,000. If there are 30 employees and the salary of the highest-paid employee is 100,000, what is the average salary of the remaining 29 employees?
1
49000
2
51000
3
48000
4
50000
Question 9
What is the default numeric data type for decimal values in Java?
1
double
2
float
3
long
4
int
Question 10
In Python, which data type is used for large integers beyond the typical integer range?
1
int
2
bigInt
3
long
4
float
Question 11
In C++, which of the following types can store the largest range of numeric values?
1
int
2
long double
3
long
4
double