Most people naturally choose to focus on things they are relatively good at, instead of keep banging their heads on something they struggle at.
GP's comment seems to imply it was a negative experience for the newbie, but in all probability given the daily frustrations and chaos of software development in the real world, switching majors might actually be the "right" decision for that person.