Sunfox Test - Set - 2
Sunfox Test - Set - 2
#include<stdio.h>
int main()
{
int i;
#if A
printf("Enter any number:");
scanf("%d", &i);
#elif B
printf("The number is odd");
return 0;
}
A. Error: unexpected end of file because there is no matching #endif
B. The number is odd
C. Garbage values
D. None of above
#include<stdio.h>
int main()
{
float arr[] = {12.4, 2.3, 4.5, 6.7};
printf("%d\n", sizeof(arr)/sizeof(arr[0]));
return 0;
}
A. 5
B. 4
C. 6
D. 7
A. Yes
B. No
4. What will be the output of the program (Turbo C in 16 bit platform DOS) ?
#include<stdio.h>
#include<string.h>
int main()
{
char *str1 = "India";
char *str2 = "BIX";
char *str3;
str3 = strcat(str1, str2);
printf("%s %s\n", str3, str1);
return 0;
}
A. IndiaBIX India
B. IndiaBIX IndiaBIX
C. India India
D. Error
#include<stdio.h>
int main()
{
union a
{
int i;
char ch[2];
};
union a u1 = {512};
union a u2 = {0, 2};
return 0;
}
1: u2 CANNOT be initialized as shown.
2: u1 can be initialized as shown.
3: To initialize char ch[] of u2 '.' operator should be used.
4: The code causes an error 'Declaration syntax error'
A. 1, 2
B. 2, 3
C. 1, 2, 3
D. 1, 3, 4
7. 66 cubic centimetres of silver is drawn into a wire 1 mm in diameter. The length of the wire in
metres will be:
A. 84
B. 90
C. 168
D. 336
8. How many times in a day, are the hands of a clock in straight line but opposite in direction?
A. 20
B. 22
C. 24
D. 48
9. The cost price of a Rs. 100 stock at 4 discount, when brokerage is 1/4 % is:
A. Rs. 95.75
B. Rs. 96
C. Rs. 96.25
D. Rs. 104.25
10. From a group of 7 men and 6 women, five persons are to be selected to form a committee so that
at least 3 men are there on the committee. In how many ways can it be done?
A. 564
B. 645
C. 735
D. 756
E. None of these
11. The true discount on a bill due 9 months hence at 16% per annum is Rs. 189. The amount of the
bill is:
A. Rs. 1386
B. Rs. 1764
C. Rs. 1575
D. Rs. 2268
A. 61
B. 71
C. 73
D. 81
13. A man rows to a place 48 km distant and come back in 14 hours. He finds that he can row 4 km
with the stream in the same time as 3 km against the stream. The rate of the stream is:
A. 1 km/hr
B. 1.5 km/hr
C. 2 km/hr
D. 2.5 km/hr
14. In what ratio must a grocer mix two varieties of pulses costing Rs. 15 and Rs. 20 per kg
respectively so as to get a mixture worth Rs. 16.50 kg?
A. 3:7
B. 5:7
C. 7:3
D. 7:5
15. In a race of 200 m, A can beat B by 31 m and C by 18 m. In a race of 350 m, C will beat B by:
A. 22.75 m
B. 25 m
C. 19.5 m
D. 53/7m
16. If 6th March, 2005 is Monday, what was the day of the week on 6th March, 2004?
A. Sunday
B. Saturday
C. Tuesday
D. Wednesday
17. An accurate clock shows 8 o'clock in the morning. Through how may degrees will the hour hand
rotate when the clock shows 2 o'clock in the afternoon?
A. 144°
B. 150°
C. 168°
D. 180°
18. A clock is started at noon. By 10 minutes past 5, the hour hand has turned through:
A. 145°
B. 150°
C. 155°
D. 160°
19. The market value of a 10.5% stock, in which an income of Rs. 756 is derived by investing Rs. 9000,
brokerage being %, is: 1/4%
A. Rs. 108.25
B. Rs. 112.20
C. Rs. 124.75
D. Rs. 125.25
A. 26
B. 24
C. 21
D. 18
A. 751
B. 853
C. 981
D. 532
A. 31
B. 91
C. 56
D. 15
A. 481
B. 511
C. 391
D. 421
A. 33
B. 121
C. 279
D. 594
25. Mr. Thomas invested an amount of Rs. 13,900 divided in two different schemes A and B at the
simple interest rate of 14% p.a. and 11% p.a. respectively. If the total amount of simple interest
earned in 2 years be Rs. 3508, what was the amount invested in Scheme B?
A. Rs. 6400
B. Rs. 6500
C. Rs. 7200
D. Rs. 7500
E. None of these