I am trying to make my code identify train stations depending on their zones but it only prints : xyz is in Zone1 when xyz is in Zone 2

zone1=["Aldgate","Angel","Baker Street","Bank","barbarican","bayswater","Blackfriars","Bondstreet","Borough","Cannon Street","Chancery Lane","Charing cross","Covent Garden","Edgware Road","Enbankment","Euston","Euston LU","Euston Square","Farringdon","Glouchester Road","Goodge Street","Great Portland Street","Green Park","High Street Kensington","Holborn","Hyde Park Corner","Kings Cross St Pancras LU","Kings Cross","Knightsbridge","Lambeth North","Lancaster Gate","Leicester Square","liverpool street","Mansion House","Marble Arch","Marylebone","Monument","Moorgate","Notting Hill Gate","Old Street","Oxford circus","Paddington","Piccadilly circus","Pimlico","Queensway","Regent's Park","Regents park","Russell square","Shoreditch High street","Sloane square","South Kensington","Southwark","St James Park","St james's Park","St Pauls","St Paul's","Temple","Tottenham Court Road","Tower Hill","Vauxhall","Victoria","Warren Street","Waterloo","Westminister"]
a=[x.lower() for x in zone1]
zone2=["Abbey Road","All Saints","Archway","Arsenal","Barons Court","Battersea Park","Belsize Park","Bermondsey","Bethnal Green","Blackwall","Bow Church"]
b=[Q.lower() for Q in zone2]
inp= input("Enter the station you are leaving from : ")
if inp in zone1 or a:
  print(inp,"is in Zone 1")
elif inp in zone2 or b:
  print(inp,"is in Zone 2")

Read more here: https://stackoverflow.com/questions/68487454/i-am-trying-to-make-my-code-identify-train-stations-depending-on-their-zones-but

Content Attribution

This content was originally published by zain surty at Recent Questions - Stack Overflow, and is syndicated here via their RSS feed. You can read the original post over there.

%d bloggers like this: