DescriptionQ647
Q647DVASIC interview problem
Constrain unique increasing addresses
TechniquesRandomizationforeachOrdering
DifficultyEasy
TopicConstraints
LanguageSystemVerilog
Requirements3 checkpoints
01
Problem
Randomize eight addresses from 0 through 1023 in strictly increasing order.
Example input and output
Use this case to check your interpretationInput
randomize exactly eight addresses in inclusive range 0..1023Output
One valid result: [4, 19, 103, 255, 511, 700, 900, 1023]Explanation
All eight addresses are in range and each is strictly greater than its predecessor; many other increasing sequences are valid.
02
Requirements (3)
- Every address must stay inside the legal range.
- Each address after the first must exceed its predecessor.
- Do not add a redundant uniqueness constraint.
