MCQOPTIONS
Saved Bookmarks
| 1. |
What is the output of this program?import java.util.*; public class Bitset_Example { public static void main(String args[]) { BitSet object = new BitSet(8); for (int k = 0; k < 6; ++k) object.set(k); object.clear(4); System.out.print(object); } } |
| A. | {0, 1, 3, 5} |
| B. | {0, 1, 2, 5} |
| C. | {0, 1, 2, 3, 5} |
| D. | {0, 1, 2, 3, 4, 5} |
| E. | None of these |
| Answer» D. {0, 1, 2, 3, 4, 5} | |