Question: Write a program to generate 100,000 random values and compute the squares of these values. Do the math using each of the following data types:

Write a program to generate 100,000 random values and compute the squares of these values. Do the math using each of the following data types: short, int, unsigned, long, sc_int<8>, sc_uint<19>, sc_bigint<8>, sc_bigint<100>, sc_fixed<12,12>. Be certain to generate numbers distributed over the entire range of possibilities. Compare the run times of each data type.

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Systems Analysis And Design Questions!