Anyos Jedlik, a Hungarian inventor, invented the first electric vehicle in 1828. He built the motor to operate an electric train using the electric current from a battery.