Update l2_switching_v4.py

works incase of a single switch topology, for multiple switches topo please refer v5