from matplotlib.pyplot import plot, show, legend, xlabel, ylabel, title, grid, savefig

if __name__ == "__main__":
    temp_2006 = [-5.9, -2.0, 0.6, 9.7, 13.7, 18.1, 22.6, 17.3, 16.4, 11.4, 7.0, 4.2]
    temp_2012 = [1.0, -4.0, 6.5, 9.1, 14.5, 17.3, 19.9, 19.5, 15.1, 8.8, 6.0, -0.9]
    temp_2018 = [3.4, -1.4, 1.9, 13.9, 17.5, 19.6, 20.6, 22.0, 16.9, 11.6, 5.8, 3.2]

    months = range(1, 13)

    plot(months, temp_2006, marker='x', linestyle='dashdot')
    plot(months, temp_2012, marker='x', linestyle='dotted')
    plot(months, temp_2018, marker='x', linestyle='None')

    title("Średnia dzienna temperatura we Wrocławiu")
    xlabel("Miesiąc")
    ylabel("Temperatura [C]")
    legend([2006, 2012, 2018])

    grid()
    # savefig("wykres1.pdf")
    show()
