How to write functions that handle in-line constraints

In reply to VijayaKrishnaKasula:

This is not really clear enough. Can you give a few examples of the data you expect to produce? And how do you plan on calling randomize()?