#!/usr/bin/python
import random
import string

n_ranks = int(raw_input("nombre de rangees (A, B, C, ...) : "))
n_lines = int(raw_input("nombre de lignes (1, 2, 3, ...): "))

ranks = string.uppercase[0:n_ranks]
lines = range(1, n_lines + 1)
winners = set()

while True:
    next_winner = (random.choice(ranks), random.choice(lines))

    if next_winner not in winners:
        raw_input("attention !")
        print "le gagnant est %s%d" % next_winner
        winners.add(next_winner)
