Question about Microsoft Excel for PC

1 Answer

Random number generation.

Good day

Im having problems with randome number generation( =rand() ), i need to limit the numerical spaces that is recieved to a number of 5 spaces.
Currently ill run the formula as.{ =rand()*100000 }.

(Note i multiply it with 100000 to ensure that i do not get a , in between the number.)

How do they i limit the Numerical Spaces delivered thru this formula to me. Please help.

I am aiming to use this in printing, to genarate a "lotoery" type of ticket.

Posted by on

  • Jovan Bester Jul 15, 2008

    Thank you for the help, but still it seems to give me a number some times that is less then 5 digits.



    I have now grabed a code of a site that allows me to put limitations on, to select a number range i want random numbers from.



    Like lets say 2000 and 3000, now i need to select 500 random numbers in between these to numbers and also. With this i can, i can also be sure that there is no doubles, and also control the amount of numerical spaces i want it on.

  • Jovan Bester Jul 15, 2008

    Thank you, but It still seems to generate a number sometimes that is less then 5 numerical values.



    Luckily i grabed some VB code of the net that allos me to generate none repeating numbers, with a garunteed 5 numerical value.



    It also gives me the option of limiting where i would like to generate the numbers from and to.



    Thank you again for the help

×

1 Answer

  • Level 2:

    An expert who has achieved level 2 by getting 100 points

    MVP:

    An expert that gotĀ 5 achievements.

    Sniper:

    An expert who has posted more than 50 answers, of which 90% or more were rated as helpful.

    Governor:

    An expert whose answer gotĀ voted for 20 times.

  • Expert
  • 53 Answers

You can use the Round function as below - it rounds out the decimal to 0 places, which gives you 5 digits with no commas

=ROUND(RAND()*100000,0)

Posted on Jul 15, 2008

1 Suggested Answer

6ya6ya
  • 2 Answers

SOURCE: I have freestanding Series 8 dishwasher. Lately during the filling cycle water hammer is occurring. How can this be resolved

Hi,
a 6ya expert can help you resolve that issue over the phone in a minute or two.
best thing about this new service is that you are never placed on hold and get to talk to real repairmen in the US.
the service is completely free and covers almost anything you can think of (from cars to computers, handyman, and even drones).
click here to download the app (for users in the US for now) and get all the help you need.
goodluck!

Posted on Jan 02, 2017

Add Your Answer

Uploading: 0%

my-video-file.mp4

Complete. Click "Add" to insert your video. Add

×

Loading...
Loading...

Related Questions:

1 Answer

Need to do a different face book passcode


Apply following 3 steps-
1. Avoid Predictable Password Formulas The biggest problem is we're all padding our passwords the same way (partly because most companies limit your password length and require certain types of characters). When required to use mix of upper- and lower-case letters, numbers, and symbols, most of us:
  • Use a name, place, or common word as the seed, e.g., "fido" (Women tend to use personal names and men tend to use hobbies)
  • Capitalize the first letter: "Fido"
  • Add a number, most likely 1 or 2, at the end: "Fido1"
  • Add one of the most common symbols (~, !, @, #, $, %, &, ?) at the end: "Fido1!"
Not only are these patterns obvious to professional password guessers, even substituting vowels for numbers ("F1d01!") or appending another word ("G00dF1d01!") wouldn't help much, since hackers are using the patterns against us and appending words from the master crack lists together.
Other clever obfuscation techniques, such as shifting keys to the left or right or using other keyboard patterns are also now sniffed out by hacking tools. As one commenter wrote in the Ars Technica article, hackers use keyword walk generators to emulate millions of keyboard patterns.
The solution: Don't do what everyone else is doing. Avoid the patterns above and remember the basics: don't use a single dictionary word, names, or dates in your password; use a mix of character types (including spaces); and make your passwords as long as possible. If you have a template for how you create memorable passwords, it's only secure if no one else is using that rule. (Check out IT security pro Mark Burnett's collection of the top 10,000 most common passwords, which he says represents 99.8% of all user passwords from leaked databases, or this list of 500 most common passwords in one page.)
2. Use Truly Random Passwords Use multiple unrelated words for your strong, long password: Using a passphrase is more secure and more memorable than complicated but shorter passwords, as web comic Xkcd pointed last year. Longer and simpler passwords trump shorter and more complex ones-but only if the words you use are truly random. If you're using a common quote or saying for your passphrase, you're a target, because hackers' dictionaries include common quotes, phrases, titles, and lyrics-and they can easily employ rules to use just the first letter of each word or other similar pattern. "To be or not to be" and "2b30rn0t2b3" and "tbontb" might all very well take just seconds to crack thanks to fast algorithms, so make your passphrase truly unique and random. (The Xkcd password generator can pick four random words for you.)
The best option is to use a password generator and manager: While the passphrase approach might be good for, say, your computer login or the few cases you need to remember your password, the best option is to generate a truly random, long, and complex password. This avoids the problem of easily cracked patterns and word lists. LastPass, KeePass, or 1Password can all generate a random password for you. See how to build a nearly hack-proof password system with LastPass for detailed instructions. Remember, the only secure password is the one you can't remember.
3. Use a Unique Password for Each Site No matter what passwords you choose or create, this is the most important security strategy of all: Use a different password for each site. This limits the damage that can be done if/when there's a security breach-if your password is compromised on one site, at least all your other accounts are protected.

Jul 09, 2013 | Computers & Internet

1 Answer

How do I use the random number generator to generate numbers between 1-100 or 1-10


The random number generator generates a number between 0 and one. To get a random number between 1 and 100, multiply the generated number by 100, add 1, and discard the fractional portion. To generate a random number between 1 and 10, multiply the generated number by 10, add 1, and discard the fractional portion.

Mar 24, 2011 | Casio FX83ES Scientific Calculator

1 Answer

How do I generate a random number that is greater than 1 on a casio fx-300MS


The random number function always generates a number between zero and one. You can convert this to a random number in any range by a suitable combination of multiplications and additions. For example, if you want a random number between zero and ten, multiply the generated random number by 10. If you want a random number between one and ten, multiply the generated random number by 9 and then add 1.

If you want to simulate the roll of a six-sided die, multiply the generated random number by 6, add 1, and ignore the fractional portion. This will give you a 1, 2, 3, 4, 5, or 6 with more-or-less equal probability.

Mar 10, 2011 | Casio FX-300MS Calculator

1 Answer

Good day im ashric.I lost my sim card holder with


Hi as you have lost the card the sim card was attatched to then the only place you can now get the code from is your service provider, the PUK code is the securit code for the sim card and the code is random so its not like the security code where you can use a number generator to get the code the PUK code is totally random and is between 8 and 11 digits long.

so you have 2 options open to you if you need to use the sim card thats asking for the PUK code then all you need to do is call your service provider and give them your phone number and they may ask your name and address but once this is done they will be able to give you the PUK code over the phone for free.

now the other option you have is if you dont need to use the sim card what you can do is get another sim card and you will either get a new puk code or the sim card wont ask for the PUK code.

let me know how you get on or if you need further assistance.

please could you rate this post as i have a whole page of unrated posts, thanks.

Jan 13, 2011 | RIM BlackBerry Curve 8520 Smartphone

1 Answer

How do i generate random integers with a ti 89 titanium?


Use the rand() function. If you give it a positive integer argument n, it will return a random integer in the range in the interval [1, n]. You'll find rand() in the MATH/PROBABILITY menu.

Dec 08, 2010 | Texas Instruments TI-89 Calculator

1 Answer

Where is the probability button?


The EL-535 can generate random numbers for you. Press 2nd Function, 7. You will see random written above 7 in orange. This will give you four choices for random numbers. 0:RAND - random decimals to 3 decimal places 1:R-DICE -1 to 6 like a standard dice, 2:R-COIN - 0 or 1 and you decide which is heads or tails.3:R-INT for integers up to 99

Dec 06, 2010 | Sharp ELW535 Calculator

2 Answers

Is there a function on the TI-30XA that will generate random nubmers?


No such function my ***!

Just click prb --> RAND randint(
If you want a random integer from 1 to ten, randint(1,10
Then you just keep clicking enter to get different numbers.

Dec 07, 2009 | Texas Instruments TI-30XA Calculator

1 Answer

Program of c to find largest and second larhest number of given 50 numbers using array


This code generates some random number to test.


#include <limits.h>
#include <stdio.h>
#include <stdlib.h>

int main()
{ findLargest();
return 0;
}

int findLargest()
{ int someNumbers[50];
int i;

// to generate some numbers for us to test
for(i=0; i<50; i++)
// generate a random number between 0-100
someNumbers[i] = rand() % 100;

// for keeping track of numbers, set as smallest possible
int largest = INT_MIN;
int largest2 = INT_MIN;

// go through each item in the array
for(i=0; i<50; i++)
{ // if bigger than our previous max, set as new max
if (someNumbers[i] > someNumbers[largest])
largest = i;
// if it's not been set as new max, and is bigger than current 2nd largest
else if(someNumbers[i] > someNumbers[largest2])
largest2 = i;

// for printing all numbers in the array
printf("%d | %d\n",i, someNumbers[i]);
}

// print largest numbers and their position in the array
printf("largest %d (pos %d).\n2nd largest %d (pos %d)",
someNumbers[largest],
largest,
someNumbers[largest2],
largest2
);

return 0;

}

May 07, 2009 | Computers & Internet

1 Answer

How do I get the Ti 85 to do random integers?


Functions on the calculator are bold. Numbers you choose are in italics.

For random positive integers between 0 and n use the following:

int (rand * n) + 1


int is on [Math] [Num] F4

and rand is on [Math] [Prob] F4

rand returns a random number x between 0 and 1 such that 0 < x < 1.

int returns the integer portion of a number such that int 123.456 returns 123 and int -123.456 returns -124.

Jan 19, 2009 | Texas Instruments TI-85 Calculator

2 Answers

Statistics


Random number generators on computers are not really random. They need to be "seeded". If you seed the random number generator with the same seed each time you will generate the same list of numbers. A common technique in computer programming is to seed the random number generator with a value like the number of seconds that has occurred since midnight. This gives you the illusion of real random numbers.

Look up the word "Seed" in your calculator documentation and it will most likely tell you how this is accomplished on the TI calculators.

Nov 20, 2007 | Texas Instruments TI-83 Plus Calculator

Not finding what you are looking for?
Microsoft Excel for PC Logo

71 people viewed this question

Ask a Question

Usually answered in minutes!

Top Microsoft Computers & Internet Experts

micky dee

Level 3 Expert

2644 Answers

Piyal Perera
Piyal Perera

Level 3 Expert

528 Answers

Les Dickinson
Les Dickinson

Level 3 Expert

18384 Answers

Are you a Microsoft Computer and Internet Expert? Answer questions, earn points and help others

Answer questions

Manuals & User Guides

Loading...