DiscussWorldIssues - Socio-Economic Religion and Political Uncensored Debate

DiscussWorldIssues - Socio-Economic Religion and Political Uncensored Debate (http://www.discussworldissues.com/forums/)
-   Technology Forum (http://www.discussworldissues.com/forums/technology-forum/)
-   -   Little help with programming. (http://www.discussworldissues.com/forums/technology-forum/182610-little-help-programming.html)

payloansday 05-02-2009 11:54 PM

Little help with programming.
 
I'm in a programming class and I've got my first assignment. We have to make a game of Yahtzee. I've got the whole game programmed except one part. After a set of rolls we have to make an output that would look like this:

ROLL #3
Dice 1: 1
Dice 2: 1
Dice 3: 3
Dice 4: 3
Dice 5: 1

You have rolled 3 1's


I've probably over complicated the program by making this set of instructions for each roll (sets each die# to a random number at the beginning of the program):



cout

Louthcoombutt 05-02-2009 11:57 PM

whoa! holy fuck... i had a programming class in high school, they told us to make a game of blackjack that would randomly deal cards and bust you over 21... i was the only one where the computer popped up and said "fuckwit..." i sucked at it

MilenaJaf 05-03-2009 12:01 AM

....hell i learned programing when you had to use a tape to rewind on the apple 3 dos and the word 'run' was used a lot lmao

BM...good luck with that, I hope someone can help you.

Edifsdubs 05-03-2009 12:01 AM

I don't think I'm horrible (only had a few little assignments so far) but I have a nasty habit of over-complicating things.

cyslespitocop 05-03-2009 01:54 AM

So you want it to tell you many dice you have rolled or the added up total? I'm confused.

lymnCymment 05-03-2009 02:00 AM

It needs to say the total number of like dice. For example if you have rolled 3 2's. It would need to output "You have rolled 3 2's.

mudozvonf 05-03-2009 02:09 AM

Ah icic, well on that note I'll have to wait until tomorrow to see the program in action.

DzjwMKo5 05-03-2009 02:14 AM

I'm getting it to where I can make it tell me how many like numbers I have. Still trying to figure out how to make it tell me what those numbers are.

catarleriarly 05-03-2009 03:05 AM

Patience young Padawan.

DevaRextusidis 05-03-2009 03:18 AM

Two hours of staring at code and my patience is gone. I'm taking a break.

HRS1H7gO 10-03-2009 02:58 AM

I hate to self-bump, but this damn thing is making me want to put my head through the wall. I'm so fucking close, just that one little part.

ZanazaKar 11-03-2009 01:20 AM

Finally done.


All times are GMT +1. The time now is 12:17 PM.

Powered by vBulletin® Version 3.8.7
Copyright ©2000 - 2025, vBulletin Solutions, Inc.
Search Engine Friendly URLs by vBSEO 3.6.0 PL2