473,395 Members | 1,422 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,395 software developers and data experts.

how can i write C code that generate random number without using built in code

plz reply,
thanks in advance.
bye
Nov 14 '05 #1
12 4981
Sweety wrote:
plz reply,
thanks in advance.
bye


HOMEWORK QUESTION
Nov 14 '05 #2
Sweety wrote:
plz reply,
thanks in advance.
bye


HOMEWORK QUESTION
Nov 14 '05 #3
Em Sun, 04 Apr 2004 20:03:48 +0000, Tom St Denis escreveu:
Sweety wrote:
plz reply,
thanks in advance.
bye


HOMEWORK QUESTION


What question? I don't see any question.

--
Quidquid latine dictum sit altum viditur

Nov 14 '05 #4
Em Sun, 04 Apr 2004 20:03:48 +0000, Tom St Denis escreveu:
Sweety wrote:
plz reply,
thanks in advance.
bye


HOMEWORK QUESTION


What question? I don't see any question.

--
Quidquid latine dictum sit altum viditur

Nov 14 '05 #5
Sweety wrote:
plz reply,
No sweat.
thanks in advance.
No problem.
bye


Bye.

--
Richard Heathfield : bi****@eton.powernet.co.uk
"Usenet is a strange place." - Dennis M Ritchie, 29 July 1999.
C FAQ: http://www.eskimo.com/~scs/C-faq/top.html
K&R answers, C books, etc: http://users.powernet.co.uk/eton
Nov 14 '05 #6
Sweety wrote:
plz reply,
No sweat.
thanks in advance.
No problem.
bye


Bye.

--
Richard Heathfield : bi****@eton.powernet.co.uk
"Usenet is a strange place." - Dennis M Ritchie, 29 July 1999.
C FAQ: http://www.eskimo.com/~scs/C-faq/top.html
K&R answers, C books, etc: http://users.powernet.co.uk/eton
Nov 14 '05 #7
http://benpfaff.org/writings/clc
--
"The way I see it, an intelligent person who disagrees with me is
probably the most important person I'll interact with on any given
day."
--Billy Chambless
Nov 14 '05 #8
http://benpfaff.org/writings/clc
--
"The way I see it, an intelligent person who disagrees with me is
probably the most important person I'll interact with on any given
day."
--Billy Chambless
Nov 14 '05 #9
Sweety wrote:
plz reply,
thanks in advance.
bye

You cannot generate truly random numbers (without an external device) in
the mathematical sense of the word. You can only generate pseudorandom
numbers. For the discussion, google the topics "alternative rand()", etc.

My favourie, although very slow method for generating a sequence of
pseudorandoms in the interval [0,1] is

next_number := after_comma_part_of ((Pi+previous_number)^5)
--
Best regards,
Alex.

PS. To email me, remove "loeschedies" from the email address given.
Nov 14 '05 #10
Sweety wrote:
plz reply,
thanks in advance.
bye

You cannot generate truly random numbers (without an external device) in
the mathematical sense of the word. You can only generate pseudorandom
numbers. For the discussion, google the topics "alternative rand()", etc.

My favourie, although very slow method for generating a sequence of
pseudorandoms in the interval [0,1] is

next_number := after_comma_part_of ((Pi+previous_number)^5)
--
Best regards,
Alex.

PS. To email me, remove "loeschedies" from the email address given.
Nov 14 '05 #11
Sweety wrote:

plz reply,


Oh very well.

--
A: Because it fouls the order in which people normally read text.
Q: Why is top-posting such a bad thing?
A: Top-posting.
Q: What is the most annoying thing on usenet and in e-mail?
Nov 14 '05 #12
Sweety wrote:

plz reply,


Oh very well.

--
A: Because it fouls the order in which people normally read text.
Q: Why is top-posting such a bad thing?
A: Top-posting.
Q: What is the most annoying thing on usenet and in e-mail?
Nov 14 '05 #13

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

3
by: vishal | last post by:
i want to generate a random number of a fixed length so how can i do this ?? i know some function which returns a single random character at a time but is there any built-in function which...
2
by: Laphan | last post by:
Hi All This is a strange request, but I just cannot fathom how to do it. In theory the requirement is very basic, but in practise its a noodle!! I have 10 team names like so: Team A Team...
10
by: Virus | last post by:
Ok well what I am trying to do is have 1.) the background color to change randomly with 5 different colors.(change on page load) 2,) 10 different quotes randomly fadeing in and out in random...
16
by: Jason | last post by:
Hi, I need a way to use random numbers in c++. In my c++ project, when using the mingw compiler I used a mersenne twister that is publicly available and this did its job well. Now I have...
11
by: Lues | last post by:
Hi, I'm trying to protect some data in tables with encription (you know why, don't you ;)) I must confess that I'm not very expirienced in writing code, especially encription code. Can any...
6
by: Sweety | last post by:
plz reply, thanks in advance. bye
6
by: Anamika | last post by:
I am doing a project where I want to generate random numbers for say n people.... These numbers should be unique for n people. Two people should not have same numbers.... Also the numbers...
24
by: pereges | last post by:
I need to generate two uniform random numbers between 0 and 1 in C ? How to do it ? I looked into rand function where you need to #define RAND_MAX as 1 but will this rand function give me ...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.