I am planning to create a simple bulls and cows( also know as mastermind board game) in C.The computer is supposed to make 4 digit code in which the allowed digits are 1,2,3,4,5,and 6 ! 0,7,8,9 are to omitted !! How do I make the computer create such a 4 digit number? I know about rand() function !! But how do I make it omit those 4 digits?
jeevsmyd -2 Junior Poster
Adak 419 Nearly a Posting Virtuoso
Auraomega 2 Junior Poster in Training
jeevsmyd -2 Junior Poster
Adak 419 Nearly a Posting Virtuoso
jeevsmyd -2 Junior Poster
Auraomega 2 Junior Poster in Training
jeevsmyd -2 Junior Poster
Auraomega 2 Junior Poster in Training
Be a part of the DaniWeb community
We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.