[edit - 17 is E ]
1. E
2. C
3. C
4. D
5. C
6. E
7. D
8. C
9. B
10. A
11. B
12. D -> only one has to be false for && to fail
13. D
14. B
15. A
16. E
17. D
18. D
19. D
20. D
21. B
22. D
23. A
24. ? -> none of them
A gives "1,2,3,4,"
B gives "1,2,3,4,5,"
C gives "0,1,2,3,4,5"
D gives "0,1,2,3,4,5,5"
E gives "1, 2, 3, 4, 5"
very strange.
25. B
26. C
27. A
B - seeds is private, main cant access it.
C - color is a string, not a function
D - seeds is private
E - the constructor only takes 1 argument
28. E
29. B
i just did a truth table and got
(p && (! (q || (! (p && r))))) is true only if p = 1, q = 0, r = 1
which i think is what B says.
30. E
the code
cout << doIt(str, a);
need doIt to return a string
only C and E return a string, and C returns fx which is the integer argument.