'How do i use random.randint in this code?

Im trying to make a fake credit card generator. Im having problem trying to figure out how to have the expiration date between 22, 27. please help me!

import time
import random
import string
import os
from colorama import init, Fore
init(convert=True)
import subprocess, requests


def ccnumber(size=16, chars=string.digits):
    return "".join(random.choice(chars) for _ in range(size))

def expire1(size=2, chars2=string.digits):
    return "".join(random.choice(chars2) for _ in range(size))

def expire2(size=2, char3=string.digits):
    return "".join(random.choice(char3) for _ in range(size))



tries = 0

while(True):
    if(tries > random.randint(10000, 100000)):
        print(Fore.CYAN +"[-]"+ Fore.RED + ccnumber() +"| "+ expire1() +"/"+ expire2() +" |  Valid  |  ")
        print(Fore.CYAN +"Withdrawing...")
        time.sleep(10)
        tries = 0
        print(Fore.GREEN + "Done!")
        time.sleep(1)
    else:
        print(Fore.CYAN +"[-]"+ Fore.RED + ccnumber() +"| "+ expire1() +"/"+ expire2() +" |  Invalid  |  ")
        tries += 1



Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source