xA=int(input('Abscisse de A : '))
yA=int(input('Ordonnée de A : '))
xB=int(input('Abscisse de B : '))
yB=int(input('Ordonnée de B : '))

m=(yB-yA)/(xB-xA)
p=yA-m*xA

from matplotlib.pyplot import plot,show

if xA>xB:
    xA,xB=xB,xA
    yA,yB=yB,yA

plot([xA,xB],[yA,yB])

for i in range(xA,xB+1):
    y=round(m*i+p,0)
    plot(i,y,marker='s',markerfacecolor='red', markersize=50)
    
show()