Select the proper form for the following declaration:
p is a pointer to an array containing 10 int values
Choose the right answer:
What happens if you try to compile and run this program?
#include
#include
int main (int argc, char *argv[]) {
double x = 1234567890.0;
printf ("%f",x);
return 0;
}
Choose the most precise answer:
Assume that ints and floats are 32-bit wide.
What happens if you try to compile and run this program?
#include
union uni {
float f, g;
int i, j;
};
int main (int argc, char *argv[]) {
union uni u;
printf ("%ld", sizeof (u) ) ;
return 0;
}
Choose the right answer:
What happens if you try to compile and run this program?
#include
#include
void fun (void) {
return 3.1415;
}
int main (int argc, char *argv[]) {
int i = fun(3.1415);
printf("%d",i);
return 0;
}
Choose the right answer:
What happens if you try to compile and run this program?
#include
struct s {
int i;
};
void fun(struct S st) {
st.i --;
int main (void) {
int k;
struct $ str1 = { 2 };
fun (str1) ;
k =str1.i;
printf("%d", k);
return 0;
}
-
Choose the correct answer:
What is the meaning of the following declaration?
float ** p;
Choose the right answer:
What happens if you try to compile and run this program?
#include
fun (void) {
static int n = 3;
return --n;
}
int main (int argc, char ** argv) {
printf("%d \n", fun() + fun());
return 0;
}
Select the correct answer:
What happens if you try to compile and run this program?
#include
int main(int argc, char *argv[]) {
int i = 10 - 2 / 5 * 10 / 2 - 1;
printf("%d",i);
return 0;
}
Choose the right answer:
What happens if you try to compile and run this program?
#include
int main (int argc, char *argv[]) {
char i = 20 + 020 + 0x20;
printf("%d",i);
return 0;
}
Choose the right answer: