This is a sample of how you can access a random value from a data table, customize it to your use. It is relatively easier in cpp, same steps a followed. You firstly have to generate a random number from 0 to max index range. Then, you can access data table as an array and retrive the value at that index.