Programming C, C++, Java, PHP, Ruby, Turing, VB
Computer Science Canada 
Programming C, C++, Java, PHP, Ruby, Turing, VB  

Username:   Password: 
 RegisterRegister   
 try writing this program?
Index -> Programming, Turing -> Turing Help
View previous topic Printable versionDownload TopicSubscribe to this topicPrivate MessagesRefresh page View next topic
Author Message
kid105




PostPosted: Thu Jan 14, 2010 11:12 pm   Post subject: try writing this program?

someone try to figure this progrm out i tried it but there is noway i could solve it i tried it this is wat i got:

var lotteryticket : array 1 .. 6 of int
var lotterynumbers : int
for i : 1 .. 6
loop
lotterynumbers := Rand.Int (1, 49)
end loop
end for

write a program which generates one ticket for lotto 649. recall that each lotto 649 ticket consists of six different integers between 1 and 49. be carefull! your program must ensure that the ticket does not contain duplicate numbers.

i have other programs to write im really stressed if some one could finish it i would relly appreciate thnx.Sad
Sponsor
Sponsor
Sponsor
sponsor
DtY




PostPosted: Thu Jan 14, 2010 11:24 pm   Post subject: RE:try writing this program?

If I do this, can I have your marks?
registration




PostPosted: Fri Jan 15, 2010 12:31 am   Post subject: Re: try writing this program?

kid105 @ Thu Jan 14, 2010 11:12 pm wrote:
someone try to figure this progrm out i tried it but there is noway i could solve it i tried it this is wat i got:

var lotteryticket : array 1 .. 6 of int
var lotterynumbers : int
for i : 1 .. 6
loop
lotterynumbers := Rand.Int (1, 49)
end loop
end for

write a program which generates one ticket for lotto 649. recall that each lotto 649 ticket consists of six different integers between 1 and 49. be carefull! your program must ensure that the ticket does not contain duplicate numbers.

i have other programs to write im really stressed if some one could finish it i would relly appreciate thnx.Sad


Did you forget about using the exit when command? This is honestly very simple, and you're kind of close.
Turing_Gamer




PostPosted: Fri Jan 15, 2010 8:44 am   Post subject: Re: try writing this program?

Is it just me or was there a similar post in this section of the forum...
Dan




PostPosted: Fri Jan 15, 2010 1:36 pm   Post subject: RE:try writing this program?

Locked, no one wants to do your home work for you.
Computer Science Canada Help with programming in C, C++, Java, PHP, Ruby, Turing, VB and more!
Display posts from previous:   
   Index -> Programming, Turing -> Turing Help
View previous topic Tell A FriendPrintable versionDownload TopicSubscribe to this topicPrivate MessagesRefresh page View next topic

Page 1 of 1  [ 5 Posts ]
Jump to:   


Style:  
Search: