Quiz on Type Conversions
Let’s see how well you understand type conversions in D.
We'll cover the following...
We'll cover the following...
Technical Quiz
1.
Consider the following program:
import std.stdio;
void main() {
double sum = 2.5;
int increment = 2;
sum += increment;
write(sum);
}
The output of the above program will be?
A.
Error: Incompatible types
B.
2.5
C.
4.5
D.
None of the above
1 / 5