/*
*
*
*/ #include<stdio.h>
#include<stdlib.h>
#include<time.h> int main()
{
int tmp; int in_hand[] = {}; char name[]; char tarot[][] = {
"[0]--->(The Fool, 0)",
"[1]--->(The Magician, I)",
"[2]--->(The High Priestess, II)",
"[3]--->(The Empress, III)",
"[4]--->(The Emperor, IV)",
"[5]--->(The Hierophant, or the Pope, V)",
"[6]--->(The Lovers, VI)",
"[7]--->(The Chariot, VII)",
"[8]--->(Strength, VIII)",
"[9]--->(The Hermit, IX)",
"[10]--->(The Wheel of Fortune, X)",
"[11]--->(Justice, XI)",
"[12]--->(The Hanged Man, XII)",
"[13]--->(Death, XIII)",
"[14]--->(Temperance, XIV)",
"[15]--->(The Devil, XV)",
"[16]--->(The Tower, XVI)",
"[17]--->(The Star, XVII)",
"[18]--->(The Moon, XVIII)",
"[19]--->(The Sun, XIX)",
"[20]--->(Judgement, XX)",
"[21]--->(The World, XXI)"
}; printf("TAROT.\n"); printf("Enter your name:"); gets(name); int left_cards = ; for(;left_cards > ;){ srand((int)time()); tmp = rand()%; if(!in_hand[tmp]){ in_hand[tmp] = ; if(left_cards > )
printf("%s \n", tarot[tmp]);
else
printf("YOUR CARD:%s \n", tarot[tmp]); left_cards --;
}
} printf("\n"); return ;
}
TAROT.
Enter your name:xkfx
[18]--->(The Moon, XVIII)
[1]--->(The Magician, I)
[4]--->(The Emperor, IV)
[7]--->(The Chariot, VII)
[10]--->(The Wheel of Fortune, X)
[14]--->(Temperance, XIV)
[17]--->(The Star, XVII)
[20]--->(Judgement, XX)
[3]--->(The Empress, III)
[6]--->(The Lovers, VI)
[9]--->(The Hermit, IX)
[12]--->(The Hanged Man, XII)
[16]--->(The Tower, XVI)
[19]--->(The Sun, XIX)
[8]--->(Strength, VIII)
[11]--->(Justice, XI)
[0]--->(The Fool, 0)
[13]--->(Death, XIII)
[2]--->(The High Priestess, II)
[5]--->(The Hierophant, or the Pope, V)
YOUR CARD:[15]--->(The Devil, XV)