# data[].attributes.attachment_link.readable_text
import random
import matplotlib.pyplot as plt


def coin_toss(num_tosses):
    heads = 0
    tails = 0
    for _ in range(num_tosses):
        result = random.choice(['Heads', 'Tails'])
        if result == 'Heads':
            heads += 1
        else:
            tails += 1
    return heads, tails


num_tosses = 100
heads, tails = coin_toss(num_tosses)

# ���������������
labels = ['Heads', 'Tails']
sizes = [heads, tails]

plt.bar(labels, sizes)
plt.xlabel('Outcome')
plt.ylabel('Frequency')
plt.title(f'Coin Toss Results ({num_tosses} tosses)')
plt.show()
    
