| Question 1 UGC NET June-2020 Find the lexicographic ordering of the bit strings given below based on the ordering 0 < 1. A) 001 B) 010 C) 011 D) 0001 E) 0101 Choose the correct answer from the options given below: |
| A – 001<010<011<0001<0101 |
| B – 0001<001<010<0101<011 |
| C – 0001<0101<001<010<011 |
| D – 001<010<0001<0101<011 |
Show Answer With Best Explanation
Answer: b
Explanation:
Lexicographically means sorting in natural order, dictionary order.
The lexicographic order of the given bit strings will be:
0001<001<010<0101<011
Take 0001 & 001 for comparing. Compare each bit of 1st string with the corresponding bit of 2nd string.
It is clear that 0001< 001.
