Thread Subject: Need help with lotto problem

Subject: Need help with lotto problem

From: Johnnycal O Callaghan

Date: 16 Nov, 2009 16:41:03

Message: 1 of 2

Hello fellow users i am a bit of a begginer at matlab and am attempting a pretty tough problem and would appreciate any help with the solution.
The question is as follows
write a Matlab program to simulate the National Lottery draw. The program should identify the day and the date of the draw, followed by six numbers drawn at random(between 1 & 23 inclusive), and a bonus number(between 1 & 23 inclusive). The next phase of the program is to go through entries in data file lottonum.dat to found any match 6 numbers
sample outlook looks like
National Lottery Draw for Tue 03-Nov-2009
Numbers are Bonus
 1 19 6 22 20 5 21
 Checking your numbers please wait......
2 Jackpot Winners for Tue 03-Nov-2009
I have figured
disp('The lotto numbers are')
x=randperm(23)
thanks
any help greatly appreciated.

Subject: Need help with lotto problem

From: the cyclist

Date: 16 Nov, 2009 18:12:02

Message: 2 of 2

"Johnnycal O Callaghan" <johnnycal101@gmail.cim> wrote in message <hdrvav$29o$1@fred.mathworks.com>...
> Hello fellow users i am a bit of a begginer at matlab and am attempting a pretty tough problem and would appreciate any help with the solution.
> The question is as follows
> write a Matlab program to simulate the National Lottery draw. The program should identify the day and the date of the draw, followed by six numbers drawn at random(between 1 & 23 inclusive), and a bonus number(between 1 & 23 inclusive). The next phase of the program is to go through entries in data file lottonum.dat to found any match 6 numbers
> sample outlook looks like
> National Lottery Draw for Tue 03-Nov-2009
> Numbers are Bonus
> 1 19 6 22 20 5 21
> Checking your numbers please wait......
> 2 Jackpot Winners for Tue 03-Nov-2009
> I have figured
> disp('The lotto numbers are')
> x=randperm(23)
> thanks
> any help greatly appreciated.

I assume this is homework. You don't seem to have made very much progress. I suggest one of two approaches:

If you have an idea of how to make some progress, then do everything you can and show us some more work.

If you have NO idea how to get started on this, then I recommend you go to your professor and say "I have NO idea how to get started on this homework problem. What should I do?"

Tags for this Thread

Everyone's Tags:

Add a New Tag:

Separated by commas
Ex.: root locus, bode

What are tags?

A tag is like a keyword or category label associated with each thread. Tags make it easier for you to find threads of interest.

Anyone can tag a thread. Tags are public and visible to everyone.

Tag Activity for This Thread
Tag Applied By Date/Time
lotto help prog... Johnnycal O Callaghan 16 Nov, 2009 11:44:08
rssFeed for this Thread

Contact us at files@mathworks.com