# Software recommendation: Windows environment to quickly generate random numbers

There are many occasions when you need to use random numbers in your daily work. When doing experiments, you may need some random numbers for testing; many product vendors need to assign random serial numbers to their products, or assign random card numbers to VIP user cards. So, how can we automatically generate random numbers to meet the needs in Windows environment?

1. Generation of ordinary random numbers in specific intervals

If you need to generate a random number in a specific interval when conducting an experiment, you can first create it by using the Excel software we are familiar with. The main use of RAND and RANDBETWEEN two functions to achieve.

For example, the need to generate random numbers within the interval of 0 to 1, you can use the function “= RAND ()” to achieve; to generate random numbers between 0 and 10, you can use the function expression “= RAND () * 10”; if you need between 1 and 10 If you need a random number between 1 and 10, use the expression “RAND()*(10-1)+1”. Similarly, for random numbers between 0 and 100, use the expression “RAND()*100”; for random numbers between 1 and 100, use the expression “RAND()*(100-1)+2” (Figure 1). We notice that the above random numbers are all decimals. So, what if we want to generate integers? There are two ways, one is to round the generated fractional random numbers, and the other is to generate integer random numbers directly. The first one, for example, adds TRUNC() function to the expression “RAND()*(100-1)+2” to generate a random integer between 1 and 100, and the whole expression is “=TRUNC(RAND()*(100-1)+2) “; the second can directly use the RANDBETWEEN() function, with the expression “=RANDBETWEEN(0,10)” to generate a random integer between 0 and 10, the expression “=RANDBETWEEN (50,9999)” generates a random integer between 50 and 9999 (Figure 2). As you can see, the RANDBETWEEN() function is more visual and simpler to use. If you find it troublesome to generate interval random numbers in the above way, you can use third-party tools and software to achieve it. For example, using Random Number Generator, you can easily set and condition the random number area, so as to automatically generate random numbers that satisfy the conditions.

Once the software is running, enter the range of random numbers to be generated in the two boxes on the left after Interval from, the number of decimal places to be intercepted after Digits after decimal point, and the number of random numbers to be generated each time after Number of digits to generate. After that, click the Generate integer button to generate the specified number of random integers, and click Generate decimal to generate the corresponding random decimals (Figure 3). After the generation conditions of random numbers are set, the operation of creating random numbers can also be done with shortcut keys. Press the function key F1 to create a specified range of integers, press F2 to generate a specified range of decimals, and press F4 to clear the list of random numbers. If you want to generate a large number of random numbers and want to find whether a specific random number exists from it, you can use the Find button to find it and locate it automatically when you find it (Figure 4). If you want to stop the random number generation in the middle of the process, you can press Esc. Tip: If you want to generate a random number that does not repeat, please select the Next random number does not equal current checkbox. If you want to copy a certain random number generated or a list of random numbers, just use a few buttons in the lower left corner of the software window to operate.

2. Generation of product serial numbers in specific formats

As a product manufacturer’s staff, to arrange serial numbers for their own hardware and software products, or sellers to configure serial numbers for customer VIP cards, you can also use two methods to achieve.

First, you can use Excel’s random function expressions. Suppose you want to generate such as “123-456” by two three-digit number and a hyphen to form a random number of serial numbers, you can use “= RANDBETWEEN (100,999) & ” – ” &RANDBETWEEN (100,999) ” function expression. The “&” symbol connects the result before and after, while “-” indicates that the two random numbers before and after are connected by the specified hyphen.

By analogy, if you want to generate a random sequence number consisting of four segments of six digits, you can use “=RANDBETWEEN(100000,999999)& ” – ” &RANDBETWEEN(100000,9999999)& ” – ” && ” – ” &RANDBETWEEN(100000, 999999)& ” – ” &RANDBETWEEN(100000,9999999)& ” – ” &RANDBETWEEN(100000,9999999)& ” – ” &RANDBETWEEN(100000,9999999)” function expressions (Figure 5). Serial numbers can also be generated using a third-party dedicated tool, such as Portable Abluescarab Software CD-Key Generator software. The first time you use this software, a pop-up prompt appears and you need to configure the parameters, which are mainly the number of segments of the serial number and the number of characters per segment (Figure 6). After entering the main window of the serial number generator, first select one of the 3 ways to use numbers, characters, and numbers + characters through the drop-down list, and then select whether to use lowercase letters through the checkbox below, and then click the Generate button to create a set of serial numbers (Figure 7). Tip: Although the software is designed for CD-Key, generating serial numbers for other products is also applicable.